mirror of
				https://github.com/IntellectualSites/PlotSquared.git
				synced 2025-10-31 01:23:44 +01:00 
			
		
		
		
	Fix for ItemFrames
This commit is contained in:
		| @@ -2803,6 +2803,13 @@ import org.bukkit.util.Vector; | |||||||
|             return; |             return; | ||||||
|         } |         } | ||||||
|         Entity victim = event.getEntity(); |         Entity victim = event.getEntity(); | ||||||
|  |         if (victim.getType().equals(EntityType.ITEM_FRAME)) { | ||||||
|  |             Plot plot = BukkitUtil.getLocation(victim).getPlot(); | ||||||
|  |             if (plot != null && !plot.isAdded(damager.getUniqueId())) { | ||||||
|  |                 event.setCancelled(true); | ||||||
|  |                 return; | ||||||
|  |             } | ||||||
|  |         } | ||||||
|         if (!entityDamage(damager, victim, event.getCause())) { |         if (!entityDamage(damager, victim, event.getCause())) { | ||||||
|             if (event.isCancelled()) { |             if (event.isCancelled()) { | ||||||
|                 if (victim instanceof Ageable) { |                 if (victim instanceof Ageable) { | ||||||
| @@ -2918,7 +2925,7 @@ import org.bukkit.util.Vector; | |||||||
|                         "plots.admin.destroy." + stub); |                         "plots.admin.destroy." + stub); | ||||||
|                     return false; |                     return false; | ||||||
|                 } |                 } | ||||||
|             } else if (victim.getEntityId() == 30) { |             } else if (victim.getType() == EntityType.ARMOR_STAND) { | ||||||
|                 if (plot != null && (plot.getFlag(Flags.MISC_BREAK, false) || plot |                 if (plot != null && (plot.getFlag(Flags.MISC_BREAK, false) || plot | ||||||
|                     .isAdded(plotPlayer.getUUID()))) { |                     .isAdded(plotPlayer.getUUID()))) { | ||||||
|                     return true; |                     return true; | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user
	 MattBDev
					MattBDev