Paper/nms-patches/EntityItemFrame.patch
Thinkofdeath 24557bc2b3 Update to Minecraft 1.8
For more information please see http://www.spigotmc.org/
2014-11-28 17:16:30 +11:00

16 lines
808 B
Diff

--- ../work/decompile-bb26c12b/net/minecraft/server/EntityItemFrame.java 2014-11-27 08:59:46.693421882 +1100
+++ src/main/java/net/minecraft/server/EntityItemFrame.java 2014-11-27 08:42:10.176850864 +1100
@@ -27,6 +27,12 @@
return false;
} else if (!damagesource.isExplosion() && this.getItem() != null) {
if (!this.world.isStatic) {
+ // CraftBukkit start - fire EntityDamageEvent
+ if (org.bukkit.craftbukkit.event.CraftEventFactory.handleNonLivingEntityDamageEvent(this, damagesource, f, false) || this.dead) {
+ return true;
+ }
+ // CraftBukkit end
+
this.a(damagesource.getEntity(), false);
this.setItem((ItemStack) null);
}