Updated Upstream (Paper, Tuinity, & Airplane)

Upstream has released updates that appear to apply and compile correctly

Paper Changes:
809466f2e Fix anchor respawn acting as a bed respawn when using the end portal (#5540)
d219fd642 [Auto] Updated Upstream (Bukkit/CraftBukkit)
db464b099 Implement methods to convert between Component and Brigadier's Message (#5542)
4047cffca Add PlayerBedFailEnterEvent (#4935)
70d697e6e Update Paperpclip
5ed771591 [CI-SKIP] Remove bad null annotation (#5538)
454a4c78e More World API (#3850)
869e02304 Add PlayerDeepSleepEvent (#5525)
fb56fc35e fix non-dummy objectives not updating
dc859a61f [CI-SKIP] [Auto] Rebuild Patches
7d1689f1a  Add missing checkReachable check for shulker boxes (#5453)
ba8eb3d4b Add missing Javadoc for COLORABLE MaterialTag (#5376)
db801cbf3 Fix PlayerItemHeldEvent firing twice (#5534)
14de2b795 fix PigZombieAngerEvent cancellation (fixes #5319) (v2) (#5329)
86d684ad1 Add get-set drop chance to EntityEquipment (#5528)
33fb8cf63 Add consumeFuel to FurnaceBurnEvent (#5532)
9957f4630 Fix duplicating /give items on item drop cancel (#5536)
d94882043 Fix legacyComposer not using AsyncChatEvent messages (#5509)
053bd82cc Don't print spawn load time when not loading spawn (#5467)
a6d78caae Add isDeeplySleeping to HumanEntity (#5470)
711b7a80b Expose more Adventure serializers through PaperComponents (#5443)
3f63bde0c Set Area Effect Cloud Rotation (#5462)
3523f0fda Remove useless check on player interact cancellation (#5448)
6574d1aa8 fix #5526 - use correct type when sending message to clients
dbfa833ec don't throw when loading TE with invalid keys
a9525a6f7 Do not schedule poi task for each block write on chunk gen
39bf5b525 Update teams known as code owners
fbae9dbe0 [Auto] Updated Upstream (Bukkit/CraftBukkit)
ac4a33aab [Auto] Updated Upstream (Bukkit)
c1e07158b [Auto] Updated Upstream (Bukkit/CraftBukkit)
5e4b88e95 Fix dangling sout
23afda179 basic hostname validation
0fb8bdf0e Updated Upstream (Bukkit/CraftBukkit) (#5508)
88ab784da [Auto] Updated Upstream (CraftBukkit)
ca7111d5f Fix PlayerItemConsumeEvent cancelling (fixes #4682) (#5383)
06fb560dc Add support for tab completing and highlighting console input from the Brigadier command tree (#5437)
0a9b89c7a Fix occasional light gen issues for neighbor blocks (#5500)

Tuinity Changes:
b12d0cce3 Replace ticket level propagator
42df8e1e0 Correctly handle recursion for chunkholder updates
73eb2a856 Do not copy visible chunks
8a4f3be69 Do not schedule poi task for each block write on chunk gen
7d36676fc Fix light source locking
f1ec0c20d Add concurrency check to ProtoChunk light sources
159d1468f Improvements to chunk loader system
32b4d526b Updated Upstream (Paper)
ac5adca33 Make sure lit is set for pre 1.14 chunks

Airplane Changes:
d8bdbc508 Reduce allocations for fire spreading
41051fd56 Redo reduction of entity chunk ticking check patch
31272d80f Flare Update
8f3271328 Remove criterion patch
0fed2df62 Various patches that need to be reorganized later
f78856bde Updated Upstream (Tuinity)
f7d6382ad Flare Update
71d079991 Update gradle configuration
0f7977428 Updated Upstream (Tuinity)
3b3cde7b0 Correctly use DEAR values, fix config reloading
dd6091981 Updated Upstream (Tuinity)
07897895b Updated Upstream (Tuinity)
c1e4d7143 Fluid cache patch
This commit is contained in:
Ben Kerllenevich
2021-04-25 12:34:17 -04:00
committed by Jason
parent 5674cdc743
commit e97d062cb0
81 changed files with 1353 additions and 433 deletions

View File

@@ -42,10 +42,10 @@ index be408aebbccbda46e8aa82ef337574137cfa0096..739839314fd8a88b5fca8b9678e1df07
private final boolean threadRestricted;
diff --git a/src/main/java/gg/airplane/AirplaneConfig.java b/src/main/java/gg/airplane/AirplaneConfig.java
index a77e628518920e84b03a8a00e1308a9a53a00896..5a20ad857b7c550281000e8d94dac78d72591f31 100644
index 7ec84ef1d1cbb1fabf4c590a2f2c1da3cc181010..b9118cc08ac38e0813d0677700d3d7dcf9b74159 100644
--- a/src/main/java/gg/airplane/AirplaneConfig.java
+++ b/src/main/java/gg/airplane/AirplaneConfig.java
@@ -96,4 +96,17 @@ public class AirplaneConfig {
@@ -102,4 +102,17 @@ public class AirplaneConfig {
}
@@ -197,7 +197,7 @@ index 0000000000000000000000000000000000000000..4419fbe94041f4b8a0ea848880798289
+
+}
diff --git a/src/main/java/net/minecraft/server/level/ChunkProviderServer.java b/src/main/java/net/minecraft/server/level/ChunkProviderServer.java
index 87c87b9767003652814c3726eece64470dbb69a8..dc1b7db4d39d4dfa65d60e5a059d3b94def6cf62 100644
index 207a9c3928aad7c6e89a120b54d87e003ebd232c..424cd048f905cd0ed3f7a4545a26ffde8da1f91f 100644
--- a/src/main/java/net/minecraft/server/level/ChunkProviderServer.java
+++ b/src/main/java/net/minecraft/server/level/ChunkProviderServer.java
@@ -388,7 +388,7 @@ public class ChunkProviderServer extends IChunkProvider {
@@ -210,7 +210,7 @@ index 87c87b9767003652814c3726eece64470dbb69a8..dc1b7db4d39d4dfa65d60e5a059d3b94
public ChunkProviderServer(WorldServer worldserver, Convertable.ConversionSession convertable_conversionsession, DataFixer datafixer, DefinedStructureManager definedstructuremanager, Executor executor, ChunkGenerator chunkgenerator, int i, boolean flag, WorldLoadListener worldloadlistener, Supplier<WorldPersistentData> supplier) {
diff --git a/src/main/java/net/minecraft/server/level/EntityPlayer.java b/src/main/java/net/minecraft/server/level/EntityPlayer.java
index 62b95dcba8606330fbb3239e74c5eaf8baa3c51d..fd6dbbf619b828c4ef3d00f8dc30d3893007db7b 100644
index fb61b6ac167b34486282a24e598020fb96081f28..b2e21e7034ad83a4ba1c99f860be5a0f5ee6a75f 100644
--- a/src/main/java/net/minecraft/server/level/EntityPlayer.java
+++ b/src/main/java/net/minecraft/server/level/EntityPlayer.java
@@ -182,7 +182,7 @@ public class EntityPlayer extends EntityHuman implements ICrafting {
@@ -316,22 +316,22 @@ index 67ca28463f5add7c18f7f16b918c3f36f8feeeda..37e64e24ca3a90370cdf12e5ff9cd1fc
if (this.tracker instanceof EntityPlayer) {
((EntityPlayer) this.tracker).playerConnection.sendPacket(packet);
diff --git a/src/main/java/net/minecraft/server/level/PlayerChunkMap.java b/src/main/java/net/minecraft/server/level/PlayerChunkMap.java
index bc18b9c3aac4c5feeb1603554e0ac009af9b457e..c9d6ddd8874195c07b3573c6b1f61ffdcff2dddd 100644
index 914c7a1b18151f29183cfe9474313ce18e7c4ae2..737851cde7752e7cccf226f1868a38d6411bfb31 100644
--- a/src/main/java/net/minecraft/server/level/PlayerChunkMap.java
+++ b/src/main/java/net/minecraft/server/level/PlayerChunkMap.java
@@ -791,6 +791,11 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
return (PlayerChunk) (this.hasPendingVisibleUpdate ? this.pendingVisibleChunks.get(i) : ((ProtectedVisibleChunksMap)this.visibleChunks).safeGet(i));
// Paper end
@@ -769,6 +769,11 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
return this.updatingChunks.getVisibleAsync(i);
// Tuinity end - Don't copy
}
+ // Airplane start - since neither map can be updated during tracker tick, it's safe to allow direct retrieval here
+ private PlayerChunk trackerGetVisibleChunk(long i) {
+ return this.hasPendingVisibleUpdate ? this.pendingVisibleChunks.get(i) : ((ProtectedVisibleChunksMap) this.visibleChunks).safeGet(i);
+ return this.updatingChunks.getVisibleAsync(i);
+ }
+ // Airplane end
protected final IntSupplier getPrioritySupplier(long i) { return c(i); } // Paper - OBFHELPER
protected IntSupplier c(long i) {
@@ -2194,10 +2199,30 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
@@ -2164,10 +2169,30 @@ public class PlayerChunkMap extends IChunkLoader implements PlayerChunk.d {
entity.tracker = null; // Paper - We're no longer tracked
}
@@ -362,7 +362,7 @@ index bc18b9c3aac4c5feeb1603554e0ac009af9b457e..c9d6ddd8874195c07b3573c6b1f61ffd
com.tuinity.tuinity.util.maplist.IteratorSafeOrderedReferenceSet.Iterator<Chunk> iterator = this.world.getChunkProvider().entityTickingChunks.iterator();
try {
while (iterator.hasNext()) {
@@ -2463,7 +2488,7 @@ Sections go from 0..16. Now whenever a section is not empty, it can potentially
@@ -2433,7 +2458,7 @@ Sections go from 0..16. Now whenever a section is not empty, it can potentially
public class EntityTracker {
final EntityTrackerEntry trackerEntry; // Paper - private -> package private
@@ -371,7 +371,7 @@ index bc18b9c3aac4c5feeb1603554e0ac009af9b457e..c9d6ddd8874195c07b3573c6b1f61ffd
private final int trackingDistance;
private SectionPosition e;
// Paper start
@@ -2482,7 +2507,9 @@ Sections go from 0..16. Now whenever a section is not empty, it can potentially
@@ -2452,7 +2477,9 @@ Sections go from 0..16. Now whenever a section is not empty, it can potentially
// Paper start - use distance map to optimise tracker
com.destroystokyo.paper.util.misc.PooledLinkedHashSets.PooledObjectLinkedOpenHashSet<EntityPlayer> lastTrackerCandidates;
@@ -382,7 +382,7 @@ index bc18b9c3aac4c5feeb1603554e0ac009af9b457e..c9d6ddd8874195c07b3573c6b1f61ffd
com.destroystokyo.paper.util.misc.PooledLinkedHashSets.PooledObjectLinkedOpenHashSet<EntityPlayer> oldTrackerCandidates = this.lastTrackerCandidates;
this.lastTrackerCandidates = newTrackerCandidates;
@@ -2523,7 +2550,13 @@ Sections go from 0..16. Now whenever a section is not empty, it can potentially
@@ -2493,7 +2520,13 @@ Sections go from 0..16. Now whenever a section is not empty, it can potentially
return this.tracker.getId();
}
@@ -397,7 +397,7 @@ index bc18b9c3aac4c5feeb1603554e0ac009af9b457e..c9d6ddd8874195c07b3573c6b1f61ffd
Iterator iterator = this.trackedPlayers.iterator();
while (iterator.hasNext()) {
@@ -2535,6 +2568,12 @@ Sections go from 0..16. Now whenever a section is not empty, it can potentially
@@ -2505,6 +2538,12 @@ Sections go from 0..16. Now whenever a section is not empty, it can potentially
}
public void broadcastIncludingSelf(Packet<?> packet) {
@@ -410,7 +410,7 @@ index bc18b9c3aac4c5feeb1603554e0ac009af9b457e..c9d6ddd8874195c07b3573c6b1f61ffd
this.broadcast(packet);
if (this.tracker instanceof EntityPlayer) {
((EntityPlayer) this.tracker).playerConnection.sendPacket(packet);
@@ -2561,8 +2600,8 @@ Sections go from 0..16. Now whenever a section is not empty, it can potentially
@@ -2531,8 +2570,8 @@ Sections go from 0..16. Now whenever a section is not empty, it can potentially
}
@@ -421,7 +421,7 @@ index bc18b9c3aac4c5feeb1603554e0ac009af9b457e..c9d6ddd8874195c07b3573c6b1f61ffd
if (entityplayer != this.tracker) {
// Paper start - remove allocation of Vec3D here
//Vec3D vec3d = entityplayer.getPositionVector().d(this.tracker.getPositionVector()); // MC-155077, SPIGOT-5113
@@ -2583,7 +2622,7 @@ Sections go from 0..16. Now whenever a section is not empty, it can potentially
@@ -2553,7 +2592,7 @@ Sections go from 0..16. Now whenever a section is not empty, it can potentially
*/
int x = this.tracker.chunkX, z = this.tracker.chunkZ;
long chunkcoordintpair = ChunkCoordIntPair.pair(x, z);
@@ -431,7 +431,7 @@ index bc18b9c3aac4c5feeb1603554e0ac009af9b457e..c9d6ddd8874195c07b3573c6b1f61ffd
if (playerchunk != null && playerchunk.getSendingChunk() != null && PlayerChunkMap.this.playerChunkManager.isChunkSent(entityplayer, MathHelper.floor(this.tracker.locX()) >> 4, MathHelper.floor(this.tracker.locZ()) >> 4)) { // Paper - no-tick view distance // Tuinity - don't broadcast in chunks the player hasn't received
flag1 = PlayerChunkMap.someDistanceCalculation(x, z, entityplayer, false) <= PlayerChunkMap.this.viewDistance;
diff --git a/src/main/java/net/minecraft/world/level/chunk/Chunk.java b/src/main/java/net/minecraft/world/level/chunk/Chunk.java
index 7474c070598bc093e06f02f19d49f3a6fa6b3d4e..c07fb5ca761c0f2067bd103026ded618a8620947 100644
index 9ba7c5080ce0cacf438bdd6e11f75cb34fbc5759..cef0462fadb305ebc2b53d37e0c17514626df99d 100644
--- a/src/main/java/net/minecraft/world/level/chunk/Chunk.java
+++ b/src/main/java/net/minecraft/world/level/chunk/Chunk.java
@@ -111,6 +111,26 @@ public class Chunk implements IChunkAccess {