From f42abdfad375a4a99acff828321fe5abc97073a8 Mon Sep 17 00:00:00 2001 From: Gero Date: Mon, 19 Feb 2024 17:39:59 +0100 Subject: [PATCH] Configurable max block/fluid ticks --- .../minecraft/server/level/ServerLevel.java.patch | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/paper-server/patches/sources/net/minecraft/server/level/ServerLevel.java.patch b/paper-server/patches/sources/net/minecraft/server/level/ServerLevel.java.patch index 1cafe41f2d..34405e9189 100644 --- a/paper-server/patches/sources/net/minecraft/server/level/ServerLevel.java.patch +++ b/paper-server/patches/sources/net/minecraft/server/level/ServerLevel.java.patch @@ -325,6 +325,18 @@ if (this.getGameRules().getBoolean(GameRules.RULE_WEATHER_CYCLE) && this.isRaining()) { this.resetWeatherCycle(); } +@@ -325,9 +495,9 @@ + if (!this.isDebug() && flag) { + j = this.getGameTime(); + gameprofilerfiller.push("blockTicks"); +- this.blockTicks.tick(j, 65536, this::tickBlock); ++ this.blockTicks.tick(j, paperConfig().environment.maxBlockTicks, this::tickBlock); // Paper - configurable max block ticks + gameprofilerfiller.popPush("fluidTicks"); +- this.fluidTicks.tick(j, 65536, this::tickFluid); ++ this.fluidTicks.tick(j, paperConfig().environment.maxFluidTicks, this::tickFluid); // Paper - configurable max fluid ticks + gameprofilerfiller.pop(); + } + @@ -345,7 +515,7 @@ this.handlingTick = false;