mirror of
https://github.com/PaperMC/Paper.git
synced 2025-07-31 12:12:08 -07:00
Remove making unused copy of visible chunks in ChunkMap#processUnloads
This commit is contained in:
@@ -242,14 +242,20 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
|
||||
if (flush) {
|
||||
List<ChunkHolder> list = (List) this.visibleChunkMap.values().stream().filter(ChunkHolder::wasAccessibleSinceLastSave).peek(ChunkHolder::refreshAccessibility).collect(Collectors.toList());
|
||||
@@ -0,0 +0,0 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||
int l = 0;
|
||||
ObjectIterator objectiterator = this.visibleChunkMap.values().iterator();
|
||||
}
|
||||
|
||||
int l = 0;
|
||||
- ObjectIterator objectiterator = this.visibleChunkMap.values().iterator();
|
||||
-
|
||||
- while (l < 20 && shouldKeepTicking.getAsBoolean() && objectiterator.hasNext()) {
|
||||
+ while (false && l < 20 && shouldKeepTicking.getAsBoolean() && objectiterator.hasNext()) { // Paper - incremental chunk and player saving
|
||||
if (this.saveChunkIfNeeded((ChunkHolder) objectiterator.next())) {
|
||||
++l;
|
||||
}
|
||||
- if (this.saveChunkIfNeeded((ChunkHolder) objectiterator.next())) {
|
||||
- ++l;
|
||||
- }
|
||||
- }
|
||||
+ // Paper - incremental chunk and player saving
|
||||
|
||||
}
|
||||
|
||||
@@ -0,0 +0,0 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||
|
||||
this.level.unload(chunk);
|
||||
|
Reference in New Issue
Block a user