diff --git a/gradle.properties b/gradle.properties index 00d47d13a..e7619ca34 100644 --- a/gradle.properties +++ b/gradle.properties @@ -2,7 +2,7 @@ group = org.purpurmc.purpur version = 1.21.1-R0.1-SNAPSHOT mcVersion = 1.21.1 -paperCommit = 11b4ac7c659ffb7e4790b0856b14117b6d532200 +paperCommit = 4829fbf6bd51e2dc86e2f190971c081aac76a201 org.gradle.caching = true org.gradle.parallel = true diff --git a/patches/server/0001-Pufferfish-Server-Changes.patch b/patches/server/0001-Pufferfish-Server-Changes.patch index ed50da5d3..9fc5b8a30 100644 --- a/patches/server/0001-Pufferfish-Server-Changes.patch +++ b/patches/server/0001-Pufferfish-Server-Changes.patch @@ -1413,10 +1413,10 @@ index 2fe9d9b38c01d04416843fdd48d3e33899b7de63..5a9712de8abe3c3ccd08c5699f89e3ce if (this.isRainingAt(blockposition)) { diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 60ff21c8df4168f14da04a12073bde47cd4693c4..301dc8ea0574f02f28067cda397683c7e7a6152f 100644 +index 750f216400a473ed6895273c99ff89960bb56833..3d1dc6d712f61de2a4927b3bf2973f75af24cf11 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -1123,6 +1123,7 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl +@@ -1157,6 +1157,7 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl @Override public void handleEditBook(ServerboundEditBookPacket packet) { diff --git a/patches/server/0008-Component-related-conveniences.patch b/patches/server/0008-Component-related-conveniences.patch index 08cdd6896..975c0e842 100644 --- a/patches/server/0008-Component-related-conveniences.patch +++ b/patches/server/0008-Component-related-conveniences.patch @@ -36,10 +36,10 @@ index cb25a8796dda84fb08865a2af769fb4d10597685..ffc7f4f4544df21b713b780eded8aeba public void displayClientMessage(Component message, boolean overlay) { this.sendSystemMessage(message, overlay); diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java -index 43eeb8ce4bc350c2b524ade11ca25d8d4d21bea5..063ac25725543988332bdaf0c600e1f6c429943e 100644 +index 0368d6ba9cc9fe557d3c7172a87a7a5b15445e47..7d0407951d869dc673d6362999312e1dad00d9a4 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -1017,6 +1017,20 @@ public abstract class PlayerList { +@@ -1020,6 +1020,20 @@ public abstract class PlayerList { } // CraftBukkit end diff --git a/patches/server/0009-Ridables.patch b/patches/server/0009-Ridables.patch index 6ab849d8f..0a2928e67 100644 --- a/patches/server/0009-Ridables.patch +++ b/patches/server/0009-Ridables.patch @@ -66,10 +66,10 @@ index ffc7f4f4544df21b713b780eded8aeba4090db52..6cad742f0141ac0e4b4b5a1dd07874eb private void updatePlayerAttributes() { diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 301dc8ea0574f02f28067cda397683c7e7a6152f..ff97005181c2b55ffb2be6d19f27b34f26a2e20c 100644 +index 3d1dc6d712f61de2a4927b3bf2973f75af24cf11..b958bfbe87b559417ec6241c14a91e09e0b583d4 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -2713,6 +2713,8 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl +@@ -2785,6 +2785,8 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl ServerGamePacketListenerImpl.this.cserver.getPluginManager().callEvent(event); diff --git a/patches/server/0011-Barrels-and-enderchests-6-rows.patch b/patches/server/0011-Barrels-and-enderchests-6-rows.patch index 84e60ccd3..d9cb39ece 100644 --- a/patches/server/0011-Barrels-and-enderchests-6-rows.patch +++ b/patches/server/0011-Barrels-and-enderchests-6-rows.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Barrels and enderchests 6 rows diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java -index 063ac25725543988332bdaf0c600e1f6c429943e..d52c598573d9ac470a39b5a6c47a2a6be3741a76 100644 +index 7d0407951d869dc673d6362999312e1dad00d9a4..34179365c6ac7a3b19f9cd76a8522a597e380a4a 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -1142,6 +1142,27 @@ public abstract class PlayerList { +@@ -1145,6 +1145,27 @@ public abstract class PlayerList { player.getBukkitEntity().recalculatePermissions(); // CraftBukkit this.server.getCommands().sendCommands(player); } // Paper - Add sendOpLevel API diff --git a/patches/server/0013-AFK-API.patch b/patches/server/0013-AFK-API.patch index ffc64c490..f05e111a8 100644 --- a/patches/server/0013-AFK-API.patch +++ b/patches/server/0013-AFK-API.patch @@ -78,7 +78,7 @@ index 6cad742f0141ac0e4b4b5a1dd07874eb7588e70f..fe0bbaec0a47305da244bbca7b9ce640 return this.stats; } diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index ff97005181c2b55ffb2be6d19f27b34f26a2e20c..cb9efbba91510d90fa4a7dbe01fa6e9ba8206612 100644 +index b958bfbe87b559417ec6241c14a91e09e0b583d4..0ec1a50485ce0107fe1983fd079be850b2341d46 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java @@ -332,6 +332,20 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl @@ -115,7 +115,7 @@ index ff97005181c2b55ffb2be6d19f27b34f26a2e20c..cb9efbba91510d90fa4a7dbe01fa6e9b this.player.resetLastActionTime(); // CraftBukkit - SPIGOT-854 this.disconnect((Component) Component.translatable("multiplayer.disconnect.idling"), org.bukkit.event.player.PlayerKickEvent.Cause.IDLING); // Paper - kick event cause } -@@ -649,6 +669,8 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl +@@ -658,6 +678,8 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl this.lastYaw = to.getYaw(); this.lastPitch = to.getPitch(); @@ -124,7 +124,7 @@ index ff97005181c2b55ffb2be6d19f27b34f26a2e20c..cb9efbba91510d90fa4a7dbe01fa6e9b Location oldTo = to.clone(); PlayerMoveEvent event = new PlayerMoveEvent(player, from, to); this.cserver.getPluginManager().callEvent(event); -@@ -1450,7 +1472,7 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl +@@ -1485,7 +1507,7 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl movedWrongly = true; if (event.getLogWarning()) // Paper end @@ -133,7 +133,7 @@ index ff97005181c2b55ffb2be6d19f27b34f26a2e20c..cb9efbba91510d90fa4a7dbe01fa6e9b } // Paper } -@@ -1508,6 +1530,8 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl +@@ -1553,6 +1575,8 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl this.lastYaw = to.getYaw(); this.lastPitch = to.getPitch(); diff --git a/patches/server/0045-Add-permission-for-F3-N-debug.patch b/patches/server/0045-Add-permission-for-F3-N-debug.patch index 944d7eca0..863b1c696 100644 --- a/patches/server/0045-Add-permission-for-F3-N-debug.patch +++ b/patches/server/0045-Add-permission-for-F3-N-debug.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Add permission for F3+N debug diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java -index d52c598573d9ac470a39b5a6c47a2a6be3741a76..105688ba795676a0612969f89668c9c8bda48f54 100644 +index 34179365c6ac7a3b19f9cd76a8522a597e380a4a..d13270623d0630f94c7911bd8a544f1ee9449b17 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -1134,6 +1134,7 @@ public abstract class PlayerList { +@@ -1137,6 +1137,7 @@ public abstract class PlayerList { } else { b0 = (byte) (24 + permissionLevel); } diff --git a/patches/server/0071-Allow-color-codes-in-books.patch b/patches/server/0071-Allow-color-codes-in-books.patch index b0d1dcced..e07b50e49 100644 --- a/patches/server/0071-Allow-color-codes-in-books.patch +++ b/patches/server/0071-Allow-color-codes-in-books.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Allow color codes in books diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index cb9efbba91510d90fa4a7dbe01fa6e9ba8206612..7a2bc00ee456caf48d3261f065fb1c9e760b813b 100644 +index 0ec1a50485ce0107fe1983fd079be850b2341d46..efaa369dc1a01e4e40bec8a6a5562e7c1822b1ac 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -1199,10 +1199,14 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl +@@ -1233,10 +1233,14 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl Objects.requireNonNull(list); stream.forEach(list::add); @@ -25,7 +25,7 @@ index cb9efbba91510d90fa4a7dbe01fa6e9ba8206612..7a2bc00ee456caf48d3261f065fb1c9e }; this.filterTextPacket((List) list).thenAcceptAsync(consumer, this.server); -@@ -1210,13 +1214,18 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl +@@ -1244,13 +1248,18 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl } private void updateBookContents(List pages, int slotId) { @@ -45,7 +45,7 @@ index cb9efbba91510d90fa4a7dbe01fa6e9ba8206612..7a2bc00ee456caf48d3261f065fb1c9e itemstack.set(DataComponents.WRITABLE_BOOK_CONTENT, new WritableBookContent(list1)); this.player.getInventory().setItem(slotId, CraftEventFactory.handleEditBookEvent(this.player, slotId, handItem, itemstack)); // CraftBukkit // Paper - Don't ignore result (see other callsite for handleEditBookEvent) -@@ -1224,6 +1233,11 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl +@@ -1258,6 +1267,11 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl } private void signBook(FilteredText title, List pages, int slotId) { @@ -57,7 +57,7 @@ index cb9efbba91510d90fa4a7dbe01fa6e9ba8206612..7a2bc00ee456caf48d3261f065fb1c9e ItemStack itemstack = this.player.getInventory().getItem(slotId); if (itemstack.is(Items.WRITABLE_BOOK)) { -@@ -1231,10 +1245,10 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl +@@ -1265,10 +1279,10 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl itemstack1.remove(DataComponents.WRITABLE_BOOK_CONTENT); List> list1 = (List>) (List) pages.stream().map((filteredtext1) -> { // CraftBukkit - decompile error @@ -70,7 +70,7 @@ index cb9efbba91510d90fa4a7dbe01fa6e9ba8206612..7a2bc00ee456caf48d3261f065fb1c9e CraftEventFactory.handleEditBookEvent(this.player, slotId, itemstack, itemstack1); // CraftBukkit this.player.getInventory().setItem(slotId, itemstack); // CraftBukkit - event factory updates the hand book } -@@ -1244,6 +1258,16 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl +@@ -1278,6 +1292,16 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl return this.player.isTextFilteringEnabled() ? Filterable.passThrough(message.filteredOrEmpty()) : Filterable.from(message); } diff --git a/patches/server/0072-Entity-lifespan.patch b/patches/server/0072-Entity-lifespan.patch index c5ec53c1f..e84a02028 100644 --- a/patches/server/0072-Entity-lifespan.patch +++ b/patches/server/0072-Entity-lifespan.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Entity lifespan diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 7a2bc00ee456caf48d3261f065fb1c9e760b813b..f71219cc6805c214a130643144c02332d0df5750 100644 +index efaa369dc1a01e4e40bec8a6a5562e7c1822b1ac..1121011d188db81be723e12fa734c3659d993176 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -2748,6 +2748,7 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl +@@ -2820,6 +2820,7 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl AABB axisalignedbb = entity.getBoundingBox(); if (this.player.canInteractWithEntity(axisalignedbb, io.papermc.paper.configuration.GlobalConfiguration.get().misc.clientInteractionLeniencyDistance.or(1.0D))) { // Paper - configurable lenience value for interact range diff --git a/patches/server/0117-PlayerBookTooLargeEvent.patch b/patches/server/0117-PlayerBookTooLargeEvent.patch index 7c8441865..ca8fd72e7 100644 --- a/patches/server/0117-PlayerBookTooLargeEvent.patch +++ b/patches/server/0117-PlayerBookTooLargeEvent.patch @@ -5,10 +5,10 @@ Subject: [PATCH] PlayerBookTooLargeEvent diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index f71219cc6805c214a130643144c02332d0df5750..e327b9400bf29b6712e6d559f174cd31238db515 100644 +index 1121011d188db81be723e12fa734c3659d993176..1662892485ec26e191dd21c14b8e8aae87afac41 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -1153,6 +1153,10 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl +@@ -1187,6 +1187,10 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl int maxBookPageSize = io.papermc.paper.configuration.GlobalConfiguration.get().itemValidation.bookSize.pageMax; double multiplier = Math.clamp(io.papermc.paper.configuration.GlobalConfiguration.get().itemValidation.bookSize.totalMultiplier, 0.3D, 1D); long byteAllowed = maxBookPageSize; @@ -19,7 +19,7 @@ index f71219cc6805c214a130643144c02332d0df5750..e327b9400bf29b6712e6d559f174cd31 for (String testString : pageList) { int byteLength = testString.getBytes(java.nio.charset.StandardCharsets.UTF_8).length; byteTotal += byteLength; -@@ -1174,7 +1178,8 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl +@@ -1208,7 +1212,8 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl } if (byteTotal > byteAllowed) { diff --git a/patches/server/0129-Dont-run-with-scissors.patch b/patches/server/0129-Dont-run-with-scissors.patch index 1d17060ff..a915231c5 100644 --- a/patches/server/0129-Dont-run-with-scissors.patch +++ b/patches/server/0129-Dont-run-with-scissors.patch @@ -6,10 +6,10 @@ Subject: [PATCH] Dont run with scissors! inspired by https://modrinth.com/mod/dont-run-with-scissors diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index e327b9400bf29b6712e6d559f174cd31238db515..435ab19d1fad30cd75aa705861760674b09ea0ac 100644 +index 1662892485ec26e191dd21c14b8e8aae87afac41..65cac2fa564071f5dc3d67b320825b24f6976626 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -1605,6 +1605,13 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl +@@ -1650,6 +1650,13 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl this.player.tryResetCurrentImpulseContext(); } @@ -23,7 +23,7 @@ index e327b9400bf29b6712e6d559f174cd31238db515..435ab19d1fad30cd75aa705861760674 this.player.checkMovementStatistics(this.player.getX() - d3, this.player.getY() - d4, this.player.getZ() - d5); this.lastGoodX = this.player.getX(); this.lastGoodY = this.player.getY(); -@@ -1632,6 +1639,14 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl +@@ -1677,6 +1684,14 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl } } @@ -35,9 +35,9 @@ index e327b9400bf29b6712e6d559f174cd31238db515..435ab19d1fad30cd75aa705861760674 + } + // Purpur end + - private boolean isPlayerCollidingWithAnythingNew(LevelReader world, AABB box, double newX, double newY, double newZ) { - AABB axisalignedbb1 = this.player.getBoundingBox().move(newX - this.player.getX(), newY - this.player.getY(), newZ - this.player.getZ()); - Iterable iterable = world.getCollisions(this.player, axisalignedbb1.deflate(9.999999747378752E-6D)); + // Paper start - optimise out extra getCubes + private boolean hasNewCollision(final ServerLevel world, final Entity entity, final AABB oldBox, final AABB newBox) { + final List collisionsBB = new java.util.ArrayList<>(); diff --git a/src/main/java/net/minecraft/world/damagesource/CombatTracker.java b/src/main/java/net/minecraft/world/damagesource/CombatTracker.java index 99a7e9eb75231c15bd8bb24fbb4e296bc9fdedff..a375d40ec6365ba8704ba3ece22dd5b2de9857b5 100644 --- a/src/main/java/net/minecraft/world/damagesource/CombatTracker.java diff --git a/patches/server/0183-Store-placer-on-Block-when-placed.patch b/patches/server/0183-Store-placer-on-Block-when-placed.patch index 663deb293..fff03cca4 100644 --- a/patches/server/0183-Store-placer-on-Block-when-placed.patch +++ b/patches/server/0183-Store-placer-on-Block-when-placed.patch @@ -25,10 +25,10 @@ index 3e29f00366511d88c90048ba8017a1de6dc87ebf..f9b1072c794b995781390af7ea542dd4 world.notifyAndUpdatePhysics(newblockposition, null, oldBlock, block, world.getBlockState(newblockposition), updateFlag, 512); // send null chunk as chunk.k() returns false by this point } diff --git a/src/main/java/net/minecraft/world/level/block/Block.java b/src/main/java/net/minecraft/world/level/block/Block.java -index a7108b2be0746aa1f0e574d8c6f5ffad6d369835..57595a781a3cbdd8575c4af36328684ce7fc28d9 100644 +index 29947de9eb6887f2e61516523ff08d8b581b0f53..5dd4ccde6c4c421f697f629adb1adfadce7b8a42 100644 --- a/src/main/java/net/minecraft/world/level/block/Block.java +++ b/src/main/java/net/minecraft/world/level/block/Block.java -@@ -438,7 +438,17 @@ public class Block extends BlockBehaviour implements ItemLike { +@@ -437,7 +437,17 @@ public class Block extends BlockBehaviour implements ItemLike { } // Paper - fix drops not preventing stats/food exhaustion } diff --git a/patches/server/0206-Shift-right-click-to-use-exp-for-mending.patch b/patches/server/0206-Shift-right-click-to-use-exp-for-mending.patch index 6cbc90110..692122954 100644 --- a/patches/server/0206-Shift-right-click-to-use-exp-for-mending.patch +++ b/patches/server/0206-Shift-right-click-to-use-exp-for-mending.patch @@ -36,10 +36,10 @@ index fe734df8b4521101c3e55c042957a531b3bdf945..7c06b284a6cc74c0b31f8921706c7796 + // Purpur end } diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 435ab19d1fad30cd75aa705861760674b09ea0ac..4db8975e8cb786042239c19f81c9b7f4637d010d 100644 +index 65cac2fa564071f5dc3d67b320825b24f6976626..8a0994bdc31b2a328a18a1d62cb99d1708976f65 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -1999,6 +1999,7 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl +@@ -2071,6 +2071,7 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl boolean cancelled; if (movingobjectposition == null || movingobjectposition.getType() != HitResult.Type.BLOCK) { diff --git a/patches/server/0216-Persistent-BlockEntity-Lore-and-DisplayName.patch b/patches/server/0216-Persistent-BlockEntity-Lore-and-DisplayName.patch index c15391cc6..536928504 100644 --- a/patches/server/0216-Persistent-BlockEntity-Lore-and-DisplayName.patch +++ b/patches/server/0216-Persistent-BlockEntity-Lore-and-DisplayName.patch @@ -29,10 +29,10 @@ index 2649188930653610b8aaaeb18797c80879cd572a..7572c289758001c7417a192f0e6e994f @Nullable diff --git a/src/main/java/net/minecraft/world/level/block/Block.java b/src/main/java/net/minecraft/world/level/block/Block.java -index 57595a781a3cbdd8575c4af36328684ce7fc28d9..0f677573083ac806cfc105321b39edabb11e5d22 100644 +index 5dd4ccde6c4c421f697f629adb1adfadce7b8a42..6673133b93677d9329bab814ee64e37de3578dde 100644 --- a/src/main/java/net/minecraft/world/level/block/Block.java +++ b/src/main/java/net/minecraft/world/level/block/Block.java -@@ -312,7 +312,7 @@ public class Block extends BlockBehaviour implements ItemLike { +@@ -311,7 +311,7 @@ public class Block extends BlockBehaviour implements ItemLike { public static void dropResources(BlockState state, LevelAccessor world, BlockPos pos, @Nullable BlockEntity blockEntity) { if (world instanceof ServerLevel) { Block.getDrops(state, (ServerLevel) world, pos, blockEntity).forEach((itemstack) -> { @@ -41,7 +41,7 @@ index 57595a781a3cbdd8575c4af36328684ce7fc28d9..0f677573083ac806cfc105321b39edab }); state.spawnAfterBreak((ServerLevel) world, pos, ItemStack.EMPTY, true); } -@@ -331,7 +331,7 @@ public class Block extends BlockBehaviour implements ItemLike { +@@ -330,7 +330,7 @@ public class Block extends BlockBehaviour implements ItemLike { event.setExpToDrop(block.getExpDrop(state, serverLevel, pos, net.minecraft.world.item.ItemStack.EMPTY, true)); // Paper - Properly handle xp dropping event.callEvent(); for (org.bukkit.inventory.ItemStack drop : event.getDrops()) { @@ -50,7 +50,7 @@ index 57595a781a3cbdd8575c4af36328684ce7fc28d9..0f677573083ac806cfc105321b39edab } state.spawnAfterBreak(serverLevel, pos, ItemStack.EMPTY, false); // Paper - Properly handle xp dropping block.popExperience(serverLevel, pos, event.getExpToDrop()); // Paper - Properly handle xp dropping -@@ -348,13 +348,32 @@ public class Block extends BlockBehaviour implements ItemLike { +@@ -347,13 +347,32 @@ public class Block extends BlockBehaviour implements ItemLike { // Paper end - Properly handle xp dropping if (world instanceof ServerLevel) { Block.getDrops(state, (ServerLevel) world, pos, blockEntity, entity, tool).forEach((itemstack1) -> { diff --git a/patches/server/0253-Remove-Timings.patch b/patches/server/0253-Remove-Timings.patch index 122df5820..1f463b6d8 100644 --- a/patches/server/0253-Remove-Timings.patch +++ b/patches/server/0253-Remove-Timings.patch @@ -510,10 +510,10 @@ index 514620a64495023fa917c14c971cd112fd64b33a..7ece40ea9ad3ba74b93250f72b42fc62 } diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java -index 15b71ef1f52467eec0020fb837f78d9f2cfd8556..1b1008ffd544dcddc31238e10c06df0d7aa68793 100644 +index b1adc1291a03489722e3eea1b20233052b9aa0fd..1babe6756b904fd2e5b2d62f6adfa153e3b772f1 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -1228,7 +1228,7 @@ public abstract class PlayerList { +@@ -1231,7 +1231,7 @@ public abstract class PlayerList { public void saveAll(int interval) { io.papermc.paper.util.MCUtil.ensureMain("Save Players" , () -> { // Paper - Ensure main @@ -522,7 +522,7 @@ index 15b71ef1f52467eec0020fb837f78d9f2cfd8556..1b1008ffd544dcddc31238e10c06df0d int numSaved = 0; long now = MinecraftServer.currentTick; for (int i = 0; i < this.players.size(); ++i) { -@@ -1239,7 +1239,7 @@ public abstract class PlayerList { +@@ -1242,7 +1242,7 @@ public abstract class PlayerList { } // Paper end - Incremental chunk and player saving } diff --git a/patches/server/0255-Add-more-logger-output-for-invalid-movement-kicks.patch b/patches/server/0255-Add-more-logger-output-for-invalid-movement-kicks.patch index 41a826f27..16068b9b1 100644 --- a/patches/server/0255-Add-more-logger-output-for-invalid-movement-kicks.patch +++ b/patches/server/0255-Add-more-logger-output-for-invalid-movement-kicks.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Add more logger output for invalid movement kicks diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 4db8975e8cb786042239c19f81c9b7f4637d010d..d7356a57de9c706de78c146ba93310c4dd30f41e 100644 +index 8a0994bdc31b2a328a18a1d62cb99d1708976f65..b29b9d95a191205f612fe798b4617081bf2fde01 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -721,6 +721,7 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl +@@ -755,6 +755,7 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl PacketUtils.ensureRunningOnSameThread(packet, this, this.player.serverLevel()); if (packet.getId() == this.awaitingTeleport) { if (this.awaitingPositionFromClient == null) { @@ -16,7 +16,7 @@ index 4db8975e8cb786042239c19f81c9b7f4637d010d..d7356a57de9c706de78c146ba93310c4 this.disconnect((Component) Component.translatable("multiplayer.disconnect.invalid_player_movement"), org.bukkit.event.player.PlayerKickEvent.Cause.INVALID_PLAYER_MOVEMENT); // Paper - kick event cause return; } -@@ -1322,7 +1323,15 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl +@@ -1356,7 +1357,15 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl @Override public void handleMovePlayer(ServerboundMovePlayerPacket packet) { PacketUtils.ensureRunningOnSameThread(packet, this, this.player.serverLevel()); diff --git a/patches/server/0264-Configurable-block-fall-damage-modifiers.patch b/patches/server/0264-Configurable-block-fall-damage-modifiers.patch index 8ebc8ba41..61fc36214 100644 --- a/patches/server/0264-Configurable-block-fall-damage-modifiers.patch +++ b/patches/server/0264-Configurable-block-fall-damage-modifiers.patch @@ -18,7 +18,7 @@ index b59dd6b512021c335f3c21999958e2ea081daf69..17c994a39a1b99cc7727e328ce7493d5 @Override diff --git a/src/main/java/net/minecraft/world/level/block/Block.java b/src/main/java/net/minecraft/world/level/block/Block.java -index 0f677573083ac806cfc105321b39edabb11e5d22..58c6002bc9d326477ebacfece4bb2bc50389fe87 100644 +index 6673133b93677d9329bab814ee64e37de3578dde..4ff7e3693305069e7fad185802a3b0481ab70a4a 100644 --- a/src/main/java/net/minecraft/world/level/block/Block.java +++ b/src/main/java/net/minecraft/world/level/block/Block.java @@ -88,6 +88,10 @@ public class Block extends BlockBehaviour implements ItemLike { @@ -32,7 +32,7 @@ index 0f677573083ac806cfc105321b39edabb11e5d22..58c6002bc9d326477ebacfece4bb2bc5 // Paper start public final boolean isDestroyable() { return io.papermc.paper.configuration.GlobalConfiguration.get().unsupportedSettings.allowPermanentBlockBreakExploits || -@@ -486,7 +490,7 @@ public class Block extends BlockBehaviour implements ItemLike { +@@ -485,7 +489,7 @@ public class Block extends BlockBehaviour implements ItemLike { } public void fallOn(Level world, BlockState state, BlockPos pos, Entity entity, float fallDistance) {