Fixed EntityDamageByEntityEvent to call for every attackable entity. Fixes BUKKIT-1129, Fixes BUKKIT-1054 and Fixes BUKKIT-147.

This commit is contained in:
feildmaster
2012-03-12 17:55:02 -05:00
committed by EvilSeph
parent c625d00351
commit 4503167283
11 changed files with 72 additions and 185 deletions

View File

@@ -50,6 +50,11 @@ public class EntityEnderCrystal extends Entity {
this.b = 0;
if (this.b <= 0) {
if (!this.world.isStatic) {
// CraftBukkit start - All non-living entities need this
if (org.bukkit.craftbukkit.event.CraftEventFactory.handleNonLivingEntityDamageEvent(this, damagesource, i)) {
return false;
}
// CraftBukkit end
this.die();
this.world.explode(this, this.locX, this.locY, this.locZ, 6.0F); // CraftBukkit - (Entity) null -> this.
} else {