3
0
Mirror von https://github.com/PaperMC/Paper.git synchronisiert 2024-11-16 13:00:06 +01:00
Paper/nms-patches/BlockDaylightDetector.patch
2018-07-15 10:00:00 +10:00

11 Zeilen
622 B
Diff

--- a/net/minecraft/server/BlockDaylightDetector.java
+++ b/net/minecraft/server/BlockDaylightDetector.java
@@ -36,6 +36,7 @@
i = MathHelper.clamp(i, 0, 15);
if (((Integer) iblockdata.get(BlockDaylightDetector.POWER)).intValue() != i) {
+ i = org.bukkit.craftbukkit.event.CraftEventFactory.callRedstoneChange(world, blockposition, ((Integer) iblockdata.get(POWER)), i).getNewCurrent(); // CraftBukkit - Call BlockRedstoneEvent
world.setTypeAndData(blockposition, (IBlockData) iblockdata.set(BlockDaylightDetector.POWER, Integer.valueOf(i)), 3);
}