@@ -25,7 +25,7 @@
|
||||
}
|
||||
}
|
||||
|
||||
@@ -75,9 +84,22 @@
|
||||
@@ -75,10 +84,23 @@
|
||||
return false;
|
||||
} else {
|
||||
if (!this.dead && !this.world.isClientSide) {
|
||||
@@ -36,16 +36,17 @@
|
||||
+ // CraftBukkit end
|
||||
this.die();
|
||||
if (!this.world.isClientSide) {
|
||||
- this.world.explode((Entity) null, this.locX, this.locY, this.locZ, 6.0F, true);
|
||||
+ // CraftBukkit start
|
||||
+ ExplosionPrimeEvent event = new ExplosionPrimeEvent(this.getBukkitEntity(), 6.0F, true);
|
||||
+ this.world.getServer().getPluginManager().callEvent(event);
|
||||
+ if (event.isCancelled()) {
|
||||
+ this.dead = false;
|
||||
+ return false;
|
||||
+ }
|
||||
+ this.world.explode(this, this.locX, this.locY, this.locZ, event.getRadius(), event.getFire());
|
||||
+ // CraftBukkit end
|
||||
if (!damagesource.isExplosion()) {
|
||||
- this.world.explode((Entity) null, this.locX, this.locY, this.locZ, 6.0F, true);
|
||||
+ // CraftBukkit start
|
||||
+ ExplosionPrimeEvent event = new ExplosionPrimeEvent(this.getBukkitEntity(), 6.0F, true);
|
||||
+ this.world.getServer().getPluginManager().callEvent(event);
|
||||
+ if (event.isCancelled()) {
|
||||
+ this.dead = false;
|
||||
+ return false;
|
||||
+ }
|
||||
+ this.world.explode(this, this.locX, this.locY, this.locZ, event.getRadius(), event.getFire());
|
||||
+ // CraftBukkit end
|
||||
}
|
||||
|
||||
this.a(damagesource);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user