diff --git a/paper-server/patches/sources/net/minecraft/server/level/ServerChunkCache.java.patch b/paper-server/patches/sources/net/minecraft/server/level/ServerChunkCache.java.patch index ef818894a2..5685bf9e2b 100644 --- a/paper-server/patches/sources/net/minecraft/server/level/ServerChunkCache.java.patch +++ b/paper-server/patches/sources/net/minecraft/server/level/ServerChunkCache.java.patch @@ -106,8 +106,9 @@ ProfilerFiller gameprofilerfiller = Profiler.get(); gameprofilerfiller.push("purge"); +- if (this.level.tickRateManager().runsNormally() || !tickChunks) { + this.level.timings.doChunkMap.startTiming(); // Spigot - if (this.level.tickRateManager().runsNormally() || !tickChunks) { ++ if (this.level.tickRateManager().runsNormally() || !tickChunks || this.level.spigotConfig.unloadFrozenChunks) { // Spigot this.distanceManager.purgeStaleTickets(); } diff --git a/paper-server/src/main/java/org/spigotmc/SpigotWorldConfig.java b/paper-server/src/main/java/org/spigotmc/SpigotWorldConfig.java index 974e679ff2..a6d2ce801b 100644 --- a/paper-server/src/main/java/org/spigotmc/SpigotWorldConfig.java +++ b/paper-server/src/main/java/org/spigotmc/SpigotWorldConfig.java @@ -393,4 +393,9 @@ public class SpigotWorldConfig private void belowZeroGenerationInExistingChunks() { this.belowZeroGenerationInExistingChunks = this.getBoolean("below-zero-generation-in-existing-chunks", true); } + + public boolean unloadFrozenChunks; + private void unloadFrozenChunks() { + this.unloadFrozenChunks = this.getBoolean("unload-frozen-chunks", false); + } }