diff options
Diffstat (limited to 'Essentials/src/com/earth2me/essentials/commands/Commandgamemode.java')
-rw-r--r-- | Essentials/src/com/earth2me/essentials/commands/Commandgamemode.java | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandgamemode.java b/Essentials/src/com/earth2me/essentials/commands/Commandgamemode.java index 5dbe09da7..9707c8403 100644 --- a/Essentials/src/com/earth2me/essentials/commands/Commandgamemode.java +++ b/Essentials/src/com/earth2me/essentials/commands/Commandgamemode.java @@ -85,12 +85,13 @@ public class Commandgamemode extends EssentialsCommand throw new NotEnoughArgumentsException("You need to specify a valid player/mode."); } + boolean skipHidden = sender instanceof Player && !ess.getUser(sender).isAuthorized("essentials.vanish.interact"); boolean foundUser = false; final List<Player> matchedPlayers = server.matchPlayer(name); for (Player matchPlayer : matchedPlayers) { final User player = ess.getUser(matchPlayer); - if (player.isHidden()) + if (skipHidden && player.isHidden()) { continue; } |