aboutsummaryrefslogtreecommitdiffhomepage
path: root/patch-remap/mache-spigotflower-stripped/net/minecraft/world/level/block/SnowLayerBlock.java.patch
diff options
context:
space:
mode:
Diffstat (limited to 'patch-remap/mache-spigotflower-stripped/net/minecraft/world/level/block/SnowLayerBlock.java.patch')
-rw-r--r--patch-remap/mache-spigotflower-stripped/net/minecraft/world/level/block/SnowLayerBlock.java.patch23
1 files changed, 23 insertions, 0 deletions
diff --git a/patch-remap/mache-spigotflower-stripped/net/minecraft/world/level/block/SnowLayerBlock.java.patch b/patch-remap/mache-spigotflower-stripped/net/minecraft/world/level/block/SnowLayerBlock.java.patch
new file mode 100644
index 0000000000..5aeff46aa6
--- /dev/null
+++ b/patch-remap/mache-spigotflower-stripped/net/minecraft/world/level/block/SnowLayerBlock.java.patch
@@ -0,0 +1,23 @@
+--- a/net/minecraft/world/level/block/SnowLayerBlock.java
++++ b/net/minecraft/world/level/block/SnowLayerBlock.java
+@@ -107,11 +97,15 @@
+ }
+
+ @Override
+- @Override
+- public void randomTick(BlockState blockstate, ServerLevel serverlevel, BlockPos blockpos, RandomSource randomsource) {
+- if (serverlevel.getBrightness(LightLayer.BLOCK, blockpos) > 11) {
+- dropResources(blockstate, serverlevel, blockpos);
+- serverlevel.removeBlock(blockpos, false);
++ public void randomTick(IBlockData state, ServerLevel level, BlockPos pos, RandomSource random) {
++ if (level.getBrightness(EnumSkyBlock.BLOCK, pos) > 11) {
++ // CraftBukkit start
++ if (org.bukkit.craftbukkit.event.CraftEventFactory.callBlockFadeEvent(level, pos, Blocks.AIR.defaultBlockState()).isCancelled()) {
++ return;
++ }
++ // CraftBukkit end
++ dropResources(state, level, pos);
++ level.removeBlock(pos, false);
+ }
+
+ }