diff --git a/src/main/java/com/massivecraft/factions/listeners/FactionsBlockListener.java b/src/main/java/com/massivecraft/factions/listeners/FactionsBlockListener.java index 7fb0b14a..8ae67aa5 100644 --- a/src/main/java/com/massivecraft/factions/listeners/FactionsBlockListener.java +++ b/src/main/java/com/massivecraft/factions/listeners/FactionsBlockListener.java @@ -344,6 +344,10 @@ public class FactionsBlockListener implements Listener { boolean pain = !justCheck && rel.confPainBuild(online); boolean deny = rel.confDenyBuild(online); + Access access = otherFaction.getAccess(me, PermissableAction.fromString(action)); + if (access == Access.ALLOW && ((rel == Relation.ALLY) || (rel == Relation.ENEMY) || (rel == Relation.NEUTRAL) || (rel == Relation.TRUCE))) { + deny = false; + } // hurt the player for building/destroying in other territory? if (pain) { player.damage(Conf.actionDeniedPainAmount); @@ -380,7 +384,7 @@ public class FactionsBlockListener implements Listener { } // Check the permission just after making sure the land isn't owned by someone else to avoid bypass. - Access access = otherFaction.getAccess(me, PermissableAction.fromString(action)); + if (access != Access.ALLOW && me.getRole() != Role.ADMIN) { // TODO: Update this once new access values are added other than just allow / deny. if (access == Access.DENY) {