3
0
Mirror von https://github.com/PaperMC/Paper.git synchronisiert 2024-12-29 09:30:07 +01:00
Paper/nms-patches/TickListServer.patch

32 Zeilen
1.2 KiB
Diff

2018-07-15 02:00:00 +02:00
--- a/net/minecraft/server/TickListServer.java
+++ b/net/minecraft/server/TickListServer.java
2020-06-25 02:00:00 +02:00
@@ -36,11 +36,17 @@
2019-07-20 01:00:00 +02:00
public void b() {
2018-07-15 02:00:00 +02:00
int i = this.nextTickList.size();
- if (i != this.nextTickListHash.size()) {
+ if (false) { // CraftBukkit
throw new IllegalStateException("TickNextTick list out of synch");
} else {
if (i > 65536) {
- i = 65536;
+ // CraftBukkit start - If the server has too much to process over time, try to alleviate that
+ if (i > 20 * 65536) {
+ i = i / 20;
+ } else {
+ i = 65536;
+ }
+ // CraftBukkit end
}
2020-06-25 02:00:00 +02:00
ChunkProviderServer chunkproviderserver = this.e.getChunkProvider();
@@ -79,7 +85,7 @@
2019-05-27 22:30:00 +02:00
throw new ReportedException(crashreport);
}
} else {
- this.a(nextticklistentry.a, nextticklistentry.b(), 0);
+ this.a(nextticklistentry.a, (T) nextticklistentry.b(), 0); // CraftBukkit - decompile error
}
}