Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public static boolean processCommand(Player player, String command,
- boolean console, boolean clientCommand) {
- if (command.length() == 0) // if they used ::(nothing) theres no command
- return false;
- String[] cmd = command.toLowerCase().split(" ");
- if (cmd.length == 0)
- return false;
- if (player.isAdmin()
- && processAdminCommand(player, cmd, console, clientCommand))
- return true;
- if (player.isMod()
- && (processModCommand(player, cmd, console, clientCommand)
- || processHeadModCommands(player, cmd, console, clientCommand)))
- return true;
- if ((player.isSupporter() || player.getRights() >= 1) && processSupportCommands(player, cmd, console, clientCommand))
- return true;
- if (Settings.ECONOMY) {
- player.getPackets().sendGameMessage("You can't use any commands in economy mode!");
- return true;
- }
- if (player.getControlerManager().getControler() instanceof DuelArena || player.getControlerManager().getControler() instanceof DuelControler) {
- player.getPackets().sendGameMessage("You can't use any commands in a duel!");
- return true;
- }
- return processNormalCommand(player, cmd, false, clientCommand);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement