MythicNetwork/MythicSpigot-master/TacoSpigot-Server/nms-patches/BlockDaylightDetector.patch

11 lines
630 B
Diff
Raw Normal View History

2023-05-25 01:58:23 +02:00
--- a/net/minecraft/server/BlockDaylightDetector.java
+++ b/net/minecraft/server/BlockDaylightDetector.java
@@ -41,6 +41,7 @@
}
if (((Integer) iblockdata.get(BlockDaylightDetector.POWER)).intValue() != i) {
+ i = org.bukkit.craftbukkit.event.CraftEventFactory.callRedstoneChange(world, blockposition.getX(), blockposition.getY(), blockposition.getZ(), ((Integer) iblockdata.get(POWER)), i).getNewCurrent(); // CraftBukkit - Call BlockRedstoneEvent
world.setTypeAndData(blockposition, iblockdata.set(BlockDaylightDetector.POWER, Integer.valueOf(i)), 3);
}