#1209: Clean up various patches
By: Owen1212055 <23108066+Owen1212055@users.noreply.github.com>
This commit is contained in:
@@ -25,7 +25,7 @@
|
||||
}
|
||||
}
|
||||
|
||||
@@ -95,11 +104,24 @@
|
||||
@@ -95,11 +104,23 @@
|
||||
return false;
|
||||
} else {
|
||||
if (!this.isRemoved() && !this.level().isClientSide) {
|
||||
@@ -40,8 +40,7 @@
|
||||
|
||||
- this.level().explode(this, damagesource1, (ExplosionDamageCalculator) null, this.getX(), this.getY(), this.getZ(), 6.0F, false, World.a.BLOCK);
|
||||
+ // CraftBukkit start
|
||||
+ ExplosionPrimeEvent event = new ExplosionPrimeEvent(this.getBukkitEntity(), 6.0F, false);
|
||||
+ this.level().getCraftServer().getPluginManager().callEvent(event);
|
||||
+ ExplosionPrimeEvent event = CraftEventFactory.callExplosionPrimeEvent(this, 6.0F, false);
|
||||
+ if (event.isCancelled()) {
|
||||
+ this.unsetRemoved();
|
||||
+ return false;
|
||||
|
||||
@@ -75,7 +75,7 @@
|
||||
|
||||
if (canDestroy(iblockdata)) {
|
||||
+ // CraftBukkit start
|
||||
+ if (CraftEventFactory.callEntityChangeBlockEvent(this, blockposition, Blocks.AIR.defaultBlockState()).isCancelled()) {
|
||||
+ if (!CraftEventFactory.callEntityChangeBlockEvent(this, blockposition, Blocks.AIR.defaultBlockState())) {
|
||||
+ continue;
|
||||
+ }
|
||||
+ // CraftBukkit end
|
||||
|
||||
Reference in New Issue
Block a user