Paper/Spigot-Server-Patches/0378-Don-t-update-snapshot-blockstates.patch
Zach Brown 684bd2adbc
Upstate upstream B/CB
--- work/Bukkit
Submodule work/Bukkit 9a793cce8..0c1d258bb:
  > Make PigZapEvent extend EntityTransformEvent

--- work/CraftBukkit
Submodule work/CraftBukkit ee6684bba..6a398ac44:
  > SPIGOT-4511: Trident doesn't lose durability
  > Tweak outdated windows
2018-12-02 18:31:09 -05:00

27 lines
1.0 KiB
Diff

From 96c0dacc79b25fda35fad6855acdb01770785d04 Mon Sep 17 00:00:00 2001
From: Matthew Miller <mnmiller1@me.com>
Date: Fri, 5 Oct 2018 15:46:46 +1000
Subject: [PATCH] Don't update snapshot blockstates
diff --git a/src/main/java/org/bukkit/craftbukkit/block/CraftBlockEntityState.java b/src/main/java/org/bukkit/craftbukkit/block/CraftBlockEntityState.java
index d4d9c5fc5..f5c6dbd85 100644
--- a/src/main/java/org/bukkit/craftbukkit/block/CraftBlockEntityState.java
+++ b/src/main/java/org/bukkit/craftbukkit/block/CraftBlockEntityState.java
@@ -131,7 +131,11 @@ public class CraftBlockEntityState<T extends TileEntity> extends CraftBlockState
TileEntity tile = getTileEntityFromWorld();
if (isApplicable(tile)) {
- applyTo(tileEntityClass.cast(tile));
+ // Paper start
+ if (!snapshotDisabled) {
+ applyTo(tileEntityClass.cast(tile));
+ }
+ // Paper end
tile.update();
}
}
--
2.19.1