mirror of
https://github.com/PurpurMC/Purpur.git
synced 2026-02-19 17:37:42 +01:00
Updated Upstream (Paper)
Upstream has released updates that appear to apply and compile correctly Paper Changes: eb11845f8 Fix creating worlds with "invalid" names (Fixes #5331) e4d8a6279 Implement Keyed on World bcb63dab7 [CI-SKIP] [Auto] Rebuild Patches 48342b06c Allow signs that are inside of the spawn protection to be right clicked to use their run_command tag c229f90c1 Add Block#isValidTool 20e709c1d Add recipe to cook events 2dcf8bff4 legacy formatting will be the death of me f597fea0d legacy formatting is worse than walking around in wet socks 7f72c4675 Use implementation-provided legacy serializer for events 27a8d99ec Adventure 4.7.0 e65bd35a1 Respect teams in legacy chat name if configured (#5321) b31089a92 Updated Upstream (Bukkit/CraftBukkit/Spigot) (#5325) a52b30814 Fix title swapping fadeIn and stay 54ec85949 Prevent grindstones from overstacking items d7795080c Fix NPE for AIR in meta operations in ItemStack 2e70796c7 [CI-SKIP] Improve documentation of PreCreatureSpawnEvent (#5244) 7bb92e750 [CI-SKIP] Add JavaDoc links to Tag class pointing to custom Paper tags (#5285) 28cd686bf fix per-world difficulty command (#5306) be7cde2c7 [CI-SKIP] Always check PATH for JDK (#5315)
This commit is contained in:
@@ -10817,10 +10817,10 @@ index 0840fdf3585407ec317f0326359619220c64db78..6b9b64539d2272070b523ed6b927de02
|
||||
// CraftBukkit start - Fire ProjectileHitEvent
|
||||
if (this.dead) {
|
||||
diff --git a/src/main/java/net/minecraft/server/EntityFireworks.java b/src/main/java/net/minecraft/server/EntityFireworks.java
|
||||
index a646dc9f030ad1f76ba2b7bb1bc7897cd34b648c..dd18eabd7104995f0e6a8ecb279a3872b46773de 100644
|
||||
index 9bc4d3dbd4c64a6fbf33dcf28afde59ace9171ba..d8faa18724baa240fca78a35c362cf661615ec4d 100644
|
||||
--- a/src/main/java/net/minecraft/server/EntityFireworks.java
|
||||
+++ b/src/main/java/net/minecraft/server/EntityFireworks.java
|
||||
@@ -124,8 +124,10 @@ public class EntityFireworks extends IProjectile {
|
||||
@@ -125,8 +125,10 @@ public class EntityFireworks extends IProjectile {
|
||||
MovingObjectPosition movingobjectposition = ProjectileHelper.a((Entity) this, this::a);
|
||||
|
||||
if (!this.noclip) {
|
||||
@@ -10832,10 +10832,10 @@ index a646dc9f030ad1f76ba2b7bb1bc7897cd34b648c..dd18eabd7104995f0e6a8ecb279a3872
|
||||
|
||||
this.x();
|
||||
diff --git a/src/main/java/net/minecraft/server/EntityFishingHook.java b/src/main/java/net/minecraft/server/EntityFishingHook.java
|
||||
index e97c7794e86c0518bcec0a0370bffbeab20e2623..0816ab54bc99bcf29356b56516e83759a3f2988f 100644
|
||||
index 3580f40b2bb30bceca0ce374edb29608168a00c0..9841c7c27cd296a5156ba79ab734d45922bacaf7 100644
|
||||
--- a/src/main/java/net/minecraft/server/EntityFishingHook.java
|
||||
+++ b/src/main/java/net/minecraft/server/EntityFishingHook.java
|
||||
@@ -226,7 +226,9 @@ public class EntityFishingHook extends IProjectile {
|
||||
@@ -227,7 +227,9 @@ public class EntityFishingHook extends IProjectile {
|
||||
private void m() {
|
||||
MovingObjectPosition movingobjectposition = ProjectileHelper.a((Entity) this, this::a);
|
||||
|
||||
@@ -10865,10 +10865,10 @@ index a88521745f9f9b6935a61db52db915ea483af227..a47217c020d2c2a3caddafa0549dc827
|
||||
if (entityhuman != null) {
|
||||
double d0 = entityhuman.h((Entity) this); // CraftBukkit - decompile error
|
||||
diff --git a/src/main/java/net/minecraft/server/EntityItem.java b/src/main/java/net/minecraft/server/EntityItem.java
|
||||
index f41aaa7623c052b9f4044898d1bdee898c03057a..d99cecc4075338d7b8f154ab94d8ac04190ba371 100644
|
||||
index 5dfb54e17fcfe6bd30e6b2a449944606e1a0ef17..9a8b7e06f14f17dfea08d7031c83f77491aaca65 100644
|
||||
--- a/src/main/java/net/minecraft/server/EntityItem.java
|
||||
+++ b/src/main/java/net/minecraft/server/EntityItem.java
|
||||
@@ -526,7 +526,7 @@ public class EntityItem extends Entity {
|
||||
@@ -527,7 +527,7 @@ public class EntityItem extends Entity {
|
||||
|
||||
// Paper start - fix MC-4
|
||||
public void setPositionRaw(double x, double y, double z) {
|
||||
@@ -11992,10 +11992,10 @@ index ff74be14512a947e81b62d53e616131ca7d7f609..e79e773f2219f9a9ae076fcbc8108b79
|
||||
public static <T> void mergeSortedSets(final java.util.function.Consumer<T> consumer, final java.util.Comparator<? super T> comparator, final java.util.SortedSet<T>...sets) {
|
||||
final ObjectRBTreeSet<T> all = new ObjectRBTreeSet<>(comparator);
|
||||
diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java
|
||||
index d6ca2ac9a5047b8d6840c8b4985ab75f35bea919..e5acc1a3e3d774c10feac9b022acba5a63f634ea 100644
|
||||
index c572ef2830f2653e2b30622bbac0a3b072bacd7a..7ac34a8959a797bf2af96f3f402fa65cffe3d666 100644
|
||||
--- a/src/main/java/net/minecraft/server/MinecraftServer.java
|
||||
+++ b/src/main/java/net/minecraft/server/MinecraftServer.java
|
||||
@@ -153,6 +153,7 @@ public abstract class MinecraftServer extends IAsyncTaskHandlerReentrant<TickTas
|
||||
@@ -155,6 +155,7 @@ public abstract class MinecraftServer extends IAsyncTaskHandlerReentrant<TickTas
|
||||
public org.bukkit.command.RemoteConsoleCommandSender remoteConsole;
|
||||
//public ConsoleReader reader; // Paper
|
||||
public static int currentTick = 0; // Paper - Further improve tick loop
|
||||
@@ -12003,7 +12003,7 @@ index d6ca2ac9a5047b8d6840c8b4985ab75f35bea919..e5acc1a3e3d774c10feac9b022acba5a
|
||||
public java.util.Queue<Runnable> processQueue = new java.util.concurrent.ConcurrentLinkedQueue<Runnable>();
|
||||
public int autosavePeriod;
|
||||
public boolean serverAutoSave = false; // Paper
|
||||
@@ -753,10 +754,11 @@ public abstract class MinecraftServer extends IAsyncTaskHandlerReentrant<TickTas
|
||||
@@ -755,10 +756,11 @@ public abstract class MinecraftServer extends IAsyncTaskHandlerReentrant<TickTas
|
||||
org.spigotmc.WatchdogThread.doStop(); // Paper
|
||||
if (!isMainThread()) {
|
||||
MinecraftServer.LOGGER.info("Stopping main thread (Ignore any thread death message you see! - DO NOT REPORT THREAD DEATH TO PAPER)");
|
||||
@@ -12016,7 +12016,7 @@ index d6ca2ac9a5047b8d6840c8b4985ab75f35bea919..e5acc1a3e3d774c10feac9b022acba5a
|
||||
} catch (InterruptedException e) {}
|
||||
}
|
||||
// We've just obliterated the main thread, this will prevent stop from dying when removing players
|
||||
@@ -957,6 +959,7 @@ public abstract class MinecraftServer extends IAsyncTaskHandlerReentrant<TickTas
|
||||
@@ -959,6 +961,7 @@ public abstract class MinecraftServer extends IAsyncTaskHandlerReentrant<TickTas
|
||||
// Paper end
|
||||
|
||||
PaperJvmChecker.checkJvm(); // Paper jvm version nag
|
||||
@@ -12024,7 +12024,7 @@ index d6ca2ac9a5047b8d6840c8b4985ab75f35bea919..e5acc1a3e3d774c10feac9b022acba5a
|
||||
org.spigotmc.WatchdogThread.tick(); // Paper
|
||||
org.spigotmc.WatchdogThread.hasStarted = true; // Paper
|
||||
Arrays.fill( recentTps, 20 );
|
||||
@@ -974,6 +977,7 @@ public abstract class MinecraftServer extends IAsyncTaskHandlerReentrant<TickTas
|
||||
@@ -976,6 +979,7 @@ public abstract class MinecraftServer extends IAsyncTaskHandlerReentrant<TickTas
|
||||
this.lastOverloadTime = this.nextTick;
|
||||
}
|
||||
|
||||
@@ -12032,7 +12032,7 @@ index d6ca2ac9a5047b8d6840c8b4985ab75f35bea919..e5acc1a3e3d774c10feac9b022acba5a
|
||||
if ( ++MinecraftServer.currentTick % SAMPLE_INTERVAL == 0 )
|
||||
{
|
||||
final long diff = curTime - tickSection;
|
||||
@@ -988,7 +992,7 @@ public abstract class MinecraftServer extends IAsyncTaskHandlerReentrant<TickTas
|
||||
@@ -990,7 +994,7 @@ public abstract class MinecraftServer extends IAsyncTaskHandlerReentrant<TickTas
|
||||
// Paper end
|
||||
tickSection = curTime;
|
||||
}
|
||||
@@ -12041,7 +12041,7 @@ index d6ca2ac9a5047b8d6840c8b4985ab75f35bea919..e5acc1a3e3d774c10feac9b022acba5a
|
||||
// Spigot end
|
||||
|
||||
//MinecraftServer.currentTick = (int) (System.currentTimeMillis() / 50); // CraftBukkit // Paper - don't overwrite current tick time
|
||||
@@ -1081,6 +1085,76 @@ public abstract class MinecraftServer extends IAsyncTaskHandlerReentrant<TickTas
|
||||
@@ -1083,6 +1087,76 @@ public abstract class MinecraftServer extends IAsyncTaskHandlerReentrant<TickTas
|
||||
}
|
||||
// Paper end
|
||||
|
||||
@@ -12118,7 +12118,7 @@ index d6ca2ac9a5047b8d6840c8b4985ab75f35bea919..e5acc1a3e3d774c10feac9b022acba5a
|
||||
private void executeModerately() {
|
||||
this.executeAll();
|
||||
java.util.concurrent.locks.LockSupport.parkNanos("executing tasks", 1000L);
|
||||
@@ -1094,22 +1168,7 @@ public abstract class MinecraftServer extends IAsyncTaskHandlerReentrant<TickTas
|
||||
@@ -1096,22 +1170,7 @@ public abstract class MinecraftServer extends IAsyncTaskHandlerReentrant<TickTas
|
||||
});
|
||||
}
|
||||
|
||||
@@ -12142,7 +12142,7 @@ index d6ca2ac9a5047b8d6840c8b4985ab75f35bea919..e5acc1a3e3d774c10feac9b022acba5a
|
||||
|
||||
@Override
|
||||
protected TickTask postToMainThread(Runnable runnable) {
|
||||
@@ -1136,6 +1195,7 @@ public abstract class MinecraftServer extends IAsyncTaskHandlerReentrant<TickTas
|
||||
@@ -1138,6 +1197,7 @@ public abstract class MinecraftServer extends IAsyncTaskHandlerReentrant<TickTas
|
||||
|
||||
private boolean bb() {
|
||||
if (super.executeNext()) {
|
||||
@@ -12150,7 +12150,7 @@ index d6ca2ac9a5047b8d6840c8b4985ab75f35bea919..e5acc1a3e3d774c10feac9b022acba5a
|
||||
return true;
|
||||
} else {
|
||||
if (this.canSleepForTick()) {
|
||||
@@ -1203,7 +1263,7 @@ public abstract class MinecraftServer extends IAsyncTaskHandlerReentrant<TickTas
|
||||
@@ -1205,7 +1265,7 @@ public abstract class MinecraftServer extends IAsyncTaskHandlerReentrant<TickTas
|
||||
// Paper start - move oversleep into full server tick
|
||||
isOversleep = true;MinecraftTimings.serverOversleep.startTiming();
|
||||
this.awaitTasks(() -> {
|
||||
@@ -12159,7 +12159,7 @@ index d6ca2ac9a5047b8d6840c8b4985ab75f35bea919..e5acc1a3e3d774c10feac9b022acba5a
|
||||
return !this.canOversleep();
|
||||
});
|
||||
isOversleep = false;MinecraftTimings.serverOversleep.stopTiming();
|
||||
@@ -1268,6 +1328,8 @@ public abstract class MinecraftServer extends IAsyncTaskHandlerReentrant<TickTas
|
||||
@@ -1270,6 +1330,8 @@ public abstract class MinecraftServer extends IAsyncTaskHandlerReentrant<TickTas
|
||||
}
|
||||
// Paper end
|
||||
|
||||
@@ -12168,7 +12168,7 @@ index d6ca2ac9a5047b8d6840c8b4985ab75f35bea919..e5acc1a3e3d774c10feac9b022acba5a
|
||||
// Paper start
|
||||
long endTime = System.nanoTime();
|
||||
long remaining = (TICK_TIME - (endTime - lastTick)) - catchupTime;
|
||||
@@ -1294,16 +1356,16 @@ public abstract class MinecraftServer extends IAsyncTaskHandlerReentrant<TickTas
|
||||
@@ -1296,16 +1358,16 @@ public abstract class MinecraftServer extends IAsyncTaskHandlerReentrant<TickTas
|
||||
}
|
||||
|
||||
protected void b(BooleanSupplier booleansupplier) {
|
||||
@@ -12188,7 +12188,7 @@ index d6ca2ac9a5047b8d6840c8b4985ab75f35bea919..e5acc1a3e3d774c10feac9b022acba5a
|
||||
this.methodProfiler.exitEnter("levels");
|
||||
Iterator iterator = this.getWorlds().iterator();
|
||||
|
||||
@@ -1314,7 +1376,7 @@ public abstract class MinecraftServer extends IAsyncTaskHandlerReentrant<TickTas
|
||||
@@ -1316,7 +1378,7 @@ public abstract class MinecraftServer extends IAsyncTaskHandlerReentrant<TickTas
|
||||
processQueue.remove().run();
|
||||
}
|
||||
MinecraftTimings.processQueueTimer.stopTiming(); // Spigot
|
||||
@@ -12197,7 +12197,7 @@ index d6ca2ac9a5047b8d6840c8b4985ab75f35bea919..e5acc1a3e3d774c10feac9b022acba5a
|
||||
MinecraftTimings.timeUpdateTimer.startTiming(); // Spigot // Paper
|
||||
// Send time updates to everyone, it will get the right time from the world the player is in.
|
||||
// Paper start - optimize time updates
|
||||
@@ -1357,11 +1419,12 @@ public abstract class MinecraftServer extends IAsyncTaskHandlerReentrant<TickTas
|
||||
@@ -1359,11 +1421,12 @@ public abstract class MinecraftServer extends IAsyncTaskHandlerReentrant<TickTas
|
||||
this.methodProfiler.enter("tick");
|
||||
|
||||
try {
|
||||
@@ -12212,7 +12212,7 @@ index d6ca2ac9a5047b8d6840c8b4985ab75f35bea919..e5acc1a3e3d774c10feac9b022acba5a
|
||||
} catch (Throwable throwable) {
|
||||
// Spigot Start
|
||||
CrashReport crashreport;
|
||||
@@ -1455,7 +1518,7 @@ public abstract class MinecraftServer extends IAsyncTaskHandlerReentrant<TickTas
|
||||
@@ -1457,7 +1520,7 @@ public abstract class MinecraftServer extends IAsyncTaskHandlerReentrant<TickTas
|
||||
}
|
||||
|
||||
public String getServerModName() {
|
||||
@@ -13390,10 +13390,10 @@ index 904c6a7d0a36b57bb4f693fc4fd0dd5b17adcbac..3127fc9dd87e82243e167862cae83ac8
|
||||
if (chunk != null) {
|
||||
playerchunkmap.callbackExecutor.execute(() -> {
|
||||
diff --git a/src/main/java/net/minecraft/server/PlayerChunkMap.java b/src/main/java/net/minecraft/server/PlayerChunkMap.java
|
||||
index e16cd5da219e41f16f9c04fd95b79fe5cf10f6b8..3ae51a3a5d863d58fde73934ed100fbd62e2b279 100644
|
||||
index 00d0a5fd7c5d2db19756f3c6cfb2381868af51fd..3fe03b92658b157d6c7875dcaae6bbd41952ccd5 100644
|
||||
--- a/src/main/java/net/minecraft/server/PlayerChunkMap.java
|
||||
+++ b/src/main/java/net/minecraft/server/PlayerChunkMap.java
|
||||
@@ -121,31 +121,28 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
@@ -122,31 +122,28 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
// CraftBukkit start - recursion-safe executor for Chunk loadCallback() and unloadCallback()
|
||||
public final CallbackExecutor callbackExecutor = new CallbackExecutor();
|
||||
public static final class CallbackExecutor implements java.util.concurrent.Executor, Runnable {
|
||||
@@ -13436,7 +13436,7 @@ index e16cd5da219e41f16f9c04fd95b79fe5cf10f6b8..3ae51a3a5d863d58fde73934ed100fbd
|
||||
task.run();
|
||||
}
|
||||
}
|
||||
@@ -198,8 +195,15 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
@@ -199,8 +196,15 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
public final com.destroystokyo.paper.util.misc.PlayerAreaMap playerViewDistanceTickMap;
|
||||
public final com.destroystokyo.paper.util.misc.PlayerAreaMap playerViewDistanceNoTickMap;
|
||||
// Paper end - no-tick view distance
|
||||
@@ -13452,7 +13452,7 @@ index e16cd5da219e41f16f9c04fd95b79fe5cf10f6b8..3ae51a3a5d863d58fde73934ed100fbd
|
||||
int chunkX = MCUtil.getChunkCoordinate(player.locX());
|
||||
int chunkZ = MCUtil.getChunkCoordinate(player.locZ());
|
||||
// Note: players need to be explicitly added to distance maps before they can be updated
|
||||
@@ -227,9 +231,13 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
@@ -228,9 +232,13 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
this.playerViewDistanceBroadcastMap.add(player, chunkX, chunkZ, effectiveNoTickViewDistance + 1); // clients need an extra neighbour to render the full view distance configured
|
||||
player.needsChunkCenterUpdate = false;
|
||||
// Paper end - no-tick view distance
|
||||
@@ -13466,7 +13466,7 @@ index e16cd5da219e41f16f9c04fd95b79fe5cf10f6b8..3ae51a3a5d863d58fde73934ed100fbd
|
||||
// Paper start - use distance map to optimise tracker
|
||||
for (int i = 0, len = TRACKING_RANGE_TYPES.length; i < len; ++i) {
|
||||
this.playerEntityTrackerTrackMaps[i].remove(player);
|
||||
@@ -244,9 +252,13 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
@@ -245,9 +253,13 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
this.playerViewDistanceTickMap.remove(player);
|
||||
this.playerViewDistanceNoTickMap.remove(player);
|
||||
// Paper end - no-tick view distance
|
||||
@@ -13480,7 +13480,7 @@ index e16cd5da219e41f16f9c04fd95b79fe5cf10f6b8..3ae51a3a5d863d58fde73934ed100fbd
|
||||
int chunkX = MCUtil.getChunkCoordinate(player.locX());
|
||||
int chunkZ = MCUtil.getChunkCoordinate(player.locZ());
|
||||
// Note: players need to be explicitly added to distance maps before they can be updated
|
||||
@@ -274,9 +286,35 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
@@ -275,9 +287,35 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
this.playerViewDistanceBroadcastMap.update(player, chunkX, chunkZ, effectiveNoTickViewDistance + 1); // clients need an extra neighbour to render the full view distance configured
|
||||
player.needsChunkCenterUpdate = false;
|
||||
// Paper end - no-tick view distance
|
||||
@@ -13516,7 +13516,7 @@ index e16cd5da219e41f16f9c04fd95b79fe5cf10f6b8..3ae51a3a5d863d58fde73934ed100fbd
|
||||
private final java.util.concurrent.ExecutorService lightThread;
|
||||
public PlayerChunkMap(WorldServer worldserver, Convertable.ConversionSession convertable_conversionsession, DataFixer datafixer, DefinedStructureManager definedstructuremanager, Executor executor, IAsyncTaskHandler<Runnable> iasynctaskhandler, ILightAccess ilightaccess, ChunkGenerator chunkgenerator, WorldLoadListener worldloadlistener, Supplier<WorldPersistentData> supplier, int i, boolean flag) {
|
||||
super(new File(convertable_conversionsession.a(worldserver.getDimensionKey()), "region"), datafixer, flag);
|
||||
@@ -310,9 +348,10 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
@@ -311,9 +349,10 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
|
||||
this.worldLoadListener = worldloadlistener;
|
||||
// Paper start - use light thread
|
||||
@@ -13528,7 +13528,7 @@ index e16cd5da219e41f16f9c04fd95b79fe5cf10f6b8..3ae51a3a5d863d58fde73934ed100fbd
|
||||
thread.setDaemon(true);
|
||||
thread.setPriority(Thread.NORM_PRIORITY+1);
|
||||
return thread;
|
||||
@@ -444,6 +483,26 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
@@ -445,6 +484,26 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
PlayerChunkMap.this.sendChunk(player, new ChunkCoordIntPair(rangeX, rangeZ), null, true, false); // unloaded, loaded
|
||||
});
|
||||
// Paper end - no-tick view distance
|
||||
@@ -13555,7 +13555,7 @@ index e16cd5da219e41f16f9c04fd95b79fe5cf10f6b8..3ae51a3a5d863d58fde73934ed100fbd
|
||||
}
|
||||
// Paper start - Chunk Prioritization
|
||||
public void queueHolderUpdate(PlayerChunk playerchunk) {
|
||||
@@ -756,6 +815,8 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
@@ -757,6 +816,8 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
|
||||
@Nullable
|
||||
private PlayerChunk a(long i, int j, @Nullable PlayerChunk playerchunk, int k) {
|
||||
@@ -13564,7 +13564,7 @@ index e16cd5da219e41f16f9c04fd95b79fe5cf10f6b8..3ae51a3a5d863d58fde73934ed100fbd
|
||||
if (k > PlayerChunkMap.GOLDEN_TICKET && j > PlayerChunkMap.GOLDEN_TICKET) {
|
||||
return playerchunk;
|
||||
} else {
|
||||
@@ -778,7 +839,9 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
@@ -779,7 +840,9 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
playerchunk.a(j);
|
||||
} else {
|
||||
playerchunk = new PlayerChunk(new ChunkCoordIntPair(i), j, this.lightEngine, this.p, this);
|
||||
@@ -13574,7 +13574,7 @@ index e16cd5da219e41f16f9c04fd95b79fe5cf10f6b8..3ae51a3a5d863d58fde73934ed100fbd
|
||||
|
||||
this.updatingChunks.put(i, playerchunk);
|
||||
this.updatingChunksModified = true;
|
||||
@@ -904,7 +967,7 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
@@ -905,7 +968,7 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
|
||||
}
|
||||
|
||||
@@ -13583,7 +13583,7 @@ index e16cd5da219e41f16f9c04fd95b79fe5cf10f6b8..3ae51a3a5d863d58fde73934ed100fbd
|
||||
|
||||
protected void unloadChunks(BooleanSupplier booleansupplier) {
|
||||
GameProfilerFiller gameprofilerfiller = this.world.getMethodProfiler();
|
||||
@@ -970,7 +1033,7 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
@@ -971,7 +1034,7 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
}
|
||||
|
||||
com.destroystokyo.paper.io.PaperFileIOThread.Holder.INSTANCE.scheduleSave(this.world, chunkPos.x, chunkPos.z,
|
||||
@@ -13592,7 +13592,7 @@ index e16cd5da219e41f16f9c04fd95b79fe5cf10f6b8..3ae51a3a5d863d58fde73934ed100fbd
|
||||
|
||||
if (!chunk.isNeedsSaving()) {
|
||||
return;
|
||||
@@ -1004,7 +1067,7 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
@@ -1005,7 +1068,7 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
asyncSaveData = ChunkRegionLoader.getAsyncSaveData(this.world, chunk);
|
||||
}
|
||||
|
||||
@@ -13601,7 +13601,7 @@ index e16cd5da219e41f16f9c04fd95b79fe5cf10f6b8..3ae51a3a5d863d58fde73934ed100fbd
|
||||
asyncSaveData, chunk);
|
||||
|
||||
chunk.setLastSaved(this.world.getTime());
|
||||
@@ -1012,6 +1075,8 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
@@ -1013,6 +1076,8 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
}
|
||||
// Paper end
|
||||
|
||||
@@ -13610,7 +13610,7 @@ index e16cd5da219e41f16f9c04fd95b79fe5cf10f6b8..3ae51a3a5d863d58fde73934ed100fbd
|
||||
private void a(long i, PlayerChunk playerchunk) {
|
||||
CompletableFuture<IChunkAccess> completablefuture = playerchunk.getChunkSave();
|
||||
Consumer<IChunkAccess> consumer = (ichunkaccess) -> { // CraftBukkit - decompile error
|
||||
@@ -1020,7 +1085,15 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
@@ -1021,7 +1086,15 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
if (completablefuture1 != completablefuture) {
|
||||
this.a(i, playerchunk);
|
||||
} else {
|
||||
@@ -13627,7 +13627,7 @@ index e16cd5da219e41f16f9c04fd95b79fe5cf10f6b8..3ae51a3a5d863d58fde73934ed100fbd
|
||||
if (ichunkaccess instanceof Chunk) {
|
||||
((Chunk) ichunkaccess).setLoaded(false);
|
||||
}
|
||||
@@ -1044,6 +1117,9 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
@@ -1045,6 +1118,9 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
this.lightEngine.queueUpdate();
|
||||
this.worldLoadListener.a(ichunkaccess.getPos(), (ChunkStatus) null);
|
||||
}
|
||||
@@ -13637,7 +13637,7 @@ index e16cd5da219e41f16f9c04fd95b79fe5cf10f6b8..3ae51a3a5d863d58fde73934ed100fbd
|
||||
|
||||
}
|
||||
};
|
||||
@@ -1059,6 +1135,7 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
@@ -1060,6 +1136,7 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
}
|
||||
|
||||
protected boolean b() {
|
||||
@@ -13645,7 +13645,7 @@ index e16cd5da219e41f16f9c04fd95b79fe5cf10f6b8..3ae51a3a5d863d58fde73934ed100fbd
|
||||
if (!this.updatingChunksModified) {
|
||||
return false;
|
||||
} else {
|
||||
@@ -1134,6 +1211,7 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
@@ -1135,6 +1212,7 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
|
||||
this.getVillagePlace().loadInData(chunkcoordintpair, chunkHolder.poiData);
|
||||
chunkHolder.tasks.forEach(Runnable::run);
|
||||
@@ -13653,7 +13653,7 @@ index e16cd5da219e41f16f9c04fd95b79fe5cf10f6b8..3ae51a3a5d863d58fde73934ed100fbd
|
||||
// Paper end
|
||||
|
||||
if (chunkHolder.protoChunk != null) {try (Timing ignored2 = this.world.timings.chunkLoadLevelTimer.startTimingIfSync()) { // Paper start - timings // Paper - chunk is created async
|
||||
@@ -1246,9 +1324,13 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
@@ -1247,9 +1325,13 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
}
|
||||
// Paper end
|
||||
this.mailboxWorldGen.a(ChunkTaskQueueSorter.a(playerchunk, runnable));
|
||||
@@ -13668,7 +13668,7 @@ index e16cd5da219e41f16f9c04fd95b79fe5cf10f6b8..3ae51a3a5d863d58fde73934ed100fbd
|
||||
protected void c(ChunkCoordIntPair chunkcoordintpair) {
|
||||
this.executor.a(SystemUtils.a(() -> {
|
||||
this.chunkDistanceManager.b(TicketType.LIGHT, chunkcoordintpair, 33 + ChunkStatus.a(ChunkStatus.FEATURES), chunkcoordintpair);
|
||||
@@ -1415,9 +1497,7 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
@@ -1416,9 +1498,7 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
chunk.B();
|
||||
return chunk;
|
||||
});
|
||||
@@ -13679,7 +13679,7 @@ index e16cd5da219e41f16f9c04fd95b79fe5cf10f6b8..3ae51a3a5d863d58fde73934ed100fbd
|
||||
}
|
||||
|
||||
public int c() {
|
||||
@@ -1498,6 +1578,7 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
@@ -1499,6 +1579,7 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
}
|
||||
|
||||
public void setViewDistance(int i) { // Paper - public
|
||||
@@ -13687,7 +13687,7 @@ index e16cd5da219e41f16f9c04fd95b79fe5cf10f6b8..3ae51a3a5d863d58fde73934ed100fbd
|
||||
int j = MathHelper.clamp(i + 1, 3, 33); // Paper - diff on change, these make the lower view distance limit 2 and the upper 32
|
||||
|
||||
if (j != this.viewDistance) {
|
||||
@@ -1511,6 +1592,7 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
@@ -1512,6 +1593,7 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
|
||||
// Paper start - no-tick view distance
|
||||
public final void setNoTickViewDistance(int viewDistance) {
|
||||
@@ -13695,7 +13695,7 @@ index e16cd5da219e41f16f9c04fd95b79fe5cf10f6b8..3ae51a3a5d863d58fde73934ed100fbd
|
||||
viewDistance = viewDistance == -1 ? -1 : MathHelper.clamp(viewDistance, 2, 32);
|
||||
|
||||
this.noTickViewDistance = viewDistance;
|
||||
@@ -1626,7 +1708,7 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
@@ -1627,7 +1709,7 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
if (Thread.currentThread() != com.destroystokyo.paper.io.PaperFileIOThread.Holder.INSTANCE) {
|
||||
com.destroystokyo.paper.io.PaperFileIOThread.Holder.INSTANCE.scheduleSave(
|
||||
this.world, chunkcoordintpair.x, chunkcoordintpair.z, null, nbttagcompound,
|
||||
@@ -13704,7 +13704,7 @@ index e16cd5da219e41f16f9c04fd95b79fe5cf10f6b8..3ae51a3a5d863d58fde73934ed100fbd
|
||||
return;
|
||||
}
|
||||
super.write(chunkcoordintpair, nbttagcompound);
|
||||
@@ -1710,6 +1792,11 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
@@ -1711,6 +1793,11 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
return chunkHolder == null ? null : chunkHolder.getAvailableChunkNow();
|
||||
}
|
||||
// Paper end
|
||||
@@ -13716,7 +13716,7 @@ index e16cd5da219e41f16f9c04fd95b79fe5cf10f6b8..3ae51a3a5d863d58fde73934ed100fbd
|
||||
|
||||
|
||||
// Paper start - async io
|
||||
@@ -2037,22 +2124,25 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
@@ -2038,22 +2125,25 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
|
||||
private final void processTrackQueue() {
|
||||
this.world.timings.tracker1.startTiming();
|
||||
try {
|
||||
@@ -13756,7 +13756,7 @@ index e16cd5da219e41f16f9c04fd95b79fe5cf10f6b8..3ae51a3a5d863d58fde73934ed100fbd
|
||||
}
|
||||
// Paper end - optimised tracker
|
||||
diff --git a/src/main/java/net/minecraft/server/PlayerConnection.java b/src/main/java/net/minecraft/server/PlayerConnection.java
|
||||
index f3679a3ad2d51612381bc47bb23eeffec924d478..24b8a27b46c9e617fe3db6317da60227dbb60a1e 100644
|
||||
index 3435eb1584546d2963324372ddab1645dcf6327a..9146b60cff0aa06e2f6b6003bfe9e2be9d2f0d56 100644
|
||||
--- a/src/main/java/net/minecraft/server/PlayerConnection.java
|
||||
+++ b/src/main/java/net/minecraft/server/PlayerConnection.java
|
||||
@@ -423,7 +423,9 @@ public class PlayerConnection implements PacketListenerPlayIn {
|
||||
@@ -13987,10 +13987,10 @@ index 8c7080777b370f97e1291dfedde5b419290f39cc..7fff1b3e4eda519851b714502d33122c
|
||||
});
|
||||
throw CancelledPacketHandleException.INSTANCE;
|
||||
diff --git a/src/main/java/net/minecraft/server/PlayerInteractManager.java b/src/main/java/net/minecraft/server/PlayerInteractManager.java
|
||||
index 114e986e5132e5e4bb42d0f08a067429bce53ba6..05656ea8448aa569e8dd480461e2d5f70d01568b 100644
|
||||
index d57784c5dd44cc110b7c863ffff82263178e7d9a..967443a44106563fe71a528703751ff00415f61a 100644
|
||||
--- a/src/main/java/net/minecraft/server/PlayerInteractManager.java
|
||||
+++ b/src/main/java/net/minecraft/server/PlayerInteractManager.java
|
||||
@@ -21,14 +21,29 @@ public class PlayerInteractManager {
|
||||
@@ -22,14 +22,29 @@ public class PlayerInteractManager {
|
||||
private EnumGamemode gamemode;
|
||||
private EnumGamemode e;
|
||||
private boolean f;
|
||||
@@ -14023,7 +14023,7 @@ index 114e986e5132e5e4bb42d0f08a067429bce53ba6..05656ea8448aa569e8dd480461e2d5f7
|
||||
public PlayerInteractManager(WorldServer worldserver) {
|
||||
this.gamemode = EnumGamemode.NOT_SET;
|
||||
this.e = EnumGamemode.NOT_SET;
|
||||
@@ -84,7 +99,7 @@ public class PlayerInteractManager {
|
||||
@@ -85,7 +100,7 @@ public class PlayerInteractManager {
|
||||
if (iblockdata == null || iblockdata.isAir()) { // Paper
|
||||
this.j = false;
|
||||
} else {
|
||||
@@ -14032,7 +14032,7 @@ index 114e986e5132e5e4bb42d0f08a067429bce53ba6..05656ea8448aa569e8dd480461e2d5f7
|
||||
|
||||
if (f >= 1.0F) {
|
||||
this.j = false;
|
||||
@@ -104,7 +119,7 @@ public class PlayerInteractManager {
|
||||
@@ -105,7 +120,7 @@ public class PlayerInteractManager {
|
||||
this.m = -1;
|
||||
this.f = false;
|
||||
} else {
|
||||
@@ -14041,7 +14041,7 @@ index 114e986e5132e5e4bb42d0f08a067429bce53ba6..05656ea8448aa569e8dd480461e2d5f7
|
||||
}
|
||||
}
|
||||
|
||||
@@ -112,6 +127,12 @@ public class PlayerInteractManager {
|
||||
@@ -113,6 +128,12 @@ public class PlayerInteractManager {
|
||||
|
||||
private float a(IBlockData iblockdata, BlockPosition blockposition, int i) {
|
||||
int j = this.currentTick - i;
|
||||
@@ -14054,7 +14054,7 @@ index 114e986e5132e5e4bb42d0f08a067429bce53ba6..05656ea8448aa569e8dd480461e2d5f7
|
||||
float f = iblockdata.getDamage(this.player, this.player.world, blockposition) * (float) (j + 1);
|
||||
int k = (int) (f * 10.0F);
|
||||
|
||||
@@ -179,7 +200,7 @@ public class PlayerInteractManager {
|
||||
@@ -180,7 +201,7 @@ public class PlayerInteractManager {
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -14063,7 +14063,7 @@ index 114e986e5132e5e4bb42d0f08a067429bce53ba6..05656ea8448aa569e8dd480461e2d5f7
|
||||
float f = 1.0F;
|
||||
|
||||
iblockdata = this.world.getType(blockposition);
|
||||
@@ -232,12 +253,12 @@ public class PlayerInteractManager {
|
||||
@@ -233,12 +254,12 @@ public class PlayerInteractManager {
|
||||
int j = (int) (f * 10.0F);
|
||||
|
||||
this.world.a(this.player.getId(), blockposition, j);
|
||||
@@ -14078,7 +14078,7 @@ index 114e986e5132e5e4bb42d0f08a067429bce53ba6..05656ea8448aa569e8dd480461e2d5f7
|
||||
|
||||
iblockdata = this.world.getType(blockposition);
|
||||
if (!iblockdata.isAir()) {
|
||||
@@ -254,12 +275,18 @@ public class PlayerInteractManager {
|
||||
@@ -255,12 +276,18 @@ public class PlayerInteractManager {
|
||||
this.f = false;
|
||||
this.j = true;
|
||||
this.k = blockposition;
|
||||
@@ -14098,7 +14098,7 @@ index 114e986e5132e5e4bb42d0f08a067429bce53ba6..05656ea8448aa569e8dd480461e2d5f7
|
||||
} else if (packetplayinblockdig_enumplayerdigtype == PacketPlayInBlockDig.EnumPlayerDigType.ABORT_DESTROY_BLOCK) {
|
||||
this.f = false;
|
||||
if (!Objects.equals(this.h, blockposition) && !BlockPosition.ZERO.equals(this.h)) {
|
||||
@@ -271,7 +298,7 @@ public class PlayerInteractManager {
|
||||
@@ -272,7 +299,7 @@ public class PlayerInteractManager {
|
||||
}
|
||||
|
||||
this.world.a(this.player.getId(), blockposition, -1);
|
||||
@@ -14107,7 +14107,7 @@ index 114e986e5132e5e4bb42d0f08a067429bce53ba6..05656ea8448aa569e8dd480461e2d5f7
|
||||
}
|
||||
|
||||
}
|
||||
@@ -281,7 +308,13 @@ public class PlayerInteractManager {
|
||||
@@ -282,7 +309,13 @@ public class PlayerInteractManager {
|
||||
|
||||
public void a(BlockPosition blockposition, PacketPlayInBlockDig.EnumPlayerDigType packetplayinblockdig_enumplayerdigtype, String s) {
|
||||
if (this.breakBlock(blockposition)) {
|
||||
@@ -14122,10 +14122,10 @@ index 114e986e5132e5e4bb42d0f08a067429bce53ba6..05656ea8448aa569e8dd480461e2d5f7
|
||||
this.player.playerConnection.sendPacket(new PacketPlayOutBlockChange(this.world, blockposition)); // CraftBukkit - SPIGOT-5196
|
||||
}
|
||||
diff --git a/src/main/java/net/minecraft/server/PlayerList.java b/src/main/java/net/minecraft/server/PlayerList.java
|
||||
index 610613c2dbea18e1064c5f29cc36cf39aece2277..193a39ba0c07b0f438aba6b3a00af51fa93bd53d 100644
|
||||
index 184a0d30f4a1d4a6a07449fdd1375a8582da9332..d03d0c13cca1762078617744253a9757b388958f 100644
|
||||
--- a/src/main/java/net/minecraft/server/PlayerList.java
|
||||
+++ b/src/main/java/net/minecraft/server/PlayerList.java
|
||||
@@ -101,6 +101,7 @@ public abstract class PlayerList {
|
||||
@@ -96,6 +96,7 @@ public abstract class PlayerList {
|
||||
abstract public void loadAndSaveFiles(); // Paper - moved from DedicatedPlayerList constructor
|
||||
|
||||
public void a(NetworkManager networkmanager, EntityPlayer entityplayer) {
|
||||
@@ -14133,7 +14133,7 @@ index 610613c2dbea18e1064c5f29cc36cf39aece2277..193a39ba0c07b0f438aba6b3a00af51f
|
||||
EntityPlayer prev = pendingPlayers.put(entityplayer.getUniqueID(), entityplayer);// Paper
|
||||
if (prev != null) {
|
||||
disconnectPendingPlayer(prev);
|
||||
@@ -641,7 +642,7 @@ public abstract class PlayerList {
|
||||
@@ -636,7 +637,7 @@ public abstract class PlayerList {
|
||||
SocketAddress socketaddress = loginlistener.networkManager.getSocketAddress();
|
||||
|
||||
EntityPlayer entity = new EntityPlayer(this.server, this.server.getWorldServer(World.OVERWORLD), gameprofile, new PlayerInteractManager(this.server.getWorldServer(World.OVERWORLD)));
|
||||
@@ -17538,7 +17538,7 @@ index 7511e38130f38703164395a670f12d1af648ff04..e602efcb3fad390bb6bff1055e782bba
|
||||
}
|
||||
value.append("},");
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
|
||||
index 968349163b15cf40dac9717072740ce48231b7c8..9e339b1c76e28987936f79ccc65a09c21c6aac5e 100644
|
||||
index 1398b18409db3b3741ce199ee7156a2dfe2cc96c..f994e99ebc8fe22e6f6b45f6379ec410a598789f 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
|
||||
@@ -232,7 +232,7 @@ import javax.annotation.Nullable; // Paper
|
||||
@@ -17566,7 +17566,7 @@ index 968349163b15cf40dac9717072740ce48231b7c8..9e339b1c76e28987936f79ccc65a09c2
|
||||
}
|
||||
|
||||
Plugin[] pluginClone = pluginManager.getPlugins().clone(); // Paper
|
||||
@@ -1901,7 +1903,10 @@ public final class CraftServer implements Server {
|
||||
@@ -1910,7 +1912,10 @@ public final class CraftServer implements Server {
|
||||
|
||||
@Override
|
||||
public boolean isPrimaryThread() {
|
||||
@@ -17578,7 +17578,7 @@ index 968349163b15cf40dac9717072740ce48231b7c8..9e339b1c76e28987936f79ccc65a09c2
|
||||
}
|
||||
|
||||
// Paper start
|
||||
@@ -2335,6 +2340,14 @@ public final class CraftServer implements Server {
|
||||
@@ -2344,6 +2349,14 @@ public final class CraftServer implements Server {
|
||||
return com.destroystokyo.paper.PaperConfig.config;
|
||||
}
|
||||
|
||||
@@ -17594,10 +17594,10 @@ index 968349163b15cf40dac9717072740ce48231b7c8..9e339b1c76e28987936f79ccc65a09c2
|
||||
public void restart() {
|
||||
org.spigotmc.RestartCommand.restart();
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
|
||||
index 22eba9372d334c65d009721e808c958dfc271308..15ce459aa15a8bb936740a8c055f4304e21312d2 100644
|
||||
index cade3ed6079011f44eba613dece3d69ec18f8f04..3e54e643d28ced3074c4b044bc8a2238de05ccc2 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
|
||||
@@ -341,6 +341,14 @@ public class CraftWorld implements World {
|
||||
@@ -342,6 +342,14 @@ public class CraftWorld implements World {
|
||||
this.generator = gen;
|
||||
|
||||
environment = env;
|
||||
@@ -17612,7 +17612,7 @@ index 22eba9372d334c65d009721e808c958dfc271308..15ce459aa15a8bb936740a8c055f4304
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -414,14 +422,7 @@ public class CraftWorld implements World {
|
||||
@@ -415,14 +423,7 @@ public class CraftWorld implements World {
|
||||
|
||||
@Override
|
||||
public Chunk getChunkAt(int x, int z) {
|
||||
@@ -17628,7 +17628,7 @@ index 22eba9372d334c65d009721e808c958dfc271308..15ce459aa15a8bb936740a8c055f4304
|
||||
}
|
||||
|
||||
// Paper start
|
||||
@@ -504,6 +505,7 @@ public class CraftWorld implements World {
|
||||
@@ -505,6 +506,7 @@ public class CraftWorld implements World {
|
||||
org.spigotmc.AsyncCatcher.catchOp("chunk unload"); // Spigot
|
||||
if (isChunkLoaded(x, z)) {
|
||||
world.getChunkProvider().removeTicket(TicketType.PLUGIN, new ChunkCoordIntPair(x, z), 0, Unit.INSTANCE); // Paper
|
||||
@@ -17636,7 +17636,7 @@ index 22eba9372d334c65d009721e808c958dfc271308..15ce459aa15a8bb936740a8c055f4304
|
||||
}
|
||||
|
||||
return true;
|
||||
@@ -717,6 +719,30 @@ public class CraftWorld implements World {
|
||||
@@ -718,6 +720,30 @@ public class CraftWorld implements World {
|
||||
return ret.entrySet().stream().collect(ImmutableMap.toImmutableMap(Map.Entry::getKey, (entry) -> entry.getValue().build()));
|
||||
}
|
||||
|
||||
@@ -17667,7 +17667,7 @@ index 22eba9372d334c65d009721e808c958dfc271308..15ce459aa15a8bb936740a8c055f4304
|
||||
@Override
|
||||
public boolean isChunkForceLoaded(int x, int z) {
|
||||
return getHandle().getForceLoadedChunks().contains(ChunkCoordIntPair.pair(x, z));
|
||||
@@ -2567,7 +2593,7 @@ public class CraftWorld implements World {
|
||||
@@ -2581,7 +2607,7 @@ public class CraftWorld implements World {
|
||||
}
|
||||
return this.world.getChunkProvider().getChunkAtAsynchronously(x, z, gen, urgent).thenComposeAsync((either) -> {
|
||||
net.minecraft.server.Chunk chunk = (net.minecraft.server.Chunk) either.left().orElse(null);
|
||||
@@ -17704,7 +17704,7 @@ index 22bde395939f97086e411cef190bb2b1e7ede79a..0f6cb508a170360b6479f9c340484124
|
||||
//Thread.sleep(TimeUnit.SECONDS.toMillis(20));
|
||||
// Paper End
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java
|
||||
index bb474fbdf44dbc61b4fa0bced4d15bc2d1fb548f..744e6351c58e5aa4a0c668f2ff1adb76a3dc0822 100644
|
||||
index 2fc101869775711533a1e50f9ae608cd74d36d3a..2af3bee540ee25ea32a7548fd0d64dea16a0a268 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java
|
||||
@@ -509,27 +509,7 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity {
|
||||
|
||||
Reference in New Issue
Block a user