mirror of
https://github.com/PaperMC/Paper.git
synced 2025-01-10 12:02:36 +01:00
43702a9e10
By: md_5 <git@md-5.net>
14 lines
750 B
Diff
14 lines
750 B
Diff
--- a/net/minecraft/world/level/block/BlockTNT.java
|
|
+++ b/net/minecraft/world/level/block/BlockTNT.java
|
|
@@ -121,6 +121,11 @@
|
|
Entity entity = iprojectile.getOwner();
|
|
|
|
if (iprojectile.isOnFire() && iprojectile.mayInteract(world, blockposition)) {
|
|
+ // CraftBukkit start
|
|
+ if (org.bukkit.craftbukkit.event.CraftEventFactory.callEntityChangeBlockEvent(iprojectile, blockposition, Blocks.AIR.defaultBlockState()).isCancelled()) {
|
|
+ return;
|
|
+ }
|
|
+ // CraftBukkit end
|
|
explode(world, blockposition, entity instanceof EntityLiving ? (EntityLiving) entity : null);
|
|
world.removeBlock(blockposition, false);
|
|
}
|