2017-04-29 10:27:31 +00:00
|
|
|
From 76d4bbc0f57b08ce52b6d3a4f3da9c7dc720c6e4 Mon Sep 17 00:00:00 2001
|
2016-04-05 23:53:30 +00:00
|
|
|
From: Aikar <aikar@aikar.co>
|
|
|
|
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
|
2017-03-25 03:18:58 +00:00
|
|
|
index 44108ab9a..9bc8ce64c 100644
|
2016-04-05 23:53:30 +00:00
|
|
|
--- a/src/main/java/net/minecraft/server/World.java
|
|
|
|
+++ b/src/main/java/net/minecraft/server/World.java
|
2017-03-25 03:18:58 +00:00
|
|
|
@@ -3190,6 +3190,7 @@ public abstract class World implements IBlockAccess {
|
2016-04-05 23:53:30 +00:00
|
|
|
return this.N;
|
|
|
|
}
|
|
|
|
|
2016-11-17 02:23:38 +00:00
|
|
|
+ public boolean shouldStayLoaded(int i, int j) { return e(i, j); } // Paper - OBFHELPER
|
|
|
|
public boolean e(int i, int j) {
|
2016-04-05 23:53:30 +00:00
|
|
|
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
|
2017-03-25 03:18:58 +00:00
|
|
|
index a27512c0f..4691b3d8f 100644
|
2016-04-05 23:53:30 +00:00
|
|
|
--- a/src/main/java/net/minecraft/server/WorldProvider.java
|
|
|
|
+++ b/src/main/java/net/minecraft/server/WorldProvider.java
|
2016-12-21 21:29:50 +00:00
|
|
|
@@ -138,6 +138,6 @@ public abstract class WorldProvider {
|
2016-11-17 02:23:38 +00:00
|
|
|
public void s() {}
|
2016-04-05 23:53:30 +00:00
|
|
|
|
2016-11-17 02:23:38 +00:00
|
|
|
public boolean c(int i, int j) {
|
2016-04-05 23:53:30 +00:00
|
|
|
- return true;
|
|
|
|
+ return !this.b.shouldStayLoaded(i, j); // Paper - Use shouldStayLoaded check for all worlds
|
|
|
|
}
|
|
|
|
}
|
|
|
|
--
|
2017-04-29 10:27:31 +00:00
|
|
|
2.12.2.windows.2
|
2016-04-05 23:53:30 +00:00
|
|
|
|