diff options
Diffstat (limited to 'patches/server/0026-Further-improve-server-tick-loop.patch')
-rw-r--r-- | patches/server/0026-Further-improve-server-tick-loop.patch | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/patches/server/0026-Further-improve-server-tick-loop.patch b/patches/server/0026-Further-improve-server-tick-loop.patch index 3dab3a2855..c9f08e6061 100644 --- a/patches/server/0026-Further-improve-server-tick-loop.patch +++ b/patches/server/0026-Further-improve-server-tick-loop.patch @@ -12,7 +12,7 @@ Previous implementation did not calculate TPS correctly. Switch to a realistic rolling average and factor in std deviation as an extra reporting variable diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java -index 905dbf6bb3fbbdf7b463c9b9baa59f54b83c3687..9f7d562131c7b4e5bf1e5028c6e4734f73b395d8 100644 +index 8bacbb2289a9e5203766d71be6ba0a31f48b626e..18f03367174651b93682d5e5f4350d8c7e6e3b98 100644 --- a/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java @@ -283,7 +283,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa @@ -33,7 +33,7 @@ index 905dbf6bb3fbbdf7b463c9b9baa59f54b83c3687..9f7d562131c7b4e5bf1e5028c6e4734f public final double[] recentTps = new double[ 3 ]; public final SlackActivityAccountant slackActivityAccountant = new SlackActivityAccountant(); // Spigot end -@@ -1009,6 +1009,57 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa +@@ -1005,6 +1005,57 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa { return ( avg * exp ) + ( tps * ( 1 - exp ) ); } @@ -91,7 +91,7 @@ index 905dbf6bb3fbbdf7b463c9b9baa59f54b83c3687..9f7d562131c7b4e5bf1e5028c6e4734f // Spigot End protected void runServer() { -@@ -1021,26 +1072,33 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa +@@ -1017,26 +1068,33 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa // Spigot start Arrays.fill( recentTps, 20 ); @@ -133,7 +133,7 @@ index 905dbf6bb3fbbdf7b463c9b9baa59f54b83c3687..9f7d562131c7b4e5bf1e5028c6e4734f tickSection = curTime; } // Spigot end -@@ -1050,7 +1108,8 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa +@@ -1046,7 +1104,8 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa this.debugCommandProfiler = new MinecraftServer.TimeProfiler(Util.getNanos(), this.tickCount); } @@ -144,7 +144,7 @@ index 905dbf6bb3fbbdf7b463c9b9baa59f54b83c3687..9f7d562131c7b4e5bf1e5028c6e4734f this.startMetricsRecordingTick(); this.profiler.push("tick"); diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index a5f9e484f597680aea3a95ac27441dc09e1087ec..9251a33715c271e17cad8b9d0de5da444ad25100 100644 +index ad70bb6419bdfa75ffc8ce4f42150097ef0ead0f..8f1d3ac7c59963feb54cba60f749880fd9e8fcd9 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java @@ -2362,6 +2362,17 @@ public final class CraftServer implements Server { |