diff --git a/src/me/libraryaddict/disguise/Commands/DisguiseCommand.java b/src/me/libraryaddict/disguise/Commands/DisguiseCommand.java index e623d19a..fb7d7912 100644 --- a/src/me/libraryaddict/disguise/Commands/DisguiseCommand.java +++ b/src/me/libraryaddict/disguise/Commands/DisguiseCommand.java @@ -23,7 +23,7 @@ public class DisguiseCommand implements CommandExecutor { ArrayList names = new ArrayList(); for (DisguiseType type : DisguiseType.values()) { String name = type.name().toLowerCase(); - if (sender.hasPermission("libsdisguises.disguise." + name)) + if (sender.hasPermission("libsdisguises.disguise.*") || sender.hasPermission("libsdisguises.disguise." + name)) names.add(name); } Collections.sort(names, String.CASE_INSENSITIVE_ORDER); @@ -32,6 +32,8 @@ public class DisguiseCommand implements CommandExecutor { private ArrayList forbiddenDisguises(CommandSender sender) { ArrayList names = new ArrayList(); + if (sender.hasPermission("libsdisguises.disguise.*")) + return names; for (DisguiseType type : DisguiseType.values()) { String name = type.name().toLowerCase(); if (!sender.hasPermission("libsdisguises.disguise." + name)) diff --git a/src/me/libraryaddict/disguise/Commands/DisguiseEntityCommand.java b/src/me/libraryaddict/disguise/Commands/DisguiseEntityCommand.java index ddf4a0c0..3717dcce 100644 --- a/src/me/libraryaddict/disguise/Commands/DisguiseEntityCommand.java +++ b/src/me/libraryaddict/disguise/Commands/DisguiseEntityCommand.java @@ -28,7 +28,8 @@ public class DisguiseEntityCommand implements CommandExecutor { ArrayList names = new ArrayList(); for (DisguiseType type : DisguiseType.values()) { String name = type.name().toLowerCase(); - if (sender.hasPermission("libsdisguises.disguiseentity." + name)) + if (sender.hasPermission("libsdisguises.disguiseentity.*") + || sender.hasPermission("libsdisguises.disguiseentity." + name)) names.add(name); } Collections.sort(names, String.CASE_INSENSITIVE_ORDER); @@ -37,6 +38,8 @@ public class DisguiseEntityCommand implements CommandExecutor { private ArrayList forbiddenDisguises(CommandSender sender) { ArrayList names = new ArrayList(); + if (sender.hasPermission("libsdisguises.disguiseentity.*")) + return names; for (DisguiseType type : DisguiseType.values()) { String name = type.name().toLowerCase(); if (!sender.hasPermission("libsdisguises.disguiseentity." + name)) diff --git a/src/me/libraryaddict/disguise/Commands/DisguisePlayerCommand.java b/src/me/libraryaddict/disguise/Commands/DisguisePlayerCommand.java index ba0cb7af..c45189ca 100644 --- a/src/me/libraryaddict/disguise/Commands/DisguisePlayerCommand.java +++ b/src/me/libraryaddict/disguise/Commands/DisguisePlayerCommand.java @@ -24,7 +24,8 @@ public class DisguisePlayerCommand implements CommandExecutor { ArrayList names = new ArrayList(); for (DisguiseType type : DisguiseType.values()) { String name = type.name().toLowerCase(); - if (sender.hasPermission("libsdisguises.disguiseplayer." + name)) + if (sender.hasPermission("libsdisguises.disguiseplayer.*") + || sender.hasPermission("libsdisguises.disguiseplayer." + name)) names.add(name); } Collections.sort(names, String.CASE_INSENSITIVE_ORDER); @@ -33,6 +34,8 @@ public class DisguisePlayerCommand implements CommandExecutor { private ArrayList forbiddenDisguises(CommandSender sender) { ArrayList names = new ArrayList(); + if (sender.hasPermission("libsdisguises.disguiseplayer.*")) + return names; for (DisguiseType type : DisguiseType.values()) { String name = type.name().toLowerCase(); if (!sender.hasPermission("libsdisguises.disguiseplayer." + name)) diff --git a/src/me/libraryaddict/disguise/Commands/DisguiseRadiusCommand.java b/src/me/libraryaddict/disguise/Commands/DisguiseRadiusCommand.java index 585b169a..91bf442c 100644 --- a/src/me/libraryaddict/disguise/Commands/DisguiseRadiusCommand.java +++ b/src/me/libraryaddict/disguise/Commands/DisguiseRadiusCommand.java @@ -29,7 +29,8 @@ public class DisguiseRadiusCommand implements CommandExecutor { ArrayList names = new ArrayList(); for (DisguiseType type : DisguiseType.values()) { String name = type.name().toLowerCase(); - if (sender.hasPermission("libsdisguises.disguiseradius." + name)) + if (sender.hasPermission("libsdisguises.disguiseradius.*") + || sender.hasPermission("libsdisguises.disguiseradius." + name)) names.add(name); } Collections.sort(names, String.CASE_INSENSITIVE_ORDER); @@ -38,6 +39,8 @@ public class DisguiseRadiusCommand implements CommandExecutor { private ArrayList forbiddenDisguises(CommandSender sender) { ArrayList names = new ArrayList(); + if (sender.hasPermission("libsdisguises.disguiseradius.*")) + return names; for (DisguiseType type : DisguiseType.values()) { String name = type.name().toLowerCase(); if (!sender.hasPermission("libsdisguises.disguiseradius." + name))