Admin claims + delete claim = resize small.

Now players with both admin claims permission and delete claims
permission may resize another player's claim to smaller than the minimum
size.
This commit is contained in:
ryanhamshire 2015-01-31 13:08:05 -08:00
parent 44fb29561e
commit 1e85ed931d

View File

@ -1872,7 +1872,7 @@ class PlayerEventHandler implements Listener
int newHeight = (Math.abs(newz1 - newz2) + 1);
boolean smaller = newWidth < playerData.claimResizing.getWidth() || newHeight < playerData.claimResizing.getHeight();
if(!playerData.claimResizing.isAdminClaim() && smaller && (newWidth < GriefPrevention.instance.config_claims_minSize || newHeight < GriefPrevention.instance.config_claims_minSize))
if(!player.hasPermission("griefprevention.adminclaims") && !playerData.claimResizing.isAdminClaim() && smaller && (newWidth < GriefPrevention.instance.config_claims_minSize || newHeight < GriefPrevention.instance.config_claims_minSize))
{
GriefPrevention.sendMessage(player, TextMode.Err, Messages.ResizeClaimTooSmall, String.valueOf(GriefPrevention.instance.config_claims_minSize));
return;