summaryrefslogtreecommitdiffstats
path: root/nms-patches/ChunkTaskScheduler.patch
blob: a1437645861961cfda57e31a124ad3bf239ce560 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
--- a/net/minecraft/server/ChunkTaskScheduler.java
+++ b/net/minecraft/server/ChunkTaskScheduler.java
@@ -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 @@
         this.f = iasynctaskhandler;
     }
 
+    // CraftBukkit start
+    public void forcePolluteCache(ChunkCoordIntPair chunkcoordintpair) {
+        this.progressCache.put(chunkcoordintpair.a(), new Scheduler.a(chunkcoordintpair, new ProtoChunk(chunkcoordintpair, ChunkConverter.a), ChunkStatus.EMPTY));
+    }
+    // CraftBukkit end
+
     @Nullable
     protected Scheduler.a a(ChunkCoordIntPair chunkcoordintpair, boolean flag) {
         IChunkLoader ichunkloader = this.e;