diff --git a/gradle.properties b/gradle.properties index 72c5c444..a09d9a97 100644 --- a/gradle.properties +++ b/gradle.properties @@ -4,5 +4,5 @@ version=1.20.1-R0.1-SNAPSHOT mcVersion=1.20.1 packageVersion=1_20_R1 org.gradle.jvmargs=-Xmx2G -paperRef=aa93dcfdce20fd15837854d6f89d0ba82cdc5c55 +paperRef=a40e48f3fd95138238d2c6422465d579b7a21e6b preVersion=false diff --git a/patches/server/0002-Leaves-Server-Utils.patch b/patches/server/0002-Leaves-Server-Utils.patch index c23f94d4..151b71e3 100644 --- a/patches/server/0002-Leaves-Server-Utils.patch +++ b/patches/server/0002-Leaves-Server-Utils.patch @@ -31,7 +31,7 @@ index 46954db7ecd35ac4018fdf476df7c8020d7ce6c8..044c51ebb058fc36074fd178929e3279 public PlayerAreaMap() { super(); diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index 3ffb92a82e17af467afb18c81accc482a93d6a6f..499fb6aa4c264f51b9ce2acd9988cd16f864dd2b 100644 +index 4c298406ce06d39f8279049270c88ec0830733b1..d92156a7ad34f7c8e9d43ea5472d33a5e1cd9fdd 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java @@ -417,6 +417,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { @@ -42,7 +42,7 @@ index 3ffb92a82e17af467afb18c81accc482a93d6a6f..499fb6aa4c264f51b9ce2acd9988cd16 public void setOrigin(@javax.annotation.Nonnull Location location) { this.origin = location.toVector(); -@@ -2438,6 +2439,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -2437,6 +2438,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { nbt.putBoolean("Paper.FreezeLock", true); } // Paper end @@ -50,7 +50,7 @@ index 3ffb92a82e17af467afb18c81accc482a93d6a6f..499fb6aa4c264f51b9ce2acd9988cd16 return nbt; } catch (Throwable throwable) { CrashReport crashreport = CrashReport.forThrowable(throwable, "Saving entity NBT"); -@@ -2606,6 +2608,11 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -2605,6 +2607,11 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { freezeLocked = nbt.getBoolean("Paper.FreezeLock"); } // Paper end @@ -62,7 +62,7 @@ index 3ffb92a82e17af467afb18c81accc482a93d6a6f..499fb6aa4c264f51b9ce2acd9988cd16 } catch (Throwable throwable) { CrashReport crashreport = CrashReport.forThrowable(throwable, "Loading entity NBT"); -@@ -4789,4 +4796,10 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -4788,4 +4795,10 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { return ((net.minecraft.server.level.ServerChunkCache) level.getChunkSource()).isPositionTicking(this); } // Paper end diff --git a/patches/server/0005-Fix-gravity-block-duper.patch b/patches/server/0005-Fix-gravity-block-duper.patch index 918f9500..956f110f 100644 --- a/patches/server/0005-Fix-gravity-block-duper.patch +++ b/patches/server/0005-Fix-gravity-block-duper.patch @@ -5,7 +5,7 @@ Subject: [PATCH] Fix gravity block duper diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index 33f657e1a5d7676db00c37f6c8a12abdb9b2374f..b93be8c7da98c4b56d1a6fd74c32509c8d59f853 100644 +index d92156a7ad34f7c8e9d43ea5472d33a5e1cd9fdd..1d76aae6657bb45b540644f7967f04cef24c9992 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java @@ -531,36 +531,8 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { @@ -46,7 +46,7 @@ index 33f657e1a5d7676db00c37f6c8a12abdb9b2374f..b93be8c7da98c4b56d1a6fd74c32509c public Entity(EntityType type, Level world) { this.id = Entity.ENTITY_COUNTER.incrementAndGet(); -@@ -3069,7 +3041,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -3068,7 +3040,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { } this.processPortalCooldown(); diff --git a/patches/server/0040-Reduce-entity-fluid-lookups-if-no-fluids.patch b/patches/server/0040-Reduce-entity-fluid-lookups-if-no-fluids.patch index 0e30cc82..2c22734f 100644 --- a/patches/server/0040-Reduce-entity-fluid-lookups-if-no-fluids.patch +++ b/patches/server/0040-Reduce-entity-fluid-lookups-if-no-fluids.patch @@ -6,10 +6,10 @@ Subject: [PATCH] Reduce entity fluid lookups if no fluids This patch is Powered by Pufferfish(https://github.com/pufferfish-gg/Pufferfish) diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index a26ec93b1914492606499f3ecbbac3a1836295d4..afecf33c1df964decad84636c4e588369ad5ea8a 100644 +index aea1ba7ff85a95a7554bb7102684d5bf9ebfbaa2..0d674998a3d17eb63e32e350b3a235d7df3d186a 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -4295,16 +4295,18 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -4294,16 +4294,18 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { } public boolean updateFluidHeightAndDoFluidPushing(TagKey tag, double speed) { @@ -35,7 +35,7 @@ index a26ec93b1914492606499f3ecbbac3a1836295d4..afecf33c1df964decad84636c4e58836 double d1 = 0.0D; boolean flag = this.isPushedByFluid(); boolean flag1 = false; -@@ -4312,38 +4314,123 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -4311,38 +4313,123 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { int k1 = 0; BlockPos.MutableBlockPos blockposition_mutableblockposition = new BlockPos.MutableBlockPos(); diff --git a/patches/server/0076-Elytra-aeronautics-no-chunk-load.patch b/patches/server/0076-Elytra-aeronautics-no-chunk-load.patch index 454dc5a3..18b1d2b8 100644 --- a/patches/server/0076-Elytra-aeronautics-no-chunk-load.patch +++ b/patches/server/0076-Elytra-aeronautics-no-chunk-load.patch @@ -5,7 +5,7 @@ Subject: [PATCH] Elytra aeronautics no chunk load diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java -index e122a633bc3e26f7a98149f66da8a9e8359c6faf..3b03de0fe88c76b21d58472139b648a9d19bbe08 100644 +index 47d6cd04b179061280e3f78ed543af6bef7ccee4..445582a852826f177f220e3bcd96db3030134f64 100644 --- a/src/main/java/net/minecraft/server/level/ChunkMap.java +++ b/src/main/java/net/minecraft/server/level/ChunkMap.java @@ -195,7 +195,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider @@ -45,7 +45,7 @@ index e122a633bc3e26f7a98149f66da8a9e8359c6faf..3b03de0fe88c76b21d58472139b648a9 int j = SectionPos.blockToSectionCoord(player.getBlockZ()); SectionPos sectionposition = player.getLastSectionPos(); diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 6d40c0b3fbccaa86207603f38b073f36df3880e6..d5659ed1f59967060b4e511a571a7f3765b25c00 100644 +index 4f9b13c8c3add6ce08deed2bc6788ec00b0112ea..f4e49ff40afa4f15b574867e8f607109ddc4e972 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java @@ -653,7 +653,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic @@ -58,10 +58,10 @@ index 6d40c0b3fbccaa86207603f38b073f36df3880e6..d5659ed1f59967060b4e511a571a7f37 !worldserver.areChunksLoadedForMove(entity.getBoundingBox().expandTowards(new Vec3(toX, toY, toZ).subtract(entity.position()))) )) { diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index e9111c5f018815f70f171e606d6a7355be075e39..d8010922d90c8e6aa3951978001b49fe1172da53 100644 +index a65f2d6262af6b34e1e3fbd2f195a788b6c10993..990c1304dd8eb4d7330acb343e00c28b5a3c99a1 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -1089,7 +1089,13 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -1088,7 +1088,13 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { return; } } @@ -76,7 +76,7 @@ index e9111c5f018815f70f171e606d6a7355be075e39..d8010922d90c8e6aa3951978001b49fe this.level().getProfiler().push("move"); if (this.stuckSpeedMultiplier.lengthSqr() > 1.0E-7D) { movement = movement.multiply(this.stuckSpeedMultiplier); -@@ -2012,6 +2018,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -2011,6 +2017,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { this.yo = y; this.zo = d4; this.setPos(d3, y, d4); diff --git a/patches/server/0085-Container-open-passthrough.patch b/patches/server/0085-Container-open-passthrough.patch index 632aba3d..5dbd7270 100644 --- a/patches/server/0085-Container-open-passthrough.patch +++ b/patches/server/0085-Container-open-passthrough.patch @@ -5,7 +5,7 @@ Subject: [PATCH] Container open passthrough diff --git a/src/main/java/net/minecraft/world/level/block/SignBlock.java b/src/main/java/net/minecraft/world/level/block/SignBlock.java -index f7fda6fb4e908869310c783e68f7ad7025840592..be4dd47eec1d002165e7ebca5249728ed5fd68a9 100644 +index e20c24c86db023ad269f15fe04963608e3fb3fe5..d2455f798a00580ebbb45e85ad2a6dcd7671207e 100644 --- a/src/main/java/net/minecraft/world/level/block/SignBlock.java +++ b/src/main/java/net/minecraft/world/level/block/SignBlock.java @@ -96,6 +96,22 @@ public abstract class SignBlock extends BaseEntityBlock implements SimpleWaterlo @@ -29,5 +29,5 @@ index f7fda6fb4e908869310c783e68f7ad7025840592..be4dd47eec1d002165e7ebca5249728e + return InteractionResult.PASS; + // Leaves end - signContainerPassthrough } else if (!this.otherPlayerIsEditingSign(player, signBlockEntity) && player.mayBuild() && this.hasEditableText(player, signBlockEntity, bl2)) { - this.openTextEdit(player, signBlockEntity, bl2); + this.openTextEdit(player, signBlockEntity, bl2, io.papermc.paper.event.player.PlayerOpenSignEvent.Cause.INTERACT); // Paper return InteractionResult.SUCCESS; diff --git a/patches/server/0099-Reduce-array-allocations.patch b/patches/server/0099-Reduce-array-allocations.patch index 3ad1179e..6ef718b7 100644 --- a/patches/server/0099-Reduce-array-allocations.patch +++ b/patches/server/0099-Reduce-array-allocations.patch @@ -73,7 +73,7 @@ index ae60bd96b5284d54676d8e7e4dd5d170b526ec1e..ad33c51ea9f74d2afd39c9139a9114b0 return true; } diff --git a/src/main/java/io/papermc/paper/world/ChunkEntitySlices.java b/src/main/java/io/papermc/paper/world/ChunkEntitySlices.java -index ce449b7b6f615f2c8240e4207f06d4e54ae0083e..454df777262ab969869dd6a651d8113ced4f7c8d 100644 +index 7e8dc9e8f381abfdcce2746edc93122d623622d1..59403aa7b77adab763c60f3f7805c802a94dcd41 100644 --- a/src/main/java/io/papermc/paper/world/ChunkEntitySlices.java +++ b/src/main/java/io/papermc/paper/world/ChunkEntitySlices.java @@ -24,6 +24,7 @@ import java.util.Arrays; @@ -93,7 +93,7 @@ index ce449b7b6f615f2c8240e4207f06d4e54ae0083e..454df777262ab969869dd6a651d8113c } public CompoundTag save() { -@@ -299,7 +300,7 @@ public final class ChunkEntitySlices { +@@ -303,7 +304,7 @@ public final class ChunkEntitySlices { protected static final class BasicEntityList { @@ -102,7 +102,7 @@ index ce449b7b6f615f2c8240e4207f06d4e54ae0083e..454df777262ab969869dd6a651d8113c protected static final int DEFAULT_CAPACITY = 4; protected E[] storage; -@@ -310,7 +311,7 @@ public final class ChunkEntitySlices { +@@ -314,7 +315,7 @@ public final class ChunkEntitySlices { } public BasicEntityList(final int cap) { @@ -111,7 +111,7 @@ index ce449b7b6f615f2c8240e4207f06d4e54ae0083e..454df777262ab969869dd6a651d8113c } public boolean isEmpty() { -@@ -322,7 +323,7 @@ public final class ChunkEntitySlices { +@@ -326,7 +327,7 @@ public final class ChunkEntitySlices { } private void resize() { @@ -482,7 +482,7 @@ index 25ed5571b24e590bc95056020d84496492b53298..89d7364bc645a8b9217e87780cdc0ced for (int j = 0; j < i; ++j) { diff --git a/src/main/java/net/minecraft/world/item/ItemStack.java b/src/main/java/net/minecraft/world/item/ItemStack.java -index 3b8f4c1883a00b4820e8b6fe3e727b5cb2326660..3c2ee97951f88bc1e27de31f30952ae119773858 100644 +index c865979ecce94e02d16f2f4d4d6be16fd5815b6c..0f4ec67c1660755f268c527a96cb8030e8830ec9 100644 --- a/src/main/java/net/minecraft/world/item/ItemStack.java +++ b/src/main/java/net/minecraft/world/item/ItemStack.java @@ -1015,7 +1015,7 @@ public final class ItemStack { diff --git a/patches/server/0100-Optimize-sun-burn-tick.patch b/patches/server/0100-Optimize-sun-burn-tick.patch index ad0486ac..6154f65d 100644 --- a/patches/server/0100-Optimize-sun-burn-tick.patch +++ b/patches/server/0100-Optimize-sun-burn-tick.patch @@ -6,10 +6,10 @@ Subject: [PATCH] Optimize sun burn tick This patch is Powered by Gale(https://github.com/GaleMC/Gale) diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index 10ce5caa3b25aa5e5b015a5d8f3c4b928bc8dfb3..40f3d47eb085663c979719bd648ac593abf0e786 100644 +index 990c1304dd8eb4d7330acb343e00c28b5a3c99a1..70b62bffa6defd2207f69f38fecaa99760bc2bbd 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -1998,8 +1998,22 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -1997,8 +1997,22 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { /** @deprecated */ @Deprecated public float getLightLevelDependentMagicValue() { diff --git a/patches/server/0107-Skip-entity-move-if-movement-is-zero.patch b/patches/server/0107-Skip-entity-move-if-movement-is-zero.patch index 667c9626..f30f1559 100644 --- a/patches/server/0107-Skip-entity-move-if-movement-is-zero.patch +++ b/patches/server/0107-Skip-entity-move-if-movement-is-zero.patch @@ -6,7 +6,7 @@ Subject: [PATCH] Skip entity move if movement is zero This patch is Powered by Gale(https://github.com/GaleMC/Gale) diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index 40f3d47eb085663c979719bd648ac593abf0e786..501208a0407829c72204625964fac40a11384563 100644 +index 70b62bffa6defd2207f69f38fecaa99760bc2bbd..aeb86eb3362893e54e0bf28ab36cdf4d2eea6c31 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java @@ -314,6 +314,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { @@ -17,7 +17,7 @@ index 40f3d47eb085663c979719bd648ac593abf0e786..501208a0407829c72204625964fac40a public boolean onGround; public boolean horizontalCollision; public boolean verticalCollision; -@@ -1067,6 +1068,13 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -1066,6 +1067,13 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { // Paper end - detailed watchdog information public void move(MoverType movementType, Vec3 movement) { @@ -31,7 +31,7 @@ index 40f3d47eb085663c979719bd648ac593abf0e786..501208a0407829c72204625964fac40a // Paper start - detailed watchdog information io.papermc.paper.util.TickThread.ensureTickThread("Cannot move an entity off-main"); synchronized (this.posLock) { -@@ -3988,6 +3996,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -3987,6 +3995,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { } public final void setBoundingBox(AABB boundingBox) { diff --git a/patches/server/0110-Skip-negligible-planar-movement-multiplication.patch b/patches/server/0110-Skip-negligible-planar-movement-multiplication.patch index 9028eedb..2fcea2a2 100644 --- a/patches/server/0110-Skip-negligible-planar-movement-multiplication.patch +++ b/patches/server/0110-Skip-negligible-planar-movement-multiplication.patch @@ -6,10 +6,10 @@ Subject: [PATCH] Skip negligible planar movement multiplication This patch is Powered by Gale(https://github.com/GaleMC/Gale) diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index 501208a0407829c72204625964fac40a11384563..ffc617fec161d42c3d393a8bcb286528df3f83f5 100644 +index aeb86eb3362893e54e0bf28ab36cdf4d2eea6c31..515b90384ce5a168496635226f4df92ea3a7a915 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -1238,9 +1238,16 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -1237,9 +1237,16 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { } this.tryCheckInsideBlocks();