Patrone.cc-src-skid-me/toothless/server/nms-patches/EntityFireworks.patch

12 lines
475 B
Diff
Raw Permalink Normal View History

2019-06-19 05:50:21 +02:00
--- a/net/minecraft/server/EntityFireworks.java
+++ b/net/minecraft/server/EntityFireworks.java
@@ -78,7 +78,7 @@
}
if (!this.world.isClientSide && this.ticksFlown > this.expectedLifespan) {
- this.world.broadcastEntityEffect(this, (byte) 17);
+ if (!org.bukkit.craftbukkit.event.CraftEventFactory.callFireworkExplodeEvent(this).isCancelled()) this.world.broadcastEntityEffect(this, (byte) 17);
this.die();
}