[ci skip] Cleanup Timings v2 diff (#6523)

This commit is contained in:
Jason 2021-08-30 02:02:24 -05:00 committed by GitHub
parent cf27619809
commit 6e9f38ea91
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
19 changed files with 107 additions and 135 deletions

View file

@ -6,7 +6,7 @@ Subject: [PATCH] Use distance map to optimise entity tracker
Use the distance map to find candidate players for tracking.
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
index 2b4c35d9bd186fd7c3650a7ad791cd67fb64e635..514d859ab0fbd25e2217c27dfbbdba1f688848c1 100644
index 5505094b43635c0388dc83515635a9ab00d9eb7a..2ee704a0851f9fd0408b54bee9fe2700421abc7a 100644
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
@@ -63,6 +63,7 @@ import net.minecraft.network.protocol.game.ClientboundSetEntityLinkPacket;
@ -191,7 +191,7 @@ index 2b4c35d9bd186fd7c3650a7ad791cd67fb64e635..514d859ab0fbd25e2217c27dfbbdba1f
List<ServerPlayer> list = Lists.newArrayList();
List<ServerPlayer> list1 = this.level.players();
@@ -1771,23 +1865,31 @@ Sections go from 0..16. Now whenever a section is not empty, it can potentially
@@ -1770,23 +1864,31 @@ Sections go from 0..16. Now whenever a section is not empty, it can potentially
DebugPackets.sendPoiPacketsForChunk(this.level, chunk.getPos());
List<Entity> list = Lists.newArrayList();
List<Entity> list1 = Lists.newArrayList();
@ -235,7 +235,7 @@ index 2b4c35d9bd186fd7c3650a7ad791cd67fb64e635..514d859ab0fbd25e2217c27dfbbdba1f
Iterator iterator;
Entity entity1;
@@ -1870,6 +1972,42 @@ Sections go from 0..16. Now whenever a section is not empty, it can potentially
@@ -1869,6 +1971,42 @@ Sections go from 0..16. Now whenever a section is not empty, it can potentially
this.lastSectionPos = SectionPos.of(entity);
}
@ -278,7 +278,7 @@ index 2b4c35d9bd186fd7c3650a7ad791cd67fb64e635..514d859ab0fbd25e2217c27dfbbdba1f
public boolean equals(Object object) {
return object instanceof ChunkMap.TrackedEntity ? ((ChunkMap.TrackedEntity) object).entity.getId() == this.entity.getId() : false;
}
@@ -1955,7 +2093,7 @@ Sections go from 0..16. Now whenever a section is not empty, it can potentially
@@ -1954,7 +2092,7 @@ Sections go from 0..16. Now whenever a section is not empty, it can potentially
int j = entity.getType().clientTrackingRange() * 16;
j = org.spigotmc.TrackingRange.getEntityTrackingRange(entity, j); // Paper