Add Plugin Chunk Ticket API

Allows plugins to force certain chunks to be kept loaded for as long as they are enabled.

By: Spottedleaf <Spottedleaf@users.noreply.github.com>
This commit is contained in:
CraftBukkit/Spigot
2019-07-08 12:14:16 +10:00
parent 09309c363f
commit aedce73dd1
6 changed files with 268 additions and 2 deletions

View File

@@ -8,6 +8,15 @@
public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
@@ -58,7 +59,7 @@
private final Mailbox<ChunkTaskQueueSorter.a<Runnable>> mailboxWorldGen;
private final Mailbox<ChunkTaskQueueSorter.a<Runnable>> mailboxMain;
public final WorldLoadListener worldLoadListener;
- private final PlayerChunkMap.a u;
+ public final PlayerChunkMap.a u; // CraftBukkit - private -> public // PAIL chunkDistanceManager
private final AtomicInteger v;
private final DefinedStructureManager definedStructureManager;
private final File x;
@@ -184,9 +185,12 @@
return completablefuture1.thenApply((list1) -> {