Java Code Examples for org.bukkit.command.Command#testPermissionSilent()

The following examples show how to use org.bukkit.command.Command#testPermissionSilent() . You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: MultipleCommandAliasHelpTopic.java    From Kettle with GNU General Public License v3.0 6 votes vote down vote up
public boolean canSee(CommandSender sender) {
    if (amendedPermission == null) {
        if (sender instanceof ConsoleCommandSender) {
            return true;
        }

        for (Command command : alias.getCommands()) {
            if (!command.testPermissionSilent(sender)) {
                return false;
            }
        }

        return true;
    } else {
        return sender.hasPermission(amendedPermission);
    }
}
 
Example 2
Source File: MultipleCommandAliasHelpTopic.java    From Thermos with GNU General Public License v3.0 6 votes vote down vote up
public boolean canSee(CommandSender sender) {
    if (amendedPermission == null) {
        if (sender instanceof ConsoleCommandSender) {
            return true;
        }

        for (Command command : alias.getCommands()) {
            if (!command.testPermissionSilent(sender)) {
                return false;
            }
        }

        return true;
    } else {
        return sender.hasPermission(amendedPermission);
    }
}