diff --git a/src/com/sk89q/worldguard/bukkit/commands/CommandRegionInfo.java b/src/com/sk89q/worldguard/bukkit/commands/CommandRegionInfo.java index d66ff767..429fc01f 100644 --- a/src/com/sk89q/worldguard/bukkit/commands/CommandRegionInfo.java +++ b/src/com/sk89q/worldguard/bukkit/commands/CommandRegionInfo.java @@ -81,7 +81,7 @@ public boolean handle(CommandSender sender, String senderName, String command, S s.append(", "); } - s.append(flags.getFlag(nfo.type).toString()); + s.append(nfo.name + ": " + flags.getFlag(nfo.type).toString()); } sender.sendMessage(ChatColor.BLUE + "Flags: " + s.toString()); diff --git a/src/com/sk89q/worldguard/protection/ApplicableRegionSet.java b/src/com/sk89q/worldguard/protection/ApplicableRegionSet.java index beb7de1d..4b5f2866 100644 --- a/src/com/sk89q/worldguard/protection/ApplicableRegionSet.java +++ b/src/com/sk89q/worldguard/protection/ApplicableRegionSet.java @@ -73,20 +73,29 @@ public boolean isStateFlagAllowed(FlagType type) { return isStateFlagAllowed(type, global.getDefaultValue(type)); } - public boolean isStateFlagAllowed(FlagType type, LocalPlayer player) { - return isStateFlagAllowed(type, global.getDefaultValue(type)) || this.isMember(player); - } - public boolean isStateFlagAllowed(FlagType type, boolean def) { - State defState = def ? State.ALLOW : State.DENY; - return getStateFlag(type, true).getValue(defState) == State.ALLOW; + if(!this.isAnyRegionAffected()) + { + return def; + } + + return getStateFlag(type, true).getValue(State.DENY) == State.ALLOW; + } + + public boolean isStateFlagAllowed(FlagType type, LocalPlayer player) { + + return isStateFlagAllowed(type, global.getDefaultValue(type), player); } public boolean isStateFlagAllowed(FlagType type, boolean def, LocalPlayer player) { - State defState = def ? State.ALLOW : State.DENY; - return getStateFlag(type, true).getValue(defState) == State.ALLOW || this.isMember(player); + if(!this.isAnyRegionAffected()) + { + return def; + } + + return getStateFlag(type, true).getValue(State.DENY) == State.ALLOW || this.isMember(player); }