Paper/Spigot-Server-Patches/0354-Make-CraftWorld-loadChunk-int-int-false-load-unconve.patch
Aikar 2365b308c8
Updated Upstream (Bukkit/CraftBukkit/Spigot)
Upstream has released updates that appears to apply and compile correctly.

This update has been tested to ensure that World Conversion still occurs correctly.

Bukkit Changes:
0812ce2c SPIGOT-4397: isChunkGenerated API

CraftBukkit Changes:
4824655c SPIGOT-4398: Upgrade to ASM 6.2.1 for better Java 11 support
eea43870 MC-134115: Fix issues converting tile entities
1a7f2d10 SPIGOT-4397: isChunkGenerated API
40aed54d SPIGOT-4396: Improve vehicle movement

Spigot Changes:
f6a273b1 Rebuild patches
2018-09-26 22:35:46 -04:00

24 lines
1.0 KiB
Diff

From 9b59314f27147a9fafdb72a79ed342b9d490f236 Mon Sep 17 00:00:00 2001
From: Spottedleaf <Spottedleaf@users.noreply.github.com>
Date: Sun, 2 Sep 2018 19:34:33 -0700
Subject: [PATCH] Make CraftWorld#loadChunk(int, int, false) load unconverted
chunks
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
index 2422251c72..d0110070a9 100644
--- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
+++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
@@ -289,7 +289,7 @@ public class CraftWorld implements World {
public boolean loadChunk(int x, int z, boolean generate) {
org.spigotmc.AsyncCatcher.catchOp( "chunk load"); // Spigot
chunkLoadCount++;
- return world.getChunkProviderServer().getChunkAt(x, z, true, generate) != null;
+ return world.getChunkProviderServer().getChunkAt(x, z, true, generate || isChunkGenerated(x, z)) != null; // Paper
}
public boolean isChunkLoaded(Chunk chunk) {
--
2.19.0