Update BauSystem to new CommandFramework #217
@ -91,7 +91,7 @@ public class BauSystem extends JavaPlugin implements Listener {
|
|||||||
new CommandLoader();
|
new CommandLoader();
|
||||||
getCommand("lockschem").setExecutor(new CommandLockschem());
|
getCommand("lockschem").setExecutor(new CommandLockschem());
|
||||||
new CommandDebugStick();
|
new CommandDebugStick();
|
||||||
getCommand("watervision").setExecutor(new CommandGills());
|
new CommandGills();
|
||||||
new CommandDetonator();
|
new CommandDetonator();
|
||||||
new CommandScript();
|
new CommandScript();
|
||||||
getCommand("scriptvars").setExecutor(new CommandScriptVars());
|
getCommand("scriptvars").setExecutor(new CommandScriptVars());
|
||||||
|
@ -20,22 +20,20 @@
|
|||||||
package de.steamwar.bausystem.commands;
|
package de.steamwar.bausystem.commands;
|
||||||
|
|
||||||
import de.steamwar.bausystem.BauSystem;
|
import de.steamwar.bausystem.BauSystem;
|
||||||
import org.bukkit.command.Command;
|
import de.steamwar.command.SWCommand;
|
||||||
import org.bukkit.command.CommandExecutor;
|
|
||||||
import org.bukkit.command.CommandSender;
|
|
||||||
import org.bukkit.entity.Player;
|
import org.bukkit.entity.Player;
|
||||||
import org.bukkit.potion.PotionEffect;
|
import org.bukkit.potion.PotionEffect;
|
||||||
import org.bukkit.potion.PotionEffectType;
|
import org.bukkit.potion.PotionEffectType;
|
||||||
|
|
||||||
public class CommandGills implements CommandExecutor {
|
public class CommandGills extends SWCommand {
|
||||||
|
|
||||||
@Override
|
public CommandGills() {
|
||||||
public boolean onCommand(CommandSender sender, Command command, String label, String[] args) {
|
super("watervision", "wv");
|
||||||
if (!(sender instanceof Player))
|
}
|
||||||
return false;
|
|
||||||
Player player = (Player) sender;
|
@Register
|
||||||
toggleGills(player);
|
public void genericCommand(Player p) {
|
||||||
return false;
|
toggleGills(p);
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void toggleGills(Player player) {
|
public static void toggleGills(Player player) {
|
||||||
|
@ -12,7 +12,5 @@ commands:
|
|||||||
fire:
|
fire:
|
||||||
freeze:
|
freeze:
|
||||||
aliases: stoplag
|
aliases: stoplag
|
||||||
watervision:
|
|
||||||
aliases: wv
|
|
||||||
lockschem:
|
lockschem:
|
||||||
scriptvars:
|
scriptvars:
|
In neuem Issue referenzieren
Einen Benutzer sperren