Allow users to configure the tickNextTickList cap

This commit is contained in:
Zach Brown 2015-03-23 14:40:52 -05:00
parent d22f14e933
commit 7cbda258cc
31 changed files with 97 additions and 73 deletions

View File

@ -1,4 +1,4 @@
From 3411a63f46a535c76039274fc976b2c6eee6fd8b Mon Sep 17 00:00:00 2001
From 75e357a8a366b9f89e20cf0a799aef4f1f238915 Mon Sep 17 00:00:00 2001
From: Zach Brown <zach.brown@destroystokyo.com>
Date: Sat, 7 Mar 2015 21:00:13 -0600
Subject: [PATCH] Configurable fishing time ranges

View File

@ -1,34 +0,0 @@
From 4c87da5a76d6f6d9a35167a7a3a087355402e23c Mon Sep 17 00:00:00 2001
From: Iceee <andrew@opticgaming.tv>
Date: Sat, 7 Mar 2015 20:49:31 -0600
Subject: [PATCH] Fix redstone lag issues
diff --git a/src/main/java/net/minecraft/server/WorldServer.java b/src/main/java/net/minecraft/server/WorldServer.java
index a599869..e27d770 100644
--- a/src/main/java/net/minecraft/server/WorldServer.java
+++ b/src/main/java/net/minecraft/server/WorldServer.java
@@ -610,6 +610,8 @@ public class WorldServer extends World implements IAsyncTaskHandler {
if (i != this.L.size()) {
throw new IllegalStateException("TickNextTick list out of synch");
} else {
+ // PaperSpigot start - No, stop doing this, it affects things like redstone
+ /*
if (i > 1000) {
// CraftBukkit start - If the server has too much to process over time, try to alleviate that
if (i > 20 * 1000) {
@@ -618,7 +620,11 @@ public class WorldServer extends World implements IAsyncTaskHandler {
i = 1000;
}
// CraftBukkit end
+ */
+ if (i > 10000) {
+ i = 10000;
}
+ // PaperSpigot end
this.methodProfiler.a("cleaning");
--
1.9.1

View File

@ -1,4 +1,4 @@
From 2263b5efd50e99d43fbf7c7428a1c4b2fd31b9ef Mon Sep 17 00:00:00 2001
From fb2cc2c1096ef34b2f7a046f14823dcb7f29ee0f Mon Sep 17 00:00:00 2001
From: Zach Brown <zach.brown@destroystokyo.com>
Date: Sat, 7 Mar 2015 21:03:06 -0600
Subject: [PATCH] Allow nerfed mobs to jump

View File

@ -1,4 +1,4 @@
From 8ac9188726669d17232df053a2a70f055552cf2b Mon Sep 17 00:00:00 2001
From 46e90062448f9fe04ef236bce34c4b92442dd9c9 Mon Sep 17 00:00:00 2001
From: Zach Brown <zach.brown@destroystokyo.com>
Date: Sat, 7 Mar 2015 21:07:10 -0600
Subject: [PATCH] Toggle for player interact limiter

View File

@ -1,4 +1,4 @@
From 063a8a59cfd31b7f11ea2f371ed03d0e9bfdd947 Mon Sep 17 00:00:00 2001
From 780b846b8b4db8c88ea2a69dda56eea16ff9fe03 Mon Sep 17 00:00:00 2001
From: gsand <gsandowns@gmail.com>
Date: Sat, 7 Mar 2015 21:35:14 -0600
Subject: [PATCH] Player Exhaustion Multipliers

View File

@ -1,4 +1,4 @@
From 9c4907b8c468bebd5b2d977a22333bd756a611bc Mon Sep 17 00:00:00 2001
From f2298a52883de199283cd20f55fc72b43585dc45 Mon Sep 17 00:00:00 2001
From: Suddenly <suddenly@suddenly.coffee>
Date: Sat, 7 Mar 2015 21:40:48 -0600
Subject: [PATCH] Add configurable despawn distances for living entities

View File

@ -1,11 +1,11 @@
From 7a1085b97d3e2cd5529876d6441556fe08d4b3d4 Mon Sep 17 00:00:00 2001
From bc01a5ab191290ee198332dab953d8d9d76691f4 Mon Sep 17 00:00:00 2001
From: Dmck2b <itallhappenedverysuddenly@gmail.com>
Date: Sat, 7 Mar 2015 21:50:40 -0600
Subject: [PATCH] Allow for toggling of spawn chunks
diff --git a/src/main/java/net/minecraft/server/World.java b/src/main/java/net/minecraft/server/World.java
index 9c98645..383178f 100644
index 13e1a90..32c882e 100644
--- a/src/main/java/net/minecraft/server/World.java
+++ b/src/main/java/net/minecraft/server/World.java
@@ -230,6 +230,7 @@ public abstract class World implements IBlockAccess {

View File

@ -1,4 +1,4 @@
From b4dd019aed5d8da6314dbd840cf89a775f068f1b Mon Sep 17 00:00:00 2001
From c9860a2e12193e696b71bdab28696fd08e55ccce Mon Sep 17 00:00:00 2001
From: Byteflux <byte@byteflux.net>
Date: Sat, 7 Mar 2015 22:03:47 -0600
Subject: [PATCH] Drop falling block entities that are above the specified

View File

@ -1,4 +1,4 @@
From 32dcf754f5c4ce1e23e62fcc8e86b8557b0721b8 Mon Sep 17 00:00:00 2001
From b4b6b413ad6ec16b1e9c236d8c78bca81a299e91 Mon Sep 17 00:00:00 2001
From: Byteflux <byte@byteflux.net>
Date: Sat, 7 Mar 2015 22:17:03 -0600
Subject: [PATCH] Configurable speed for water flowing over lava

View File

@ -1,4 +1,4 @@
From 0b07ded341b1681cb2cee003c84fbb5f764705ce Mon Sep 17 00:00:00 2001
From 259f5e95b81da92d16c768d14b3616f2367ccd72 Mon Sep 17 00:00:00 2001
From: Jedediah Smith <jedediah@silencegreys.com>
Date: Sat, 7 Mar 2015 22:52:21 -0600
Subject: [PATCH] Player affects spawning API
@ -65,7 +65,7 @@ index aeb0a44..7df5b84 100644
biomebase_biomemeta = worldserver.a(enumcreaturetype, blockposition2);
if (biomebase_biomemeta == null) {
diff --git a/src/main/java/net/minecraft/server/World.java b/src/main/java/net/minecraft/server/World.java
index 383178f..1f9da7a 100644
index 32c882e..c563d62 100644
--- a/src/main/java/net/minecraft/server/World.java
+++ b/src/main/java/net/minecraft/server/World.java
@@ -3135,4 +3135,50 @@ public abstract class World implements IBlockAccess {

View File

@ -1,4 +1,4 @@
From 866eff9b3494a65ad776257b09a4826e0ffc4de0 Mon Sep 17 00:00:00 2001
From c2c7d4fd0768eea36066557bbc4b6c3f48907499 Mon Sep 17 00:00:00 2001
From: Zach Brown <zach.brown@destroystokyo.com>
Date: Sat, 7 Mar 2015 22:55:25 -0600
Subject: [PATCH] Show 'PaperSpigot' in client crashes, server lists, and

View File

@ -1,4 +1,4 @@
From d8b7ac10997877efad844eb952c8bea62a5fceff Mon Sep 17 00:00:00 2001
From 4b60804cd3d134409b1bffb6557b24bb0cccc976 Mon Sep 17 00:00:00 2001
From: Zach Brown <zach.brown@destroystokyo.com>
Date: Sat, 7 Mar 2015 22:57:07 -0600
Subject: [PATCH] RIP metrics

View File

@ -1,4 +1,4 @@
From a79300041630ddb0bd165871e199d8bdc604aacb Mon Sep 17 00:00:00 2001
From fcfba0e0c4e6d55ab0625bcb2d5f157e75277a58 Mon Sep 17 00:00:00 2001
From: Byteflux <byte@byteflux.net>
Date: Sun, 8 Mar 2015 01:06:14 -0600
Subject: [PATCH] Remove invalid mob spawner tile entities

View File

@ -1,11 +1,11 @@
From afcd29c0fb52110b9aa263f54f21c206ca55b333 Mon Sep 17 00:00:00 2001
From 0ed1de26c7933ca520548d35cefc535b278aff93 Mon Sep 17 00:00:00 2001
From: Aikar <aikar@aikar.co>
Date: Sun, 8 Mar 2015 01:56:22 -0600
Subject: [PATCH] Optimize TileEntity Ticking
diff --git a/src/main/java/net/minecraft/server/TileEntity.java b/src/main/java/net/minecraft/server/TileEntity.java
index a829555..2118c08 100644
index 0de85da..0a21872 100644
--- a/src/main/java/net/minecraft/server/TileEntity.java
+++ b/src/main/java/net/minecraft/server/TileEntity.java
@@ -21,6 +21,12 @@ public abstract class TileEntity {
@ -74,7 +74,7 @@ index f75e2de..7119612 100644
if (this.e instanceof BlockDaylightDetector) {
((BlockDaylightDetector) this.e).f(this.world, this.position);
diff --git a/src/main/java/net/minecraft/server/World.java b/src/main/java/net/minecraft/server/World.java
index 1f9da7a..1761ea7 100644
index c563d62..15fe976 100644
--- a/src/main/java/net/minecraft/server/World.java
+++ b/src/main/java/net/minecraft/server/World.java
@@ -65,7 +65,7 @@ public abstract class World implements IBlockAccess {

View File

@ -1,4 +1,4 @@
From b241364542febefab32e12ba3079bdf53dd1eb0b Mon Sep 17 00:00:00 2001
From 78cd8cc1024bdc966f9af150ec1281a071375be4 Mon Sep 17 00:00:00 2001
From: Iceee <andrew@opticgaming.tv>
Date: Sun, 8 Mar 2015 03:16:39 -0500
Subject: [PATCH] Move sound handling out of the chest tick loop

View File

@ -1,4 +1,4 @@
From 14d9eb1bb9fd025d44c9383e57096e00f66cc6e1 Mon Sep 17 00:00:00 2001
From aeaa678d95303de968269960a3c48dc0ac0fd46b Mon Sep 17 00:00:00 2001
From: Iceee <andrew@opticgaming.tv>
Date: Sun, 8 Mar 2015 03:34:15 -0500
Subject: [PATCH] Remove certain entities that fly through unloaded chunks
@ -70,7 +70,7 @@ index 2d22327..50423eb 100644
this.motY *= 0.9800000190734863D;
this.motZ *= 0.9800000190734863D;
diff --git a/src/main/java/net/minecraft/server/World.java b/src/main/java/net/minecraft/server/World.java
index 1761ea7..564f9a7 100644
index 15fe976..7425bbf 100644
--- a/src/main/java/net/minecraft/server/World.java
+++ b/src/main/java/net/minecraft/server/World.java
@@ -1174,6 +1174,7 @@ public abstract class World implements IBlockAccess {

View File

@ -1,4 +1,4 @@
From 113e9f7f45f54115339cf463c3e6696e331e479b Mon Sep 17 00:00:00 2001
From 176a4043886d2e4298a9350fe1501375274b489e Mon Sep 17 00:00:00 2001
From: gsand <gsandowns@gmail.com>
Date: Sun, 8 Mar 2015 03:41:33 -0500
Subject: [PATCH] Configurable strength and weakness effect modifiers

View File

@ -1,4 +1,4 @@
From 8c9305592b06bbdb8eafcdc2ce97f7e95dc0115b Mon Sep 17 00:00:00 2001
From 1d624caf17dd3d571fd289c167b7fc713fbb3346 Mon Sep 17 00:00:00 2001
From: Dmck2b <suddenly@suddenly.coffee>
Date: Sun, 8 Mar 2015 03:45:49 -0500
Subject: [PATCH] Temporary fix for rails dupe

View File

@ -1,4 +1,4 @@
From a26a02fd43b1d4bba8335252b6e607cf2689f599 Mon Sep 17 00:00:00 2001
From 6bcd687996b2504fa884f0f50aac658a5bc4d425 Mon Sep 17 00:00:00 2001
From: Aikar <aikar@aikar.co>
Date: Sun, 8 Mar 2015 03:47:32 -0500
Subject: [PATCH] Further improve server tick loop

View File

@ -1,4 +1,4 @@
From abf69c7aee5dbfab5cc1f9543d85e9bbaf944ce7 Mon Sep 17 00:00:00 2001
From 5cff72e10eb8de4fb44661db5cb083957cd0bbeb Mon Sep 17 00:00:00 2001
From: Aikar <aikar@aikar.co>
Date: Fri, 28 Nov 2014 13:20:22 -0600
Subject: [PATCH] Only refresh abilities if needed

View File

@ -1,4 +1,4 @@
From ebe7c6a18c22763d684214011d582a067fdc3b2b Mon Sep 17 00:00:00 2001
From f1976dd6704c5cad38c48a61834c781cad708264 Mon Sep 17 00:00:00 2001
From: Aikar <aikar@aikar.co>
Date: Sun, 8 Mar 2015 04:03:56 -0500
Subject: [PATCH] Player lookup improvements

View File

@ -1,4 +1,4 @@
From 66292f7e9fb064cda6d087b23a5569f19a4c3175 Mon Sep 17 00:00:00 2001
From e3dce716d008beed3006863b1e558287be5e7535 Mon Sep 17 00:00:00 2001
From: gsand <gsandowns@gmail.com>
Date: Sun, 8 Mar 2015 04:10:02 -0500
Subject: [PATCH] Configurable game mechanics changes

View File

@ -1,11 +1,11 @@
From f0be1406d6177779cc38e5818fe8948fad68aaaf Mon Sep 17 00:00:00 2001
From 736c3c56bbfe94414bc4c17d6e44e74c2d2e9955 Mon Sep 17 00:00:00 2001
From: Aikar <aikar@aikar.co>
Date: Thu, 6 Nov 2014 18:29:20 -0600
Subject: [PATCH] Add async chunk load API
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
index 7a1f2c7..4c55e68 100644
index 2bbe104..d8401c4 100644
--- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
+++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
@@ -120,6 +120,24 @@ public class CraftWorld implements World {

View File

@ -1,4 +1,4 @@
From ec24a84a17c631de797f9e995f67bb0ede42dda1 Mon Sep 17 00:00:00 2001
From 3d8002fbf829ebd6cb4e4d771334fa935e4419e5 Mon Sep 17 00:00:00 2001
From: Byteflux <byte@byteflux.net>
Date: Sun, 30 Nov 2014 18:58:07 -0600
Subject: [PATCH] Allow specified ItemStacks to retain their invalid data

View File

@ -1,4 +1,4 @@
From 75dede09c4970d9dee8438c4f1430dc1e8ef77b2 Mon Sep 17 00:00:00 2001
From 519f0b747ea7168c9ddf33d305f62799f5c7297a Mon Sep 17 00:00:00 2001
From: Aikar <aikar@aikar.co>
Date: Sun, 8 Mar 2015 04:23:41 -0500
Subject: [PATCH] Add TNT source location API

View File

@ -1,11 +1,11 @@
From ac5c2cf4282f96547d2c96251ec2bb6865f1af6e Mon Sep 17 00:00:00 2001
From e441393dd8fc9d33934c0fde7733cd91aee6be4e Mon Sep 17 00:00:00 2001
From: Aikar <aikar@aikar.co>
Date: Sun, 8 Mar 2015 04:37:23 -0500
Subject: [PATCH] Prevent tile entity and entity crashes
diff --git a/src/main/java/net/minecraft/server/TileEntity.java b/src/main/java/net/minecraft/server/TileEntity.java
index 2118c08..bd8278a 100644
index 0a21872..bbcca2a 100644
--- a/src/main/java/net/minecraft/server/TileEntity.java
+++ b/src/main/java/net/minecraft/server/TileEntity.java
@@ -163,7 +163,12 @@ public abstract class TileEntity {
@ -23,7 +23,7 @@ index 2118c08..bd8278a 100644
public String a() throws Exception {
int i = Block.getId(TileEntity.this.world.getType(TileEntity.this.position).getBlock());
diff --git a/src/main/java/net/minecraft/server/World.java b/src/main/java/net/minecraft/server/World.java
index 564f9a7..4a71d0d 100644
index 7425bbf..c6d82db 100644
--- a/src/main/java/net/minecraft/server/World.java
+++ b/src/main/java/net/minecraft/server/World.java
@@ -1432,10 +1432,13 @@ public abstract class World implements IBlockAccess {

View File

@ -1,4 +1,4 @@
From bf77b5dc899e2b259abc934f6af93cc4acc111e3 Mon Sep 17 00:00:00 2001
From 6d10b8134f0cf1f24b7690f1936eda3a4388acc4 Mon Sep 17 00:00:00 2001
From: Zach Brown <zach.brown@destroystokyo.com>
Date: Mon, 23 Feb 2015 14:57:28 -0600
Subject: [PATCH] Configurable top of nether void damage

View File

@ -1,4 +1,4 @@
From 89d4f3637d8965b1c72c460a8939ff529e9f1609 Mon Sep 17 00:00:00 2001
From dba1e342404e73aa510c825ffa84e59bff427690 Mon Sep 17 00:00:00 2001
From: Zach <zach.brown@destroystokyo.com>
Date: Fri, 13 Feb 2015 14:49:30 -0600
Subject: [PATCH] Enderman drop the block they're holding when they die

View File

@ -1,4 +1,4 @@
From 359beb44876591e93dfec57afbd13e75a43891ea Mon Sep 17 00:00:00 2001
From 6f6ad58d8f5db70d6968bef9d6dc604381ca85ad Mon Sep 17 00:00:00 2001
From: Zach Brown <zach.brown@destroystokyo.com>
Date: Sun, 8 Mar 2015 04:52:37 -0500
Subject: [PATCH] PaperSpigot TNT Changes
@ -67,7 +67,7 @@ index 1daba4e..dd1ad68 100644
+ }
}
diff --git a/src/main/java/org/github/paperspigot/PaperSpigotWorldConfig.java b/src/main/java/org/github/paperspigot/PaperSpigotWorldConfig.java
index a6d8532..ceb5e64 100644
index a6d8532..1915a7c 100644
--- a/src/main/java/org/github/paperspigot/PaperSpigotWorldConfig.java
+++ b/src/main/java/org/github/paperspigot/PaperSpigotWorldConfig.java
@@ -192,4 +192,35 @@ public class PaperSpigotWorldConfig
@ -103,8 +103,8 @@ index a6d8532..ceb5e64 100644
+ System.err.println( " Many TNT Related Settings Have Moved " );
+ System.err.println( " Please check your config in paper.yml! " );
+ System.err.println( "==========================================" );
+ }
+ }
+ }
}
--
1.9.1

View File

@ -1,4 +1,4 @@
From f542fa5ba10ffa2a7ee41cd7db5d49c750ecd11a Mon Sep 17 00:00:00 2001
From 3a6dea881c8f50416d7b78d18383e7b211c61656 Mon Sep 17 00:00:00 2001
From: Zach Brown <zach.brown@destroystokyo.com>
Date: Thu, 5 Mar 2015 15:30:06 -0600
Subject: [PATCH] Check online mode before converting and renaming player data

View File

@ -0,0 +1,58 @@
From c42571ad2dde931065e837927349fa1d157f53e3 Mon Sep 17 00:00:00 2001
From: Iceee <andrew@opticgaming.tv>
Date: Sat, 7 Mar 2015 20:49:31 -0600
Subject: [PATCH] Fix redstone lag issues
diff --git a/src/main/java/net/minecraft/server/WorldServer.java b/src/main/java/net/minecraft/server/WorldServer.java
index a599869..5d73d88 100644
--- a/src/main/java/net/minecraft/server/WorldServer.java
+++ b/src/main/java/net/minecraft/server/WorldServer.java
@@ -22,7 +22,6 @@ import java.util.logging.Level;
import org.bukkit.WeatherType;
import org.bukkit.block.BlockState;
-import org.bukkit.craftbukkit.util.LongHash;
import org.bukkit.event.block.BlockFormEvent;
import org.bukkit.event.weather.LightningStrikeEvent;
@@ -610,6 +609,8 @@ public class WorldServer extends World implements IAsyncTaskHandler {
if (i != this.L.size()) {
throw new IllegalStateException("TickNextTick list out of synch");
} else {
+ // PaperSpigot start - No, stop doing this, it affects things like redstone
+ /*
if (i > 1000) {
// CraftBukkit start - If the server has too much to process over time, try to alleviate that
if (i > 20 * 1000) {
@@ -618,7 +619,11 @@ public class WorldServer extends World implements IAsyncTaskHandler {
i = 1000;
}
// CraftBukkit end
+ */
+ if (i > paperSpigotConfig.tickNextTickCap) {
+ i = paperSpigotConfig.tickNextTickCap;
}
+ // PaperSpigot end
this.methodProfiler.a("cleaning");
diff --git a/src/main/java/org/github/paperspigot/PaperSpigotWorldConfig.java b/src/main/java/org/github/paperspigot/PaperSpigotWorldConfig.java
index 1915a7c..46412dd 100644
--- a/src/main/java/org/github/paperspigot/PaperSpigotWorldConfig.java
+++ b/src/main/java/org/github/paperspigot/PaperSpigotWorldConfig.java
@@ -223,4 +223,11 @@ public class PaperSpigotWorldConfig
System.err.println( "==========================================" );
}
}
+
+ public int tickNextTickCap;
+ private void tickNextTickCap()
+ {
+ tickNextTickCap = 10000; // Higher values will be friendlier to vanilla style mechanics but may hurt performance
+ log( "WorldServer TickNextTick cap set at " + tickNextTickCap );
+ }
}
--
1.9.1