--- a/net/minecraft/world/level/TickListServer.java +++ b/net/minecraft/world/level/TickListServer.java @@ -47,11 +47,17 @@ public void b() { int i = this.tickNextTickList.size(); - if (i != this.tickNextTickSet.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 } Iterator> iterator = this.tickNextTickList.iterator(); @@ -89,7 +95,7 @@ throw new ReportedException(crashreport); } } else { - this.a(nextticklistentry.pos, nextticklistentry.b(), 0); + this.a(nextticklistentry.pos, (T) nextticklistentry.b(), 0); // CraftBukkit - decompile error } }