mirror of
https://github.com/EssentialsX/Essentials.git
synced 2024-11-03 01:19:58 +01:00
Prevent GM commands from being used on CommandBlocks.
This commit is contained in:
parent
237c896fff
commit
a7aa8be37a
@ -202,4 +202,5 @@ v 2.0:
|
||||
- Change order of data in Users.yml to [name, Group, SubGroup, Permissions, Info nodes].
|
||||
- Add alphabetically sorted user lists.
|
||||
- allWorldsDataList now returns fully mirrored worlds which are not identical mirrors (fixes the /manselect list).
|
||||
- Add support for Rcon.
|
||||
- Add support for Rcon.
|
||||
- Prevent GM commands from being used on CommandBlocks.
|
@ -381,6 +381,12 @@ public class GroupManager extends JavaPlugin {
|
||||
Group senderGroup = null;
|
||||
User senderUser = null;
|
||||
boolean isOpOverride = config.isOpOverride();
|
||||
|
||||
// PREVENT GM COMMANDS BEING USED ON COMMANDBLOCKS
|
||||
if (sender.getClass().getName().equals("org.bukkit.command.BlockCommandSender")) {
|
||||
sender.sendMessage(ChatColor.RED + "GM Commands can not be called from CommandBlocks");
|
||||
return true;
|
||||
}
|
||||
|
||||
// DETERMINING PLAYER INFORMATION
|
||||
if (sender instanceof Player) {
|
||||
|
Loading…
Reference in New Issue
Block a user