diff options
author | Noah van der Aa <[email protected]> | 2024-10-31 22:30:18 +0100 |
---|---|---|
committer | GitHub <[email protected]> | 2024-10-31 22:30:18 +0100 |
commit | 7ee48350744b09adea3beb75249d971d31d47779 (patch) | |
tree | 0b3aaded496644c6ad1bfb228476f5fed49db549 /patches/server/0702-Throw-exception-on-world-create-while-being-ticked.patch | |
parent | c5c125079c47f35c6b91d8c989964cd86293ef86 (diff) | |
download | Paper-7ee48350744b09adea3beb75249d971d31d47779.tar.gz Paper-7ee48350744b09adea3beb75249d971d31d47779.zip |
Correctly clear explosion density cache(#11541)
Diffstat (limited to 'patches/server/0702-Throw-exception-on-world-create-while-being-ticked.patch')
-rw-r--r-- | patches/server/0702-Throw-exception-on-world-create-while-being-ticked.patch | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/patches/server/0702-Throw-exception-on-world-create-while-being-ticked.patch b/patches/server/0702-Throw-exception-on-world-create-while-being-ticked.patch index 75ec8c003c..61105fee38 100644 --- a/patches/server/0702-Throw-exception-on-world-create-while-being-ticked.patch +++ b/patches/server/0702-Throw-exception-on-world-create-while-being-ticked.patch @@ -7,7 +7,7 @@ There are no plans to support creating worlds while worlds are being ticked themselvess. diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java -index a836ea518bc6d8ddd7c6484038d3d712b3fb13cf..aa9a4a0f35d0200777bdc83520ba82a970bfa900 100644 +index 57c52a30d284332361f28d6138d3c5f1fc6d52bd..25e2baf2109b27887e4b3631d948907d9d8d65a2 100644 --- a/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java @@ -327,6 +327,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa @@ -18,7 +18,7 @@ index a836ea518bc6d8ddd7c6484038d3d712b3fb13cf..aa9a4a0f35d0200777bdc83520ba82a9 public static <S extends MinecraftServer> S spin(Function<Thread, S> serverFactory) { AtomicReference<S> atomicreference = new AtomicReference(); -@@ -1627,7 +1628,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa +@@ -1626,7 +1627,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa gameprofilerfiller.push("commandFunctions"); this.getFunctions().tick(); gameprofilerfiller.popPush("levels"); @@ -27,7 +27,7 @@ index a836ea518bc6d8ddd7c6484038d3d712b3fb13cf..aa9a4a0f35d0200777bdc83520ba82a9 // CraftBukkit start // Run tasks that are waiting on processing -@@ -1655,6 +1656,8 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa +@@ -1654,6 +1655,8 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa } } @@ -38,7 +38,7 @@ index a836ea518bc6d8ddd7c6484038d3d712b3fb13cf..aa9a4a0f35d0200777bdc83520ba82a9 worldserver.hasPhysicsEvent = org.bukkit.event.block.BlockPhysicsEvent.getHandlerList().getRegisteredListeners().length > 0; // Paper - BlockPhysicsEvent @@ -1687,6 +1690,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa gameprofilerfiller.pop(); - gameprofilerfiller.pop(); + worldserver.explosionDensityCache.clear(); // Paper - Optimize explosions } + this.isIteratingOverLevels = false; // Paper - Throw exception on world create while being ticked |