From b3771feb01adfcb4f9fe061f84d7c14db8b3e51b Mon Sep 17 00:00:00 2001 From: DroppingAnvil Date: Mon, 30 Mar 2020 16:33:50 -0500 Subject: [PATCH] Fixed claim using moderator checks instead of f perms --- .../massivecraft/factions/zcore/persist/MemoryFPlayer.java | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/main/java/com/massivecraft/factions/zcore/persist/MemoryFPlayer.java b/src/main/java/com/massivecraft/factions/zcore/persist/MemoryFPlayer.java index 4208dbc1..3efbf51f 100644 --- a/src/main/java/com/massivecraft/factions/zcore/persist/MemoryFPlayer.java +++ b/src/main/java/com/massivecraft/factions/zcore/persist/MemoryFPlayer.java @@ -842,12 +842,14 @@ public abstract class MemoryFPlayer implements FPlayer { return true; } else if (currentFaction.getAccess(this, PermissableAction.TERRITORY) == Access.ALLOW) { return true; + } else if (currentFaction.isWilderness() && forFaction.getAccess(this, PermissableAction.TERRITORY) == Access.ALLOW) { + return true; } else if (myFaction != forFaction) { error = FactionsPlugin.getInstance().txt.parse(TL.CLAIM_CANTCLAIM.toString(), forFaction.describeTo(this)); } else if (forFaction == currentFaction) { error = FactionsPlugin.getInstance().txt.parse(TL.CLAIM_ALREADYOWN.toString(), forFaction.describeTo(this, true)); - } else if (this.getRole().value < Role.MODERATOR.value) { - error = FactionsPlugin.getInstance().txt.parse(TL.CLAIM_MUSTBE.toString(), Role.MODERATOR.getTranslation()); + } else if (forFaction.getAccess(this, PermissableAction.TERRITORY) != Access.ALLOW) { + error = TL.COMMAND_CLAIM_DENIED.toString(); } else if (forFaction.getFPlayers().size() < Conf.claimsRequireMinFactionMembers) { error = FactionsPlugin.getInstance().txt.parse(TL.CLAIM_MEMBERS.toString(), Conf.claimsRequireMinFactionMembers); } else if (currentFaction.isSafeZone()) {