SteamWar/BauSystem2.0
Archiviert
12
0

Fix GamemodeCommand code convention

Dieser Commit ist enthalten in:
yoyosource 2021-04-17 15:48:21 +02:00
Ursprung 67f38d7523
Commit 4c8159043f

Datei anzeigen

@ -25,7 +25,6 @@ import net.md_5.bungee.api.ChatColor;
import org.bukkit.GameMode; import org.bukkit.GameMode;
import org.bukkit.entity.Player; import org.bukkit.entity.Player;
@Linked(LinkageType.COMMAND) @Linked(LinkageType.COMMAND)
public class GamemodeCommand extends SWCommand { public class GamemodeCommand extends SWCommand {
@ -33,14 +32,12 @@ public class GamemodeCommand extends SWCommand {
super("gamemode", "gm", "g"); super("gamemode", "gm", "g");
} }
@Register(help = true) @Register(help = true)
public void help(final Player p, final String... args) { public void help(final Player p, final String... args) {
p.sendMessage(ChatColor.RED + "Unbekannter Spielmodus."); p.sendMessage(ChatColor.RED + "Unbekannter Spielmodus.");
p.sendMessage(ChatColor.RED + "Mögliche Spielmodi: survival, adventure, creative, specator."); p.sendMessage(ChatColor.RED + "Mögliche Spielmodi: survival, adventure, creative, specator.");
} }
@Register @Register
public void genericCommand(final Player p) { public void genericCommand(final Player p) {
if (p.getGameMode() == GameMode.CREATIVE) { if (p.getGameMode() == GameMode.CREATIVE) {
@ -50,7 +47,6 @@ public class GamemodeCommand extends SWCommand {
} }
} }
@Register @Register
public void gamemodeCommand(final Player p, final GameMode gameMode) { public void gamemodeCommand(final Player p, final GameMode gameMode) {
p.setGameMode(gameMode); p.setGameMode(gameMode);