Change permission checking in preparation for permission rework

This commit is contained in:
Magnus Ulf
2018-12-20 18:12:16 +01:00
parent f347c1058a
commit 0efccf335c
4 changed files with 69 additions and 45 deletions

View File

@@ -170,8 +170,7 @@ public class EngineChunkChange extends Engine
MPerm claimnear = MPerm.getPermClaimnear();
for (Faction nearbyFaction : nearbyFactions)
{
if (claimnear.has(newFaction, nearbyFaction)) continue;
mplayer.message(claimnear.createDeniedMessage(mplayer, nearbyFaction));
if (claimnear.has(mplayer, nearbyFaction, true)) continue;
event.setCancelled(true);
return;
}