3
0
Mirror von https://github.com/PaperMC/Paper.git synchronisiert 2024-12-18 12:30:06 +01:00
Paper/nms-patches/ChunkTaskScheduler.patch

25 Zeilen
1.1 KiB
Diff

2018-07-25 11:32:06 +02:00
--- a/net/minecraft/server/ChunkTaskScheduler.java
+++ b/net/minecraft/server/ChunkTaskScheduler.java
2018-08-26 04:00:00 +02:00
@@ -20,7 +20,7 @@
private final ChunkGenerator<?> d;
private final IChunkLoader e;
private final IAsyncTaskHandler f;
- private final Long2ObjectMap<Scheduler.a> progressCache = new ExpiringMap(8192, 5000) {
+ private final Long2ObjectMap<Scheduler.a> progressCache = new ExpiringMap<Scheduler.a>(8192, 5000) { // CraftBukkit - decompile error
protected boolean a(Scheduler.a scheduler_a) {
ProtoChunk protochunk = (ProtoChunk) scheduler_a.a();
@@ -40,6 +40,12 @@
2018-07-25 11:32:06 +02:00
this.f = iasynctaskhandler;
}
+ // CraftBukkit start
+ public void forcePolluteCache(ChunkCoordIntPair chunkcoordintpair) {
2018-08-26 04:00:00 +02:00
+ this.progressCache.put(chunkcoordintpair.a(), new Scheduler.a(chunkcoordintpair, new ProtoChunk(chunkcoordintpair, ChunkConverter.a), ChunkStatus.EMPTY));
2018-07-25 11:32:06 +02:00
+ }
+ // CraftBukkit end
+
2018-08-26 04:00:00 +02:00
@Nullable
protected Scheduler.a a(ChunkCoordIntPair chunkcoordintpair, boolean flag) {
IChunkLoader ichunkloader = this.e;