Archiviert
1
0

Denying watchcat command

Dieser Commit ist enthalten in:
Lixfel 2019-07-09 21:43:32 +02:00
Ursprung b9c158da39
Commit 7b0fe96b13
2 geänderte Dateien mit 22 neuen und 0 gelöschten Zeilen

Datei anzeigen

@ -110,6 +110,7 @@ public class BungeeCore extends Plugin {
addCmd(new FightCommand()); addCmd(new FightCommand());
addCmd(new HelpCommand()); addCmd(new HelpCommand());
addCmd(new BanCommand()); addCmd(new BanCommand());
addCmd(new DenyCommand("watchcat", "wc"));
BroadCastMsgs = config.getStringList("broadcasts").toArray(new String[1]); BroadCastMsgs = config.getStringList("broadcasts").toArray(new String[1]);
getProxy().getScheduler().schedule(this, () -> { getProxy().getScheduler().schedule(this, () -> {

Datei anzeigen

@ -0,0 +1,21 @@
package de.steamwar.bungeecore.commands;
import de.steamwar.bungeecore.BungeeCore;
import net.md_5.bungee.api.CommandSender;
import net.md_5.bungee.api.chat.TextComponent;
import net.md_5.bungee.api.connection.ProxiedPlayer;
public class DenyCommand extends Command {
public DenyCommand(String cmd, String ...aliases) {
super(cmd, "", aliases);
}
@Override
public void execute(CommandSender sender, String[] args) {
if(sender instanceof ProxiedPlayer){
ProxiedPlayer player = (ProxiedPlayer) sender;
player.sendMessage(new TextComponent(BungeeCore.ChatPrefix + "§cUnbekannter Befehl."));
}
}
}