Merge branch 'master' into 1.15
This commit is contained in:
commit
431080eea9
17 files changed
+134
-51
No files matched your search
@@ -185,6 +185,23 @@ public class SettingsManager
|
||||
}));
|
||||
}
|
||||
|
||||
public static boolean canUseCommand(ServerCommandSource source, String commandLevel)
|
||||
{
|
||||
switch (commandLevel)
|
||||
{
|
||||
case "true": return true;
|
||||
case "false": return false;
|
||||
case "ops": return source.hasPermissionLevel(2); // typical for other cheaty commands
|
||||
case "0":
|
||||
case "1":
|
||||
case "2":
|
||||
case "3":
|
||||
case "4":
|
||||
return source.hasPermissionLevel(Integer.parseInt(commandLevel));
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
private void loadConfigurationFromConf()
|
||||
{
|
||||
for (ParsedRule<?> rule : rules.values()) rule.resetToDefault(server.getCommandSource());
|
||||
|
||||
Reference in new issue
Block a user