|
|
|
@@ -254,6 +254,7 @@ public class WorldGuardPlugin extends JavaPlugin {
|
|
|
|
|
public void loadConfiguration() {
|
|
|
|
|
Configuration config = getConfiguration();
|
|
|
|
|
config.load();
|
|
|
|
|
perms.load();
|
|
|
|
|
|
|
|
|
|
enforceOneSession = config.getBoolean("protection.enforce-single-session", true);
|
|
|
|
|
itemDurability = config.getBoolean("protection.item-durability", true);
|
|
|
|
@@ -483,7 +484,7 @@ public class WorldGuardPlugin extends JavaPlugin {
|
|
|
|
|
checkArgs(args, 0, 1);
|
|
|
|
|
|
|
|
|
|
// Allow setting other people invincible
|
|
|
|
|
if (args.length > 1) {
|
|
|
|
|
if (args.length > 0) {
|
|
|
|
|
if (!hasPermission(player, "/godother")) {
|
|
|
|
|
player.sendMessage(ChatColor.RED + "You don't have permission to make others invincible.");
|
|
|
|
|
return true;
|
|
|
|
@@ -572,7 +573,7 @@ public class WorldGuardPlugin extends JavaPlugin {
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if (cmd.equalsIgnoreCase("stack")) {
|
|
|
|
|
checkPermission(player, "stack");
|
|
|
|
|
checkPermission(player, "/stack");
|
|
|
|
|
checkArgs(args, 0, 0);
|
|
|
|
|
|
|
|
|
|
ItemStack[] items = player.getInventory().getContents();
|
|
|
|
@@ -640,7 +641,7 @@ public class WorldGuardPlugin extends JavaPlugin {
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if (cmd.equalsIgnoreCase("locate")) {
|
|
|
|
|
checkPermission(player, "locate");
|
|
|
|
|
checkPermission(player, "/locate");
|
|
|
|
|
checkArgs(args, 0, 3);
|
|
|
|
|
|
|
|
|
|
if (args.length == 1) {
|
|
|
|
@@ -688,7 +689,7 @@ public class WorldGuardPlugin extends JavaPlugin {
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if (cmd.equalsIgnoreCase("reloadwg")) {
|
|
|
|
|
checkPermission(player, "reloadwg");
|
|
|
|
|
checkPermission(player, "/reloadwg");
|
|
|
|
|
checkArgs(args, 0, 0);
|
|
|
|
|
|
|
|
|
|
LoggerToChatHandler handler = new LoggerToChatHandler(player);
|
|
|
|
|