Skip to content

Commit 79dd62a

Browse files
authored
Use AreaMap for per-player mob spawning (#7235)
1 parent 19bc612 commit 79dd62a

File tree

264 files changed

+207
-457
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

264 files changed

+207
-457
lines changed

patches/server/0364-implement-optional-per-player-mob-spawns.patch

Lines changed: 68 additions & 305 deletions
Large diffs are not rendered by default.

patches/server/0387-Prevent-Double-PlayerChunkMap-adds-crashing-server.patch

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,10 @@ Suspected case would be around the technique used in .stopRiding
77
Stack will identify any causer of this and warn instead of crashing.
88

99
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
10-
index 0583d7ee24f694fbf5138dfae9f7b8c8e4225ab3..27c304d66ecf0bb8d7b5b4343ca207880e14711b 100644
10+
index 2d7f0eb7df62d1c26ccf19cf61595227e19aa562..ed4b4c3d3d991716078d5f008bf4665e76b30f33 100644
1111
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
1212
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
13-
@@ -1539,6 +1539,14 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
13+
@@ -1560,6 +1560,14 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
1414

1515
public void addEntity(Entity entity) {
1616
org.spigotmc.AsyncCatcher.catchOp("entity track"); // Spigot

patches/server/0393-Improved-Watchdog-Support.patch

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -262,10 +262,10 @@ index 049eb5693dc98e1d0ec3bd88c73a41fdb2f59bff..0716aaf29f9d76240a0de4ca02daba44
262262
}
263263

264264
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
265-
index 27c304d66ecf0bb8d7b5b4343ca207880e14711b..6f851c24a67d1b3a349790b0d60f45b23ff93bc6 100644
265+
index ed4b4c3d3d991716078d5f008bf4665e76b30f33..4cb7e63b433b8d4a02c2d193a2596e51ddab2779 100644
266266
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
267267
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
268-
@@ -514,6 +514,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
268+
@@ -535,6 +535,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
269269
MutableBoolean mutableboolean = new MutableBoolean();
270270

271271
do {

patches/server/0403-Fix-Chunk-Post-Processing-deadlock-risk.patch

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ This successfully fixed a reoccurring and highly reproduceable crash
2525
for heightmaps.
2626

2727
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
28-
index 6f851c24a67d1b3a349790b0d60f45b23ff93bc6..4566af37c76cb3a2fe6441451a444a5a3c9914f9 100644
28+
index 4cb7e63b433b8d4a02c2d193a2596e51ddab2779..9396d1164355aa3f10a8e5adad4813be808c0ffb 100644
2929
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
3030
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
3131
@@ -174,6 +174,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
@@ -36,7 +36,7 @@ index 6f851c24a67d1b3a349790b0d60f45b23ff93bc6..4566af37c76cb3a2fe6441451a444a5a
3636
// Paper start - distance maps
3737
private final com.destroystokyo.paper.util.misc.PooledLinkedHashSets<ServerPlayer> pooledLinkedPlayerHashSets = new com.destroystokyo.paper.util.misc.PooledLinkedHashSets<>();
3838

39-
@@ -954,7 +955,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
39+
@@ -975,7 +976,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
4040
return Either.left(chunk);
4141
});
4242
}, (runnable) -> {
@@ -46,10 +46,10 @@ index 6f851c24a67d1b3a349790b0d60f45b23ff93bc6..4566af37c76cb3a2fe6441451a444a5a
4646

4747
completablefuture1.thenAcceptAsync((either) -> {
4848
diff --git a/src/main/java/net/minecraft/server/level/ServerChunkCache.java b/src/main/java/net/minecraft/server/level/ServerChunkCache.java
49-
index 5b6381858418ceca4fe40ef329e050538e980cdb..66dfe3d79fa3273a2bab64193f73f2b38002c18c 100644
49+
index 19c44eae78802c9fe0479cdc32f21156dc9b9d45..02516d4a6ee08908765f5bc84b14560754a67680 100644
5050
--- a/src/main/java/net/minecraft/server/level/ServerChunkCache.java
5151
+++ b/src/main/java/net/minecraft/server/level/ServerChunkCache.java
52-
@@ -1144,6 +1144,7 @@ public class ServerChunkCache extends ChunkSource {
52+
@@ -1140,6 +1140,7 @@ public class ServerChunkCache extends ChunkSource {
5353
return super.pollTask() || execChunkTask; // Paper
5454
}
5555
} finally {

patches/server/0404-Fix-Longstanding-Broken-behavior-of-PlayerJoinEvent.patch

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,10 +28,10 @@ receives a deterministic result, and should no longer require 1 tick
2828
delays anymore.
2929

3030
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
31-
index 4566af37c76cb3a2fe6441451a444a5a3c9914f9..49e612fc0fc4ec991d821d0aa4b41f488dd9f832 100644
31+
index 9396d1164355aa3f10a8e5adad4813be808c0ffb..5f576e6b749e36a4729439930f48e2b1cdddef16 100644
3232
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
3333
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
34-
@@ -1548,6 +1548,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
34+
@@ -1569,6 +1569,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
3535
.printStackTrace();
3636
return;
3737
}

patches/server/0429-Reduce-allocation-of-Vec3D-by-entity-tracker.patch

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,10 @@ Subject: [PATCH] Reduce allocation of Vec3D by entity tracker
55

66

77
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
8-
index 49e612fc0fc4ec991d821d0aa4b41f488dd9f832..62a8482b73796f2c6b76c0e039cb21e799bc9416 100644
8+
index 5f576e6b749e36a4729439930f48e2b1cdddef16..20818ae001a0a1bcf570041468bea33b88fda4ac 100644
99
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
1010
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
11-
@@ -1826,9 +1826,13 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
11+
@@ -1847,9 +1847,13 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
1212
public void updatePlayer(ServerPlayer player) {
1313
org.spigotmc.AsyncCatcher.catchOp("player tracker update"); // Spigot
1414
if (player != this.entity) {

patches/server/0432-Optimize-anyPlayerCloseEnoughForSpawning-to-use-dist.patch

Lines changed: 21 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -37,10 +37,10 @@ index 74d674b2684b0db4aa6c183edc6091d53e9ee882..626bcbc6dd013260c3f8b38a1d14e7ba
3737

3838
// CraftBukkit start
3939
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
40-
index 62a8482b73796f2c6b76c0e039cb21e799bc9416..87b612c25f865af4c8da72c761b70094fb89c4cb 100644
40+
index 7f8c82f2f50934bcc2eacd40a5fbd93d5dae68f6..745b8c16600ba106907302daa9630abdce6807b0 100644
4141
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
4242
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
43-
@@ -177,21 +177,37 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
43+
@@ -177,11 +177,23 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
4444
final CallbackExecutor chunkLoadConversionCallbackExecutor = new CallbackExecutor(); // Paper
4545
// Paper start - distance maps
4646
private final com.destroystokyo.paper.util.misc.PooledLinkedHashSets<ServerPlayer> pooledLinkedPlayerHashSets = new com.destroystokyo.paper.util.misc.PooledLinkedHashSets<>();
@@ -61,28 +61,32 @@ index 62a8482b73796f2c6b76c0e039cb21e799bc9416..87b612c25f865af4c8da72c761b70094
6161
int chunkZ = MCUtil.getChunkCoordinate(player.getZ());
6262
// Note: players need to be explicitly added to distance maps before they can be updated
6363
+ this.playerChunkTickRangeMap.add(player, chunkX, chunkZ, DistanceManager.MOB_SPAWN_RANGE); // Paper - optimise ChunkMap#anyPlayerCloseEnoughForSpawning
64-
}
64+
// Paper start - per player mob spawning
65+
if (this.playerMobDistanceMap != null) {
66+
this.playerMobDistanceMap.add(player, chunkX, chunkZ, this.distanceManager.getSimulationDistance());
67+
@@ -191,6 +203,10 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
6568

6669
void removePlayerFromDistanceMaps(ServerPlayer player) {
67-
-
70+
6871
+ // Paper start - optimise ChunkMap#anyPlayerCloseEnoughForSpawning
6972
+ this.playerMobSpawnMap.remove(player);
7073
+ this.playerChunkTickRangeMap.remove(player);
7174
+ // Paper end - optimise ChunkMap#anyPlayerCloseEnoughForSpawning
72-
}
73-
74-
void updateMaps(ServerPlayer player) {
75+
// Paper start - per player mob spawning
76+
if (this.playerMobDistanceMap != null) {
77+
this.playerMobDistanceMap.remove(player);
78+
@@ -202,6 +218,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
7579
int chunkX = MCUtil.getChunkCoordinate(player.getX());
7680
int chunkZ = MCUtil.getChunkCoordinate(player.getZ());
7781
// Note: players need to be explicitly added to distance maps before they can be updated
7882
+ this.playerChunkTickRangeMap.update(player, chunkX, chunkZ, DistanceManager.MOB_SPAWN_RANGE); // Paper - optimise ChunkMap#anyPlayerCloseEnoughForSpawning
79-
}
80-
// Paper end
81-
// Paper start
82-
@@ -266,6 +282,38 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
83+
// Paper start - per player mob spawning
84+
if (this.playerMobDistanceMap != null) {
85+
this.playerMobDistanceMap.update(player, chunkX, chunkZ, this.distanceManager.getSimulationDistance());
86+
@@ -281,6 +298,38 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
8387
this.regionManagers.add(this.dataRegionManager);
8488
// Paper end
85-
this.playerMobDistanceMap = this.level.paperConfig.perPlayerMobSpawns ? new com.destroystokyo.paper.util.PlayerMobDistanceMap() : null; // Paper
89+
this.playerMobDistanceMap = this.level.paperConfig.perPlayerMobSpawns ? new com.destroystokyo.paper.util.misc.PlayerAreaMap(this.pooledLinkedPlayerHashSets) : null; // Paper
8690
+ // Paper start - optimise ChunkMap#anyPlayerCloseEnoughForSpawning
8791
+ this.playerChunkTickRangeMap = new com.destroystokyo.paper.util.misc.PlayerAreaMap(this.pooledLinkedPlayerHashSets,
8892
+ (ServerPlayer player, int rangeX, int rangeZ, int currPosX, int currPosZ, int prevPosX, int prevPosZ,
@@ -118,15 +122,15 @@ index 62a8482b73796f2c6b76c0e039cb21e799bc9416..87b612c25f865af4c8da72c761b70094
118122
}
119123

120124
protected ChunkGenerator generator() {
121-
@@ -466,6 +514,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
125+
@@ -487,6 +536,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
122126
} else {
123127
if (holder != null) {
124128
holder.setTicketLevel(level);
125129
+ holder.updateRanges(); // Paper - optimise anyPlayerCloseEnoughForSpawning
126130
}
127131

128132
if (holder != null) {
129-
@@ -1310,43 +1359,48 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
133+
@@ -1331,43 +1381,48 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
130134
return this.anyPlayerCloseEnoughForSpawning(pos, false);
131135
}
132136

@@ -269,7 +273,7 @@ index f11e9421d393ef5a04f24c78a1214359710cc2f8..3865146697051e01a778414064425ea0
269273

270274
public String getDebugStatus() {
271275
diff --git a/src/main/java/net/minecraft/server/level/ServerChunkCache.java b/src/main/java/net/minecraft/server/level/ServerChunkCache.java
272-
index 50f3be85039c698bb2f73116a397d6ddaeea6dbd..b10ed9f87e58983863864161457cd415bb782bfd 100644
276+
index 02516d4a6ee08908765f5bc84b14560754a67680..b327bd2f48166a4a0c831b0209695fe5935f6a68 100644
273277
--- a/src/main/java/net/minecraft/server/level/ServerChunkCache.java
274278
+++ b/src/main/java/net/minecraft/server/level/ServerChunkCache.java
275279
@@ -881,6 +881,37 @@ public class ServerChunkCache extends ChunkSource {
@@ -310,7 +314,7 @@ index 50f3be85039c698bb2f73116a397d6ddaeea6dbd..b10ed9f87e58983863864161457cd415
310314
LevelData worlddata = this.level.getLevelData();
311315
ProfilerFiller gameprofilerfiller = this.level.getProfiler();
312316

313-
@@ -928,15 +959,7 @@ public class ServerChunkCache extends ChunkSource {
317+
@@ -924,15 +955,7 @@ public class ServerChunkCache extends ChunkSource {
314318
boolean flag2 = this.level.getGameRules().getBoolean(GameRules.RULE_DOMOBSPAWNING) && !this.level.players().isEmpty(); // CraftBukkit
315319

316320
Collections.shuffle(list);
@@ -327,7 +331,7 @@ index 50f3be85039c698bb2f73116a397d6ddaeea6dbd..b10ed9f87e58983863864161457cd415
327331
Iterator iterator1 = list.iterator();
328332

329333
while (iterator1.hasNext()) {
330-
@@ -944,9 +967,9 @@ public class ServerChunkCache extends ChunkSource {
334+
@@ -940,9 +963,9 @@ public class ServerChunkCache extends ChunkSource {
331335
LevelChunk chunk1 = chunkproviderserver_a.chunk;
332336
ChunkPos chunkcoordintpair = chunk1.getPos();
333337

patches/server/0433-Use-distance-map-to-optimise-entity-tracker.patch

Lines changed: 15 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ Subject: [PATCH] Use distance map to optimise entity tracker
66
Use the distance map to find candidate players for tracking.
77

88
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
9-
index 87b612c25f865af4c8da72c761b70094fb89c4cb..2534cae6f1b369843808aac91931bdc845bbacb1 100644
9+
index 4796e60ade3b576dbe0fe79bc9f0be6085dc7cc8..d358bca3aa0407ede113b4ca6243043f75202267 100644
1010
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
1111
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
1212
@@ -67,6 +67,7 @@ import net.minecraft.network.protocol.game.ClientboundSetEntityLinkPacket;
@@ -17,7 +17,7 @@ index 87b612c25f865af4c8da72c761b70094fb89c4cb..2534cae6f1b369843808aac91931bdc8
1717
import net.minecraft.server.level.progress.ChunkProgressListener;
1818
import net.minecraft.server.network.ServerPlayerConnection;
1919
import net.minecraft.util.CsvOutput;
20-
@@ -188,15 +189,45 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
20+
@@ -188,10 +189,35 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
2121
public final com.destroystokyo.paper.util.misc.PlayerAreaMap playerMobSpawnMap; // this map is absent from updateMaps since it's controlled at the start of the chunkproviderserver tick
2222
public final com.destroystokyo.paper.util.misc.PlayerAreaMap playerChunkTickRangeMap;
2323
// Paper end - optimise ChunkMap#anyPlayerCloseEnoughForSpawning
@@ -52,9 +52,11 @@ index 87b612c25f865af4c8da72c761b70094fb89c4cb..2534cae6f1b369843808aac91931bdc8
5252
+ // Paper end - use distance map to optimise entity tracker
5353
// Note: players need to be explicitly added to distance maps before they can be updated
5454
this.playerChunkTickRangeMap.add(player, chunkX, chunkZ, DistanceManager.MOB_SPAWN_RANGE); // Paper - optimise ChunkMap#anyPlayerCloseEnoughForSpawning
55-
}
55+
// Paper start - per player mob spawning
56+
@@ -203,6 +229,11 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
5657

5758
void removePlayerFromDistanceMaps(ServerPlayer player) {
59+
5860
+ // Paper start - use distance map to optimise tracker
5961
+ for (int i = 0, len = TRACKING_RANGE_TYPES.length; i < len; ++i) {
6062
+ this.playerEntityTrackerTrackMaps[i].remove(player);
@@ -63,7 +65,7 @@ index 87b612c25f865af4c8da72c761b70094fb89c4cb..2534cae6f1b369843808aac91931bdc8
6365
// Paper start - optimise ChunkMap#anyPlayerCloseEnoughForSpawning
6466
this.playerMobSpawnMap.remove(player);
6567
this.playerChunkTickRangeMap.remove(player);
66-
@@ -207,6 +238,14 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
68+
@@ -218,6 +249,14 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
6769
int chunkX = MCUtil.getChunkCoordinate(player.getX());
6870
int chunkZ = MCUtil.getChunkCoordinate(player.getZ());
6971
// Note: players need to be explicitly added to distance maps before they can be updated
@@ -76,12 +78,12 @@ index 87b612c25f865af4c8da72c761b70094fb89c4cb..2534cae6f1b369843808aac91931bdc8
7678
+ }
7779
+ // Paper end - use distance map to optimise entity tracker
7880
this.playerChunkTickRangeMap.update(player, chunkX, chunkZ, DistanceManager.MOB_SPAWN_RANGE); // Paper - optimise ChunkMap#anyPlayerCloseEnoughForSpawning
79-
}
80-
// Paper end
81-
@@ -282,6 +321,45 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
81+
// Paper start - per player mob spawning
82+
if (this.playerMobDistanceMap != null) {
83+
@@ -298,6 +337,45 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
8284
this.regionManagers.add(this.dataRegionManager);
8385
// Paper end
84-
this.playerMobDistanceMap = this.level.paperConfig.perPlayerMobSpawns ? new com.destroystokyo.paper.util.PlayerMobDistanceMap() : null; // Paper
86+
this.playerMobDistanceMap = this.level.paperConfig.perPlayerMobSpawns ? new com.destroystokyo.paper.util.misc.PlayerAreaMap(this.pooledLinkedPlayerHashSets) : null; // Paper
8587
+ // Paper start - use distance map to optimise entity tracker
8688
+ this.playerEntityTrackerTrackMaps = new com.destroystokyo.paper.util.misc.PlayerAreaMap[TRACKING_RANGE_TYPES.length];
8789
+ this.entityTrackerTrackRanges = new int[TRACKING_RANGE_TYPES.length];
@@ -124,7 +126,7 @@ index 87b612c25f865af4c8da72c761b70094fb89c4cb..2534cae6f1b369843808aac91931bdc8
124126
// Paper start - optimise ChunkMap#anyPlayerCloseEnoughForSpawning
125127
this.playerChunkTickRangeMap = new com.destroystokyo.paper.util.misc.PlayerAreaMap(this.pooledLinkedPlayerHashSets,
126128
(ServerPlayer player, int rangeX, int rangeZ, int currPosX, int currPosZ, int prevPosX, int prevPosZ,
127-
@@ -1482,17 +1560,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
129+
@@ -1504,17 +1582,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
128130
}
129131

130132
public void move(ServerPlayer player) {
@@ -143,7 +145,7 @@ index 87b612c25f865af4c8da72c761b70094fb89c4cb..2534cae6f1b369843808aac91931bdc8
143145

144146
int i = SectionPos.blockToSectionCoord(player.getBlockX());
145147
int j = SectionPos.blockToSectionCoord(player.getBlockZ());
146-
@@ -1619,7 +1687,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
148+
@@ -1641,7 +1709,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
147149

148150
entity.tracker = playerchunkmap_entitytracker; // Paper - Fast access to tracker
149151
this.entityMap.put(entity.getId(), playerchunkmap_entitytracker);
@@ -152,7 +154,7 @@ index 87b612c25f865af4c8da72c761b70094fb89c4cb..2534cae6f1b369843808aac91931bdc8
152154
if (entity instanceof ServerPlayer) {
153155
ServerPlayer entityplayer = (ServerPlayer) entity;
154156

155-
@@ -1663,7 +1731,37 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
157+
@@ -1685,7 +1753,37 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
156158
entity.tracker = null; // Paper - We're no longer tracked
157159
}
158160

@@ -190,7 +192,7 @@ index 87b612c25f865af4c8da72c761b70094fb89c4cb..2534cae6f1b369843808aac91931bdc8
190192
List<ServerPlayer> list = Lists.newArrayList();
191193
List<ServerPlayer> list1 = this.level.players();
192194
ObjectIterator objectiterator = this.entityMap.values().iterator();
193-
@@ -1739,23 +1837,31 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
195+
@@ -1761,23 +1859,31 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
194196
DebugPackets.sendPoiPacketsForChunk(this.level, chunk.getPos());
195197
List<Entity> list = Lists.newArrayList();
196198
List<Entity> list1 = Lists.newArrayList();
@@ -234,7 +236,7 @@ index 87b612c25f865af4c8da72c761b70094fb89c4cb..2534cae6f1b369843808aac91931bdc8
234236

235237
Iterator iterator;
236238
Entity entity1;
237-
@@ -1831,6 +1937,42 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
239+
@@ -1853,6 +1959,42 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
238240
this.lastSectionPos = SectionPos.of(entity);
239241
}
240242

0 commit comments

Comments
 (0)