From 6d984b9d484fc5c4de82da88f1bbbfcbd9cbed71 Mon Sep 17 00:00:00 2001 From: Aikar Date: Tue, 5 Apr 2016 19:42:22 -0400 Subject: [PATCH] Don't spam reload spawn chunks in nether/end diff --git a/src/main/java/net/minecraft/server/World.java b/src/main/java/net/minecraft/server/World.java index 46b1323..e5a2a65 100644 --- a/src/main/java/net/minecraft/server/World.java +++ b/src/main/java/net/minecraft/server/World.java @@ -3210,6 +3210,7 @@ public abstract class World implements IBlockAccess { return this.N; } + public boolean shouldStayLoaded(int i, int j) { return e(i, j); } // Paper - OBFHELPER public boolean e(int i, int j) { BlockPosition blockposition = this.getSpawn(); int k = i * 16 + 8 - blockposition.getX(); diff --git a/src/main/java/net/minecraft/server/WorldProvider.java b/src/main/java/net/minecraft/server/WorldProvider.java index 660f3bc..9adadaf 100644 --- a/src/main/java/net/minecraft/server/WorldProvider.java +++ b/src/main/java/net/minecraft/server/WorldProvider.java @@ -137,6 +137,6 @@ public abstract class WorldProvider { public void s() {} public boolean c(int i, int j) { - return true; + return !this.b.shouldStayLoaded(i, j); // Paper - Use shouldStayLoaded check for all worlds } } -- 2.9.3