bugfix - admins could not place signs etc in safezones
This commit is contained in:
		@@ -102,6 +102,7 @@ public class FactionsBlockListener extends BlockListener {
 | 
			
		||||
		Faction myFaction = me.getFaction();
 | 
			
		||||
		Faction otherFaction = Board.getFactionAt(new FLocation(block));
 | 
			
		||||
		
 | 
			
		||||
		// In safe zones you may use any block...
 | 
			
		||||
		if (otherFaction.isNormal() && myFaction != otherFaction) {
 | 
			
		||||
			me.sendMessage("You can't use "+TextUtil.getMaterialName(material)+" in the territory of "+otherFaction.getTag(myFaction));
 | 
			
		||||
			return false;
 | 
			
		||||
 
 | 
			
		||||
@@ -159,11 +159,20 @@ public class FactionsPlayerListener extends PlayerListener{
 | 
			
		||||
		}
 | 
			
		||||
 | 
			
		||||
		FPlayer me = FPlayer.get(player);
 | 
			
		||||
		
 | 
			
		||||
		if (otherFaction.isSafeZone()) {
 | 
			
		||||
			if (Factions.hasPermManageSafeZone(player)) {
 | 
			
		||||
				return true;
 | 
			
		||||
			}
 | 
			
		||||
			me.sendMessage("You can't use "+TextUtil.getMaterialName(material)+" in a safe zone.");
 | 
			
		||||
			return false;
 | 
			
		||||
		}
 | 
			
		||||
		
 | 
			
		||||
		Faction myFaction = me.getFaction();
 | 
			
		||||
 | 
			
		||||
		// Cancel if we are not in our own territory
 | 
			
		||||
		if (myFaction != otherFaction) {
 | 
			
		||||
			me.sendMessage("You can't use that in the territory of "+otherFaction.getTag(myFaction));
 | 
			
		||||
			me.sendMessage("You can't use "+TextUtil.getMaterialName(material)+" in the territory of "+otherFaction.getTag(myFaction));
 | 
			
		||||
			return false;
 | 
			
		||||
		}
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user