Cleanup MCUtils patch for chunk system

Remove utilities that are unused, as well as replacing
the full chunk map with a concurrentutil implementation.

Additionally, fix the addition/removal of chunks to/from the
full chunk map so that getChunkIfLoaded correctly returns a
non-null chunk when calling the load or unload events.
This commit is contained in:
Spottedleaf 2024-06-19 10:29:03 -07:00
parent c0268ca86e
commit 38428c0d6c
79 changed files with 365 additions and 2552 deletions

View file

@ -125,7 +125,7 @@ index 72f2e81b9905a0d57ed8e2a88578f62d5235c456..7b58b2d6297800c2dcdbf7539e5ab8e7
public static void registerCommands(final MinecraftServer server) {
diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java
index 12f530044d918ddc1ba4b2376419f9ed72283b98..2a2b5205692573c9886a2696f376958809b899ac 100644
index ee86f2cb71b2c8dc85c27635efca3666de7a3cbe..1e6546637c5c2ddf4aacc7a3ea8623ce55059203 100644
--- a/src/main/java/net/minecraft/server/MinecraftServer.java
+++ b/src/main/java/net/minecraft/server/MinecraftServer.java
@@ -258,6 +258,11 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
@ -152,7 +152,7 @@ index 12f530044d918ddc1ba4b2376419f9ed72283b98..2a2b5205692573c9886a2696f3769588
this.logTickMethodTime(i);
this.profiler.pop();
org.spigotmc.WatchdogThread.tick(); // Spigot
@@ -2863,4 +2873,30 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
@@ -2858,4 +2868,30 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
public static record ServerResourcePackInfo(UUID id, String url, String hash, boolean isRequired, @Nullable Component prompt) {
}