3
0
Mirror von https://github.com/PaperMC/Paper.git synchronisiert 2024-12-25 07:40:06 +01:00
Paper/nms-patches/BlockDaylightDetector.patch

11 Zeilen
660 B
Diff

2015-05-25 12:37:24 +02:00
--- a/net/minecraft/server/BlockDaylightDetector.java
+++ b/net/minecraft/server/BlockDaylightDetector.java
2016-02-29 22:32:46 +01:00
@@ -45,6 +45,7 @@
2016-02-29 22:32:46 +01:00
i = MathHelper.clamp(i, 0, 15);
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);
}