SteamWar/SpigotCore
Archiviert
13
0

Merge branch 'master' into schematic-node

Dieser Commit ist enthalten in:
Chaoscaot 2021-07-10 22:25:36 +02:00
Commit ea74198a40

Datei anzeigen

@ -19,6 +19,7 @@
package de.steamwar.command;
import de.steamwar.sql.SteamwarUser;
import org.bukkit.Bukkit;
import org.bukkit.GameMode;
import org.bukkit.command.Command;
@ -69,6 +70,7 @@ public class SWCommandUtils {
if (s.equals("a") || s.equals("adventure") || s.equals("2")) return GameMode.ADVENTURE;
return null;
}, s -> Arrays.asList("s", "survival", "0", "c", "creative", "1", "sp", "spectator", "3", "a", "adventure", "2")));
MAPPER_FUNCTIONS.put(SteamwarUser.class.getTypeName(), createMapper(SteamwarUser::get, s -> Bukkit.getOnlinePlayers().stream().map(Player::getName).collect(Collectors.toList())));
}
private static void addMapper(Class<?> clazz, Class<?> alternativeClazz, TypeMapper<?> mapper) {