aboutsummaryrefslogtreecommitdiffhomepage
path: root/patches/server/0716-Warn-on-plugins-accessing-faraway-chunks.patch
diff options
context:
space:
mode:
Diffstat (limited to 'patches/server/0716-Warn-on-plugins-accessing-faraway-chunks.patch')
-rw-r--r--patches/server/0716-Warn-on-plugins-accessing-faraway-chunks.patch18
1 files changed, 9 insertions, 9 deletions
diff --git a/patches/server/0716-Warn-on-plugins-accessing-faraway-chunks.patch b/patches/server/0716-Warn-on-plugins-accessing-faraway-chunks.patch
index 504e0b4859..883f1fb37c 100644
--- a/patches/server/0716-Warn-on-plugins-accessing-faraway-chunks.patch
+++ b/patches/server/0716-Warn-on-plugins-accessing-faraway-chunks.patch
@@ -18,10 +18,10 @@ index 9afc0eaaca5ab7b6445d90ce53e31a6ae76f8848..f0c2187a92de633a1d4cc7e71ff62cbe
private static boolean isOutsideSpawnableHeight(int y) {
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
-index 9b7304ea9a4f226872d13e64722adb267f727806..431bd698e28b7731bf781e29de6c6a3fd936c71c 100644
+index d5675c1aec7d4b1a426cff55c8cac2decac6ec0a..5ac5f5a1963a89dace45d61e0ca0588c1c0fd05c 100644
--- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
+++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
-@@ -301,9 +301,24 @@ public class CraftWorld extends CraftRegionAccessor implements World {
+@@ -302,9 +302,24 @@ public class CraftWorld extends CraftRegionAccessor implements World {
public boolean setSpawnLocation(int x, int y, int z) {
return this.setSpawnLocation(x, y, z, 0.0F);
}
@@ -46,7 +46,7 @@ index 9b7304ea9a4f226872d13e64722adb267f727806..431bd698e28b7731bf781e29de6c6a3f
net.minecraft.world.level.chunk.LevelChunk chunk = (net.minecraft.world.level.chunk.LevelChunk) this.world.getChunk(x, z, ChunkStatus.FULL, true);
return new CraftChunk(chunk);
}
-@@ -399,6 +414,7 @@ public class CraftWorld extends CraftRegionAccessor implements World {
+@@ -400,6 +415,7 @@ public class CraftWorld extends CraftRegionAccessor implements World {
if (!unloadChunk0(x, z, false)) {
return false;
}
@@ -54,7 +54,7 @@ index 9b7304ea9a4f226872d13e64722adb267f727806..431bd698e28b7731bf781e29de6c6a3f
final long chunkKey = ChunkCoordIntPair.pair(x, z);
world.getChunkProvider().unloadQueue.remove(chunkKey);
-@@ -472,6 +488,7 @@ public class CraftWorld extends CraftRegionAccessor implements World {
+@@ -473,6 +489,7 @@ public class CraftWorld extends CraftRegionAccessor implements World {
@Override
public boolean loadChunk(int x, int z, boolean generate) {
org.spigotmc.AsyncCatcher.catchOp("chunk load"); // Spigot
@@ -62,7 +62,7 @@ index 9b7304ea9a4f226872d13e64722adb267f727806..431bd698e28b7731bf781e29de6c6a3f
ChunkAccess chunk = this.world.getChunkSource().getChunk(x, z, generate || isChunkGenerated(x, z) ? ChunkStatus.FULL : ChunkStatus.EMPTY, true); // Paper
// If generate = false, but the chunk already exists, we will get this back.
-@@ -504,6 +521,7 @@ public class CraftWorld extends CraftRegionAccessor implements World {
+@@ -505,6 +522,7 @@ public class CraftWorld extends CraftRegionAccessor implements World {
@Override
public boolean addPluginChunkTicket(int x, int z, Plugin plugin) {
@@ -70,7 +70,7 @@ index 9b7304ea9a4f226872d13e64722adb267f727806..431bd698e28b7731bf781e29de6c6a3f
Preconditions.checkArgument(plugin != null, "null plugin");
Preconditions.checkArgument(plugin.isEnabled(), "plugin is not enabled");
-@@ -604,6 +622,7 @@ public class CraftWorld extends CraftRegionAccessor implements World {
+@@ -605,6 +623,7 @@ public class CraftWorld extends CraftRegionAccessor implements World {
@Override
public void setChunkForceLoaded(int x, int z, boolean forced) {
@@ -78,7 +78,7 @@ index 9b7304ea9a4f226872d13e64722adb267f727806..431bd698e28b7731bf781e29de6c6a3f
this.getHandle().setChunkForced(x, z, forced);
}
-@@ -938,6 +957,7 @@ public class CraftWorld extends CraftRegionAccessor implements World {
+@@ -939,6 +958,7 @@ public class CraftWorld extends CraftRegionAccessor implements World {
@Override
public int getHighestBlockYAt(int x, int z, org.bukkit.HeightMap heightMap) {
@@ -86,7 +86,7 @@ index 9b7304ea9a4f226872d13e64722adb267f727806..431bd698e28b7731bf781e29de6c6a3f
// Transient load for this tick
return this.world.getChunk(x >> 4, z >> 4).getHeight(CraftHeightMap.toNMS(heightMap), x, z);
}
-@@ -2339,6 +2359,7 @@ public class CraftWorld extends CraftRegionAccessor implements World {
+@@ -2340,6 +2360,7 @@ public class CraftWorld extends CraftRegionAccessor implements World {
// Paper start
@Override
public void getChunkAtAsync(int x, int z, boolean gen, boolean urgent, @NotNull Consumer<? super Chunk> cb) {
@@ -94,7 +94,7 @@ index 9b7304ea9a4f226872d13e64722adb267f727806..431bd698e28b7731bf781e29de6c6a3f
ca.spottedleaf.moonrise.common.util.ChunkSystem.scheduleChunkLoad(
this.getHandle(), x, z, gen, ChunkStatus.FULL, true,
urgent ? ca.spottedleaf.concurrentutil.util.Priority.HIGHER : ca.spottedleaf.concurrentutil.util.Priority.NORMAL,
-@@ -2351,6 +2372,8 @@ public class CraftWorld extends CraftRegionAccessor implements World {
+@@ -2352,6 +2373,8 @@ public class CraftWorld extends CraftRegionAccessor implements World {
@Override
public void getChunksAtAsync(int minX, int minZ, int maxX, int maxZ, boolean urgent, Runnable cb) {