0
0
mirror of https://hub.spigotmc.org/stash/scm/spigot/craftbukkit.git synced 2024-11-25 13:56:14 +00:00
craftbukkit/nms-patches/net/minecraft/world/item/enchantment/effects/ReplaceBlock.patch
2024-06-14 01:05:00 +10:00

12 lines
814 B
Diff

--- a/net/minecraft/world/item/enchantment/effects/ReplaceBlock.java
+++ b/net/minecraft/world/item/enchantment/effects/ReplaceBlock.java
@@ -26,7 +26,7 @@
if ((Boolean) this.predicate.map((blockpredicate) -> {
return blockpredicate.test(worldserver, blockposition);
- }).orElse(true) && worldserver.setBlockAndUpdate(blockposition, this.blockState.getState(entity.getRandom(), blockposition))) {
+ }).orElse(true) && org.bukkit.craftbukkit.event.CraftEventFactory.handleBlockFormEvent(worldserver, blockposition, this.blockState.getState(entity.getRandom(), blockposition), entity)) { // CraftBukkit - Call EntityBlockFormEvent
this.triggerGameEvent.ifPresent((holder) -> {
worldserver.gameEvent(entity, holder, blockposition);
});