diff --git a/patches/unapplied/server/0749-Fire-CauldronLevelChange-on-initial-fill.patch b/patches/server/0722-Fire-CauldronLevelChange-on-initial-fill.patch similarity index 71% rename from patches/unapplied/server/0749-Fire-CauldronLevelChange-on-initial-fill.patch rename to patches/server/0722-Fire-CauldronLevelChange-on-initial-fill.patch index 0ad967e4e4..4f5e70f836 100644 --- a/patches/unapplied/server/0749-Fire-CauldronLevelChange-on-initial-fill.patch +++ b/patches/server/0722-Fire-CauldronLevelChange-on-initial-fill.patch @@ -7,71 +7,70 @@ Also don't fire level events or game events if stalactite drip is cancelled diff --git a/src/main/java/net/minecraft/core/cauldron/CauldronInteraction.java b/src/main/java/net/minecraft/core/cauldron/CauldronInteraction.java -index 4c9334dde0734a3550a810845cee53f474e9c96b..50fd3e43b4971cd72efd1f609f0cdc4b0f57bed4 100644 +index 6de21246693afd20fce867e6c2480f912e1b639a..50e9643c88252d6afbcea1763cc3f7063f0d35b4 100644 --- a/src/main/java/net/minecraft/core/cauldron/CauldronInteraction.java +++ b/src/main/java/net/minecraft/core/cauldron/CauldronInteraction.java -@@ -80,7 +80,7 @@ public interface CauldronInteraction { - } else { +@@ -81,7 +81,7 @@ public interface CauldronInteraction { + if (potioncontents != null && potioncontents.is(Potions.WATER)) { if (!world.isClientSide) { // CraftBukkit start - if (!LayeredCauldronBlock.changeLevel(iblockdata, world, blockposition, Blocks.WATER_CAULDRON.defaultBlockState(), entityhuman, CauldronLevelChangeEvent.ChangeReason.BOTTLE_EMPTY)) { + if (!LayeredCauldronBlock.changeLevel(iblockdata, world, blockposition, Blocks.WATER_CAULDRON.defaultBlockState(), entityhuman, CauldronLevelChangeEvent.ChangeReason.BOTTLE_EMPTY, false)) { // Paper - Call CauldronLevelChangeEvent - return InteractionResult.SUCCESS; + return ItemInteractionResult.SUCCESS; } // CraftBukkit end -@@ -128,7 +128,7 @@ public interface CauldronInteraction { - if ((Integer) iblockdata.getValue(LayeredCauldronBlock.LEVEL) != 3 && PotionUtils.getPotion(itemstack) == Potions.WATER) { - if (!world.isClientSide) { - // CraftBukkit start -- if (!LayeredCauldronBlock.changeLevel(iblockdata, world, blockposition, iblockdata.cycle(LayeredCauldronBlock.LEVEL), entityhuman, CauldronLevelChangeEvent.ChangeReason.BOTTLE_EMPTY)) { -+ if (!LayeredCauldronBlock.changeLevel(iblockdata, world, blockposition, iblockdata.cycle(LayeredCauldronBlock.LEVEL), entityhuman, CauldronLevelChangeEvent.ChangeReason.BOTTLE_EMPTY, false)) { // Paper - Call CauldronLevelChangeEvent - return InteractionResult.SUCCESS; - } - // CraftBukkit end -@@ -212,7 +212,7 @@ public interface CauldronInteraction { +@@ -136,7 +136,7 @@ public interface CauldronInteraction { + if (potioncontents != null && potioncontents.is(Potions.WATER)) { + if (!world.isClientSide) { + // CraftBukkit start +- if (!LayeredCauldronBlock.changeLevel(iblockdata, world, blockposition, iblockdata.cycle(LayeredCauldronBlock.LEVEL), entityhuman, CauldronLevelChangeEvent.ChangeReason.BOTTLE_EMPTY)) { ++ if (!LayeredCauldronBlock.changeLevel(iblockdata, world, blockposition, iblockdata.cycle(LayeredCauldronBlock.LEVEL), entityhuman, CauldronLevelChangeEvent.ChangeReason.BOTTLE_EMPTY, false)) { // Paper - Call CauldronLevelChangeEvent + return ItemInteractionResult.SUCCESS; + } + // CraftBukkit end +@@ -222,7 +222,7 @@ public interface CauldronInteraction { } else { if (!world.isClientSide) { // CraftBukkit start - if (!LayeredCauldronBlock.changeLevel(state, world, pos, Blocks.CAULDRON.defaultBlockState(), player, CauldronLevelChangeEvent.ChangeReason.BUCKET_FILL)) { + if (!LayeredCauldronBlock.changeLevel(state, world, pos, Blocks.CAULDRON.defaultBlockState(), player, CauldronLevelChangeEvent.ChangeReason.BUCKET_FILL, false)) { // Paper - Call CauldronLevelChangeEvent - return InteractionResult.SUCCESS; + return ItemInteractionResult.SUCCESS; } // CraftBukkit end -@@ -233,7 +233,7 @@ public interface CauldronInteraction { - static InteractionResult emptyBucket(Level world, BlockPos pos, Player player, InteractionHand hand, ItemStack stack, BlockState state, SoundEvent soundEvent) { +@@ -243,7 +243,7 @@ public interface CauldronInteraction { + static ItemInteractionResult emptyBucket(Level world, BlockPos pos, Player player, InteractionHand hand, ItemStack stack, BlockState state, SoundEvent soundEvent) { if (!world.isClientSide) { // CraftBukkit start - if (!LayeredCauldronBlock.changeLevel(state, world, pos, state, player, CauldronLevelChangeEvent.ChangeReason.BUCKET_EMPTY)) { + if (!LayeredCauldronBlock.changeLevel(state, world, pos, state, player, CauldronLevelChangeEvent.ChangeReason.BUCKET_EMPTY, false)) { // Paper - Call CauldronLevelChangeEvent - return InteractionResult.SUCCESS; + return ItemInteractionResult.SUCCESS; } // CraftBukkit end diff --git a/src/main/java/net/minecraft/world/level/block/CauldronBlock.java b/src/main/java/net/minecraft/world/level/block/CauldronBlock.java -index 588b3e911d9b22dad2928ea9e32e8a8a3a8e9b96..47b6b83842201620bd6620f5acf11bb14334e35d 100644 +index 8d5ad9848d9652b4fd7179c425c47a683ee169ef..c9968934f4ecaa8d81e545f279b3001c7b1ce545 100644 --- a/src/main/java/net/minecraft/world/level/block/CauldronBlock.java +++ b/src/main/java/net/minecraft/world/level/block/CauldronBlock.java -@@ -43,10 +43,18 @@ public class CauldronBlock extends AbstractCauldronBlock { +@@ -44,9 +44,19 @@ public class CauldronBlock extends AbstractCauldronBlock { public void handlePrecipitation(BlockState state, Level world, BlockPos pos, Biome.Precipitation precipitation) { if (CauldronBlock.shouldHandlePrecipitation(world, precipitation)) { if (precipitation == Biome.Precipitation.RAIN) { -- world.setBlockAndUpdate(pos, Blocks.WATER_CAULDRON.defaultBlockState()); + // Paper start - Call CauldronLevelChangeEvent + if (!LayeredCauldronBlock.changeLevel(state, world, pos, Blocks.WATER_CAULDRON.defaultBlockState(), null, CauldronLevelChangeEvent.ChangeReason.NATURAL_FILL, false)) { // avoid duplicate game event + return; + } + // Paper end - Call CauldronLevelChangeEvent - world.gameEvent((Entity) null, GameEvent.BLOCK_CHANGE, pos); + world.setBlockAndUpdate(pos, Blocks.WATER_CAULDRON.defaultBlockState()); + world.gameEvent((Entity) null, (Holder) GameEvent.BLOCK_CHANGE, pos); } else if (precipitation == Biome.Precipitation.SNOW) { -- world.setBlockAndUpdate(pos, Blocks.POWDER_SNOW_CAULDRON.defaultBlockState()); + // Paper start - Call CauldronLevelChangeEvent + if (!LayeredCauldronBlock.changeLevel(state, world, pos, Blocks.POWDER_SNOW_CAULDRON.defaultBlockState(), null, CauldronLevelChangeEvent.ChangeReason.NATURAL_FILL, false)) { // avoid duplicate game event + return; + } + // Paper end - Call CauldronLevelChangeEvent - world.gameEvent((Entity) null, GameEvent.BLOCK_CHANGE, pos); + world.setBlockAndUpdate(pos, Blocks.POWDER_SNOW_CAULDRON.defaultBlockState()); + world.gameEvent((Entity) null, (Holder) GameEvent.BLOCK_CHANGE, pos); } - -@@ -64,11 +72,19 @@ public class CauldronBlock extends AbstractCauldronBlock { +@@ -65,11 +75,19 @@ public class CauldronBlock extends AbstractCauldronBlock { if (fluid == Fluids.WATER) { iblockdata1 = Blocks.WATER_CAULDRON.defaultBlockState(); @@ -94,10 +93,10 @@ index 588b3e911d9b22dad2928ea9e32e8a8a3a8e9b96..47b6b83842201620bd6620f5acf11bb1 } diff --git a/src/main/java/net/minecraft/world/level/block/LayeredCauldronBlock.java b/src/main/java/net/minecraft/world/level/block/LayeredCauldronBlock.java -index 18ca086e28f4295cb9303919222d7c8ae0ca5d9a..542bc6be48d5c53eee988156e7aa6ecfccb51069 100644 +index 7c67efa6e344870b764eb39d5508190349e2e911..b222ac8e5b966c515be2aca86083f5640853cd29 100644 --- a/src/main/java/net/minecraft/world/level/block/LayeredCauldronBlock.java +++ b/src/main/java/net/minecraft/world/level/block/LayeredCauldronBlock.java -@@ -101,7 +101,13 @@ public class LayeredCauldronBlock extends AbstractCauldronBlock { +@@ -102,7 +102,13 @@ public class LayeredCauldronBlock extends AbstractCauldronBlock { } // CraftBukkit start @@ -112,12 +111,12 @@ index 18ca086e28f4295cb9303919222d7c8ae0ca5d9a..542bc6be48d5c53eee988156e7aa6ecf CraftBlockState newState = CraftBlockStates.getBlockState(world, blockposition); newState.setData(newBlock); -@@ -114,7 +120,7 @@ public class LayeredCauldronBlock extends AbstractCauldronBlock { +@@ -115,7 +121,7 @@ public class LayeredCauldronBlock extends AbstractCauldronBlock { return false; } newState.update(true); -- world.gameEvent(GameEvent.BLOCK_CHANGE, blockposition, GameEvent.Context.of(newBlock)); -+ if (sendGameEvent) world.gameEvent(GameEvent.BLOCK_CHANGE, blockposition, GameEvent.Context.of(newBlock)); // Paper - Call CauldronLevelChangeEvent +- world.gameEvent((Holder) GameEvent.BLOCK_CHANGE, blockposition, GameEvent.Context.of(newBlock)); ++ if (sendGameEvent) world.gameEvent((Holder) GameEvent.BLOCK_CHANGE, blockposition, GameEvent.Context.of(newBlock)); // Paper - Call CauldronLevelChangeEvent return true; } // CraftBukkit end diff --git a/patches/unapplied/server/0750-fix-powder-snow-cauldrons-not-turning-to-water.patch b/patches/server/0723-fix-powder-snow-cauldrons-not-turning-to-water.patch similarity index 90% rename from patches/unapplied/server/0750-fix-powder-snow-cauldrons-not-turning-to-water.patch rename to patches/server/0723-fix-powder-snow-cauldrons-not-turning-to-water.patch index 1d388d0504..f277b93aa1 100644 --- a/patches/unapplied/server/0750-fix-powder-snow-cauldrons-not-turning-to-water.patch +++ b/patches/server/0723-fix-powder-snow-cauldrons-not-turning-to-water.patch @@ -7,10 +7,10 @@ Powder snow cauldrons should turn to water when extinguishing an entity diff --git a/src/main/java/net/minecraft/world/level/block/LayeredCauldronBlock.java b/src/main/java/net/minecraft/world/level/block/LayeredCauldronBlock.java -index 542bc6be48d5c53eee988156e7aa6ecfccb51069..42c1e3dfec23d6a7d832bf73d47ecae1212ec2c9 100644 +index b222ac8e5b966c515be2aca86083f5640853cd29..fa5366961861370c2366e6f0ff026a6d65128316 100644 --- a/src/main/java/net/minecraft/world/level/block/LayeredCauldronBlock.java +++ b/src/main/java/net/minecraft/world/level/block/LayeredCauldronBlock.java -@@ -69,7 +69,7 @@ public class LayeredCauldronBlock extends AbstractCauldronBlock { +@@ -70,7 +70,7 @@ public class LayeredCauldronBlock extends AbstractCauldronBlock { if (!world.isClientSide && entity.isOnFire() && this.isEntityInsideContent(state, pos, entity)) { // CraftBukkit start if (entity.mayInteract(world, pos)) { @@ -19,7 +19,7 @@ index 542bc6be48d5c53eee988156e7aa6ecfccb51069..42c1e3dfec23d6a7d832bf73d47ecae1 return; } } -@@ -79,6 +79,7 @@ public class LayeredCauldronBlock extends AbstractCauldronBlock { +@@ -80,6 +80,7 @@ public class LayeredCauldronBlock extends AbstractCauldronBlock { } @@ -27,7 +27,7 @@ index 542bc6be48d5c53eee988156e7aa6ecfccb51069..42c1e3dfec23d6a7d832bf73d47ecae1 private void handleEntityOnFireInside(BlockState state, Level world, BlockPos pos) { if (this.precipitationType == Biome.Precipitation.SNOW) { LayeredCauldronBlock.lowerFillLevel((BlockState) Blocks.WATER_CAULDRON.defaultBlockState().setValue(LayeredCauldronBlock.LEVEL, (Integer) state.getValue(LayeredCauldronBlock.LEVEL)), world, pos); -@@ -87,6 +88,15 @@ public class LayeredCauldronBlock extends AbstractCauldronBlock { +@@ -88,6 +89,15 @@ public class LayeredCauldronBlock extends AbstractCauldronBlock { } } diff --git a/patches/unapplied/server/0751-Add-PlayerStopUsingItemEvent.patch b/patches/server/0724-Add-PlayerStopUsingItemEvent.patch similarity index 85% rename from patches/unapplied/server/0751-Add-PlayerStopUsingItemEvent.patch rename to patches/server/0724-Add-PlayerStopUsingItemEvent.patch index c78c171d1e..f8544cd79c 100644 --- a/patches/unapplied/server/0751-Add-PlayerStopUsingItemEvent.patch +++ b/patches/server/0724-Add-PlayerStopUsingItemEvent.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Add PlayerStopUsingItemEvent diff --git a/src/main/java/net/minecraft/world/entity/LivingEntity.java b/src/main/java/net/minecraft/world/entity/LivingEntity.java -index 5de5ca787905d9e0133e5f75280748526c568203..2b7325d3bcea2175ec22a45101f5bbaf29c2231a 100644 +index 7f8e82a1d5fa1ca665a66d2fb1342163f7c7a733..f3ca6f6c7a8f2dc51e263ee879412bf2806b0946 100644 --- a/src/main/java/net/minecraft/world/entity/LivingEntity.java +++ b/src/main/java/net/minecraft/world/entity/LivingEntity.java -@@ -4045,6 +4045,7 @@ public abstract class LivingEntity extends Entity implements Attackable { +@@ -4027,6 +4027,7 @@ public abstract class LivingEntity extends Entity implements Attackable { public void releaseUsingItem() { if (!this.useItem.isEmpty()) { diff --git a/patches/unapplied/server/0752-Don-t-tick-markers.patch b/patches/server/0725-Don-t-tick-markers.patch similarity index 93% rename from patches/unapplied/server/0752-Don-t-tick-markers.patch rename to patches/server/0725-Don-t-tick-markers.patch index f920e6b436..9b56cbe7ff 100644 --- a/patches/unapplied/server/0752-Don-t-tick-markers.patch +++ b/patches/server/0725-Don-t-tick-markers.patch @@ -23,10 +23,10 @@ index ff99336e0b8131ae161cfa5c4fc83c6905e3dbc8..5e5a018433414af76eaa1e781f61612d } }); diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java -index 03a9f82ac2af6cb64081c2bb758cb02a7ffd5b89..024f32155feb31365c8233f94b1e15ed85e929fb 100644 +index d4dc2e3a89b76009bb1ce2c3b03515fcf308efa0..8aa6044a60e0148d2841e7618889fbefdc8b8f60 100644 --- a/src/main/java/net/minecraft/server/level/ServerLevel.java +++ b/src/main/java/net/minecraft/server/level/ServerLevel.java -@@ -2235,6 +2235,7 @@ public class ServerLevel extends Level implements WorldGenLevel { +@@ -2192,6 +2192,7 @@ public class ServerLevel extends Level implements WorldGenLevel { } public void onTickingStart(Entity entity) { diff --git a/patches/unapplied/server/0753-Expand-FallingBlock-API.patch b/patches/server/0726-Expand-FallingBlock-API.patch similarity index 94% rename from patches/unapplied/server/0753-Expand-FallingBlock-API.patch rename to patches/server/0726-Expand-FallingBlock-API.patch index 3f57a2d718..861e7e87f2 100644 --- a/patches/unapplied/server/0753-Expand-FallingBlock-API.patch +++ b/patches/server/0726-Expand-FallingBlock-API.patch @@ -13,7 +13,7 @@ public net.minecraft.world.entity.item.FallingBlockEntity blockState Co-authored-by: Lukas Planz diff --git a/src/main/java/net/minecraft/world/entity/item/FallingBlockEntity.java b/src/main/java/net/minecraft/world/entity/item/FallingBlockEntity.java -index c0477f913867c67809978a4f240303151d81e6ea..a52c2fc38fd97ffa1684270443646d605ec35830 100644 +index cc00bf81de902cfc587bcf6f18e861fd4339c91e..d504d10fbe45dfe3f2f3d08d2473df6cd18f6dcf 100644 --- a/src/main/java/net/minecraft/world/entity/item/FallingBlockEntity.java +++ b/src/main/java/net/minecraft/world/entity/item/FallingBlockEntity.java @@ -67,6 +67,7 @@ public class FallingBlockEntity extends Entity { @@ -24,7 +24,7 @@ index c0477f913867c67809978a4f240303151d81e6ea..a52c2fc38fd97ffa1684270443646d60 public FallingBlockEntity(EntityType type, Level world) { super(type, world); -@@ -169,7 +170,7 @@ public class FallingBlockEntity extends Entity { +@@ -171,7 +172,7 @@ public class FallingBlockEntity extends Entity { } if (!this.onGround() && !flag1) { @@ -33,7 +33,7 @@ index c0477f913867c67809978a4f240303151d81e6ea..a52c2fc38fd97ffa1684270443646d60 if (this.dropItem && this.level().getGameRules().getBoolean(GameRules.RULE_DOENTITYDROPS)) { this.spawnAtLocation((ItemLike) block); } -@@ -315,6 +316,7 @@ public class FallingBlockEntity extends Entity { +@@ -317,6 +318,7 @@ public class FallingBlockEntity extends Entity { } nbt.putBoolean("CancelDrop", this.cancelDrop); @@ -41,7 +41,7 @@ index c0477f913867c67809978a4f240303151d81e6ea..a52c2fc38fd97ffa1684270443646d60 } @Override -@@ -342,6 +344,11 @@ public class FallingBlockEntity extends Entity { +@@ -344,6 +346,11 @@ public class FallingBlockEntity extends Entity { this.blockState = Blocks.SAND.defaultBlockState(); } diff --git a/patches/unapplied/server/0754-Add-support-for-Proxy-Protocol.patch b/patches/server/0727-Add-support-for-Proxy-Protocol.patch similarity index 91% rename from patches/unapplied/server/0754-Add-support-for-Proxy-Protocol.patch rename to patches/server/0727-Add-support-for-Proxy-Protocol.patch index 1c60d69833..4d1db35776 100644 --- a/patches/unapplied/server/0754-Add-support-for-Proxy-Protocol.patch +++ b/patches/server/0727-Add-support-for-Proxy-Protocol.patch @@ -5,22 +5,22 @@ Subject: [PATCH] Add support for Proxy Protocol diff --git a/build.gradle.kts b/build.gradle.kts -index d16c0311142e44ec1048818221796c09ab7a90d8..f9056ee057a22a11288405cd42cd0ba4c9d120c3 100644 +index d104cf1064630698035025acbfbbf1f5e3da142a..4dd185f68ff99f598d9a6557d8bec2d254af052f 100644 --- a/build.gradle.kts +++ b/build.gradle.kts -@@ -30,6 +30,7 @@ dependencies { +@@ -31,6 +31,7 @@ dependencies { log4jPlugins.annotationProcessorConfigurationName("org.apache.logging.log4j:log4j-core:2.19.0") // Paper - Needed to generate meta for our Log4j plugins runtimeOnly(log4jPlugins.output) alsoShade(log4jPlugins.output) + implementation("io.netty:netty-codec-haproxy:4.1.97.Final") // Paper - Add support for proxy protocol // Paper end - implementation("org.apache.logging.log4j:log4j-iostreams:2.19.0") // Paper - remove exclusion + implementation("org.apache.logging.log4j:log4j-iostreams:2.22.1") // Paper - remove exclusion implementation("org.ow2.asm:asm-commons:9.7") diff --git a/src/main/java/net/minecraft/server/network/ServerConnectionListener.java b/src/main/java/net/minecraft/server/network/ServerConnectionListener.java -index 87abd6274f9da9367094bad0c28acfa47e01c50e..4f330a44c77a7ec3237a86fda04921a8c4a1c00f 100644 +index c63c194c44646e6bc1a59426552787011fc2ced5..96355e1da8feb6687ea0069dda4a82fcd7e25e8a 100644 --- a/src/main/java/net/minecraft/server/network/ServerConnectionListener.java +++ b/src/main/java/net/minecraft/server/network/ServerConnectionListener.java -@@ -121,6 +121,29 @@ public class ServerConnectionListener { +@@ -123,6 +123,29 @@ public class ServerConnectionListener { Connection object = j > 0 ? new RateKickingConnection(j) : new Connection(PacketFlow.SERVERBOUND); // CraftBukkit - decompile error //ServerConnectionListener.this.connections.add(object); // Paper diff --git a/patches/unapplied/server/0755-Fix-OfflinePlayer-getBedSpawnLocation.patch b/patches/server/0728-Fix-OfflinePlayer-getBedSpawnLocation.patch similarity index 96% rename from patches/unapplied/server/0755-Fix-OfflinePlayer-getBedSpawnLocation.patch rename to patches/server/0728-Fix-OfflinePlayer-getBedSpawnLocation.patch index e67e0fc286..61c9b7dd07 100644 --- a/patches/unapplied/server/0755-Fix-OfflinePlayer-getBedSpawnLocation.patch +++ b/patches/server/0728-Fix-OfflinePlayer-getBedSpawnLocation.patch @@ -8,7 +8,7 @@ instance of CraftOfflinePlayer the world was incorrect due to the logic for reading the NBT not being up-to-date. diff --git a/src/main/java/org/bukkit/craftbukkit/CraftOfflinePlayer.java b/src/main/java/org/bukkit/craftbukkit/CraftOfflinePlayer.java -index 0c1b5f625a351905e082b2c2a63bfd737101527e..ef2dfa30686bba3eb510bf95172174cc9972422e 100644 +index 411b280ac3e27e72091db813c0c9b69b62df6097..8caee0181f256e2ffd4e880274859eaf5f81ae96 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftOfflinePlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftOfflinePlayer.java @@ -37,6 +37,7 @@ import org.bukkit.profile.PlayerProfile; diff --git a/patches/unapplied/server/0756-Fix-FurnaceInventory-for-smokers-and-blast-furnaces.patch b/patches/server/0729-Fix-FurnaceInventory-for-smokers-and-blast-furnaces.patch similarity index 96% rename from patches/unapplied/server/0756-Fix-FurnaceInventory-for-smokers-and-blast-furnaces.patch rename to patches/server/0729-Fix-FurnaceInventory-for-smokers-and-blast-furnaces.patch index ef7517367b..1de015285e 100644 --- a/patches/unapplied/server/0756-Fix-FurnaceInventory-for-smokers-and-blast-furnaces.patch +++ b/patches/server/0729-Fix-FurnaceInventory-for-smokers-and-blast-furnaces.patch @@ -5,7 +5,7 @@ Subject: [PATCH] Fix FurnaceInventory for smokers and blast furnaces diff --git a/src/main/java/org/bukkit/craftbukkit/inventory/util/CraftTileInventoryConverter.java b/src/main/java/org/bukkit/craftbukkit/inventory/util/CraftTileInventoryConverter.java -index 8d3f71689087d687e6400e2ea9750a6fb3535bf1..149683821a248fbbd93d0417085f0cb0e86a1398 100644 +index 4a4996f8653edaf3182887821a8762caceab58ee..acb80ea99df024a30d2b8a8567d90379842b9dd3 100644 --- a/src/main/java/org/bukkit/craftbukkit/inventory/util/CraftTileInventoryConverter.java +++ b/src/main/java/org/bukkit/craftbukkit/inventory/util/CraftTileInventoryConverter.java @@ -65,7 +65,7 @@ public abstract class CraftTileInventoryConverter implements CraftInventoryCreat diff --git a/patches/unapplied/server/0758-Sanitize-sent-BlockEntity-NBT.patch b/patches/server/0730-Sanitize-sent-BlockEntity-NBT.patch similarity index 71% rename from patches/unapplied/server/0758-Sanitize-sent-BlockEntity-NBT.patch rename to patches/server/0730-Sanitize-sent-BlockEntity-NBT.patch index 72cdd70ba1..24ed948469 100644 --- a/patches/unapplied/server/0758-Sanitize-sent-BlockEntity-NBT.patch +++ b/patches/server/0730-Sanitize-sent-BlockEntity-NBT.patch @@ -5,24 +5,24 @@ Subject: [PATCH] Sanitize sent BlockEntity NBT diff --git a/src/main/java/net/minecraft/network/protocol/game/ClientboundBlockEntityDataPacket.java b/src/main/java/net/minecraft/network/protocol/game/ClientboundBlockEntityDataPacket.java -index d79284a790569141c2ac8178d6ecc20b17cdd0d3..3944852921335c78a04a9dc301882ab5b152b1ed 100644 +index df38a2ffb29394b27a11e5150fc99ecf38331796..3fbf48941d28ffb473c14d15aea334e83a34f961 100644 --- a/src/main/java/net/minecraft/network/protocol/game/ClientboundBlockEntityDataPacket.java +++ b/src/main/java/net/minecraft/network/protocol/game/ClientboundBlockEntityDataPacket.java -@@ -17,7 +17,7 @@ public class ClientboundBlockEntityDataPacket implements Packet nbtGetter) { -- return new ClientboundBlockEntityDataPacket(blockEntity.getBlockPos(), blockEntity.getType(), nbtGetter.apply(blockEntity)); -+ return new ClientboundBlockEntityDataPacket(blockEntity.getBlockPos(), blockEntity.getType(), blockEntity.sanitizeSentNbt(nbtGetter.apply(blockEntity))); // Paper - Sanitize sent data + public static ClientboundBlockEntityDataPacket create(BlockEntity blockEntity, BiFunction nbtGetter) { + RegistryAccess registryAccess = blockEntity.getLevel().registryAccess(); +- return new ClientboundBlockEntityDataPacket(blockEntity.getBlockPos(), blockEntity.getType(), nbtGetter.apply(blockEntity, registryAccess)); ++ return new ClientboundBlockEntityDataPacket(blockEntity.getBlockPos(), blockEntity.getType(), blockEntity.sanitizeSentNbt(nbtGetter.apply(blockEntity, registryAccess))); // Paper - Sanitize sent data } public static ClientboundBlockEntityDataPacket create(BlockEntity blockEntity) { diff --git a/src/main/java/net/minecraft/network/protocol/game/ClientboundLevelChunkPacketData.java b/src/main/java/net/minecraft/network/protocol/game/ClientboundLevelChunkPacketData.java -index a44a82d2d5ed4d675dc1a184d5b6b935fda575dd..03b6aa2e3bd871ae59e761866b53a10f72b3cdac 100644 +index ac900dfdc5c90e9e60d47efa734be8f0a5b20dca..ec1cb034d840633240f2b379b09f7d2f1c8971a5 100644 --- a/src/main/java/net/minecraft/network/protocol/game/ClientboundLevelChunkPacketData.java +++ b/src/main/java/net/minecraft/network/protocol/game/ClientboundLevelChunkPacketData.java -@@ -145,6 +145,7 @@ public class ClientboundLevelChunkPacketData { - CompoundTag compoundTag = blockEntity.getUpdateTag(); +@@ -154,6 +154,7 @@ public class ClientboundLevelChunkPacketData { + CompoundTag compoundTag = blockEntity.getUpdateTag(blockEntity.getLevel().registryAccess()); BlockPos blockPos = blockEntity.getBlockPos(); int i = SectionPos.sectionRelative(blockPos.getX()) << 4 | SectionPos.sectionRelative(blockPos.getZ()); + blockEntity.sanitizeSentNbt(compoundTag); // Paper - Sanitize sent data @@ -30,13 +30,13 @@ index a44a82d2d5ed4d675dc1a184d5b6b935fda575dd..03b6aa2e3bd871ae59e761866b53a10f } } diff --git a/src/main/java/net/minecraft/world/level/block/entity/BlockEntity.java b/src/main/java/net/minecraft/world/level/block/entity/BlockEntity.java -index 4893eaf93738da860014ddf3ad003334c9ebc9fa..20201430ee8f28245aa845acb172d0f5d80458ff 100644 +index df945a152747bea0452ec18c09d59598903aa91f..a7dfad2696e7145af1355a5db132af14d09a6f30 100644 --- a/src/main/java/net/minecraft/world/level/block/entity/BlockEntity.java +++ b/src/main/java/net/minecraft/world/level/block/entity/BlockEntity.java -@@ -253,4 +253,11 @@ public abstract class BlockEntity { - return null; +@@ -357,6 +357,14 @@ public abstract class BlockEntity { } // CraftBukkit end + + // Paper start - Sanitize sent data + public CompoundTag sanitizeSentNbt(CompoundTag tag) { + tag.remove("PublicBukkitValues"); @@ -44,4 +44,7 @@ index 4893eaf93738da860014ddf3ad003334c9ebc9fa..20201430ee8f28245aa845acb172d0f5 + return tag; + } + // Paper end - Sanitize sent data - } ++ + private static class ComponentHelper { + + public static final Codec COMPONENTS_CODEC = DataComponentMap.CODEC.optionalFieldOf("components", DataComponentMap.EMPTY).codec(); diff --git a/patches/server/0731-Disable-component-selector-resolving-in-books-by-def.patch b/patches/server/0731-Disable-component-selector-resolving-in-books-by-def.patch new file mode 100644 index 0000000000..796fcc7f2a --- /dev/null +++ b/patches/server/0731-Disable-component-selector-resolving-in-books-by-def.patch @@ -0,0 +1,19 @@ +From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 +From: Nassim Jahnke +Date: Thu, 2 Jun 2022 20:35:58 +0200 +Subject: [PATCH] Disable component selector resolving in books by default + + +diff --git a/src/main/java/net/minecraft/world/item/WrittenBookItem.java b/src/main/java/net/minecraft/world/item/WrittenBookItem.java +index 46383a9f8bd1075ea56847f5fd8437df0a5d4941..0a5182c52fe2fef05dabbeb5ed13487f9175efbe 100644 +--- a/src/main/java/net/minecraft/world/item/WrittenBookItem.java ++++ b/src/main/java/net/minecraft/world/item/WrittenBookItem.java +@@ -54,7 +54,7 @@ public class WrittenBookItem extends Item { + + public static boolean resolveBookComponents(ItemStack book, CommandSourceStack commandSource, @Nullable Player player) { + WrittenBookContent writtenBookContent = book.get(DataComponents.WRITTEN_BOOK_CONTENT); +- if (writtenBookContent != null && !writtenBookContent.resolved()) { ++ if (io.papermc.paper.configuration.GlobalConfiguration.get().itemValidation.resolveSelectorsInBooks && writtenBookContent != null && !writtenBookContent.resolved()) { // Paper - Disable component selector resolving in books by default + WrittenBookContent writtenBookContent2 = writtenBookContent.resolve(commandSource, player); + if (writtenBookContent2 != null) { + book.set(DataComponents.WRITTEN_BOOK_CONTENT, writtenBookContent2); diff --git a/patches/unapplied/server/0760-Prevent-entity-loading-causing-async-lookups.patch b/patches/server/0732-Prevent-entity-loading-causing-async-lookups.patch similarity index 69% rename from patches/unapplied/server/0760-Prevent-entity-loading-causing-async-lookups.patch rename to patches/server/0732-Prevent-entity-loading-causing-async-lookups.patch index d02ab57220..ee40703b74 100644 --- a/patches/unapplied/server/0760-Prevent-entity-loading-causing-async-lookups.patch +++ b/patches/server/0732-Prevent-entity-loading-causing-async-lookups.patch @@ -5,22 +5,22 @@ Subject: [PATCH] Prevent entity loading causing async lookups diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index f08908238cc9680310a2b37089b051bf6fdf5ee3..936ce33bffd93ed7210b6659c27c476e1db348bb 100644 +index 3bd13975934e8f61b41c4c08b73ead6e0f45ffac..bcf4e77ed17fa35d509b33568793a38278e2b718 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -727,6 +727,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, S +@@ -740,6 +740,7 @@ public abstract class Entity implements SyncedDataHolder, Nameable, EntityAccess public void baseTick() { this.level().getProfiler().push("entityBaseTick"); + if (firstTick && this instanceof net.minecraft.world.entity.NeutralMob neutralMob) neutralMob.tickInitialPersistentAnger(level); // Paper - Prevent entity loading causing async lookups - this.feetBlockState = null; + this.inBlockState = null; if (this.isPassenger() && this.getVehicle().isRemoved()) { this.stopRiding(); diff --git a/src/main/java/net/minecraft/world/entity/NeutralMob.java b/src/main/java/net/minecraft/world/entity/NeutralMob.java -index fa64c7baa7587f2cfe80b78ed83be011239618cf..47d5a0928f3c86d71f851738bfe7beedc98cfbb3 100644 +index 7bb01b28b07bf2b31897cc5ab1f44fc0387958bb..a0d0a3330bb43807172fde1ee21644380517b40c 100644 --- a/src/main/java/net/minecraft/world/entity/NeutralMob.java +++ b/src/main/java/net/minecraft/world/entity/NeutralMob.java -@@ -42,18 +42,11 @@ public interface NeutralMob { +@@ -42,24 +42,11 @@ public interface NeutralMob { UUID uuid = nbt.getUUID("AngryAt"); this.setPersistentAngerTarget(uuid); @@ -28,11 +28,17 @@ index fa64c7baa7587f2cfe80b78ed83be011239618cf..47d5a0928f3c86d71f851738bfe7beed - - if (entity != null) { - if (entity instanceof Mob) { -- this.setLastHurtByMob((Mob) entity); +- Mob entityinsentient = (Mob) entity; +- +- this.setTarget(entityinsentient); +- this.setLastHurtByMob(entityinsentient); - } - -- if (entity.getType() == EntityType.PLAYER) { -- this.setLastHurtByPlayer((Player) entity); +- if (entity instanceof Player) { +- Player entityhuman = (Player) entity; +- +- this.setTarget(entityhuman); +- this.setLastHurtByPlayer(entityhuman); - } - - } @@ -44,7 +50,7 @@ index fa64c7baa7587f2cfe80b78ed83be011239618cf..47d5a0928f3c86d71f851738bfe7beed } } } -@@ -127,4 +120,27 @@ public interface NeutralMob { +@@ -133,4 +120,28 @@ public interface NeutralMob { @Nullable LivingEntity getTarget(); @@ -60,14 +66,15 @@ index fa64c7baa7587f2cfe80b78ed83be011239618cf..47d5a0928f3c86d71f851738bfe7beed + Entity entity = ((ServerLevel) level).getEntity(target); + + if (entity != null) { -+ if (entity instanceof Mob) { -+ this.setLastHurtByMob((Mob) entity); ++ if (entity instanceof Mob mob) { ++ this.setTarget(mob); ++ this.setLastHurtByMob(mob); + } + -+ if (entity.getType() == EntityType.PLAYER) { -+ this.setLastHurtByPlayer((Player) entity); ++ if (entity instanceof Player player) { ++ this.setTarget(player); ++ this.setLastHurtByPlayer(player); + } -+ + } + } + // Paper end - Prevent entity loading causing async lookups diff --git a/patches/unapplied/server/0761-Throw-exception-on-world-create-while-being-ticked.patch b/patches/server/0733-Throw-exception-on-world-create-while-being-ticked.patch similarity index 87% rename from patches/unapplied/server/0761-Throw-exception-on-world-create-while-being-ticked.patch rename to patches/server/0733-Throw-exception-on-world-create-while-being-ticked.patch index 42eeeb0a1e..e241f9d3fc 100644 --- a/patches/unapplied/server/0761-Throw-exception-on-world-create-while-being-ticked.patch +++ b/patches/server/0733-Throw-exception-on-world-create-while-being-ticked.patch @@ -7,10 +7,10 @@ There are no plans to support creating worlds while worlds are being ticked themselvess. diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java -index 88821acddee03c30c2630d3d6c39cc93702ed35b..2a96d128dd42b937b16e25274b39fb66c3d9a097 100644 +index 79f7e0fb2f1aa6af441c6e09d2c443d7d4bb47ef..00457548d43e1d2143d1f6027593a1178f02564a 100644 --- a/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java -@@ -307,6 +307,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop S spin(Function serverFactory) { AtomicReference atomicreference = new AtomicReference(); -@@ -1501,7 +1502,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop 0; // Paper - BlockPhysicsEvent -@@ -1571,6 +1574,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop maindimensionkey = CraftDimensionUtil.getMainDimensionKey(origin); ResourceKey maindimensionkey1 = CraftDimensionUtil.getMainDimensionKey(this.level()); diff --git a/patches/unapplied/server/0765-Add-missing-important-BlockStateListPopulator-method.patch b/patches/server/0737-Add-missing-important-BlockStateListPopulator-method.patch similarity index 97% rename from patches/unapplied/server/0765-Add-missing-important-BlockStateListPopulator-method.patch rename to patches/server/0737-Add-missing-important-BlockStateListPopulator-method.patch index 5db34c9fe3..ecf565ebf6 100644 --- a/patches/unapplied/server/0765-Add-missing-important-BlockStateListPopulator-method.patch +++ b/patches/server/0737-Add-missing-important-BlockStateListPopulator-method.patch @@ -53,7 +53,7 @@ index ffe6881d93153838cd23f125980b832e6fd1d0eb..f5cbe9ae5802fa48e57092b1e5ca8a5f + // Paper end } diff --git a/src/main/java/org/bukkit/craftbukkit/util/DummyGeneratorAccess.java b/src/main/java/org/bukkit/craftbukkit/util/DummyGeneratorAccess.java -index 440660dfa70d57e94ae4eef1dce783aee5034f7e..67c9009b735429e887e706baf50a6023d572a46c 100644 +index 4705aed1dd98378c146bf9e346df1a17f719ad36..daf3c26fce7569761951bfd5594c6726d854a9ff 100644 --- a/src/main/java/org/bukkit/craftbukkit/util/DummyGeneratorAccess.java +++ b/src/main/java/org/bukkit/craftbukkit/util/DummyGeneratorAccess.java @@ -258,4 +258,14 @@ public class DummyGeneratorAccess implements WorldGenLevel { diff --git a/patches/unapplied/server/0766-Nameable-Banner-API.patch b/patches/server/0738-Nameable-Banner-API.patch similarity index 84% rename from patches/unapplied/server/0766-Nameable-Banner-API.patch rename to patches/server/0738-Nameable-Banner-API.patch index 351d3597e0..98b584a2de 100644 --- a/patches/unapplied/server/0766-Nameable-Banner-API.patch +++ b/patches/server/0738-Nameable-Banner-API.patch @@ -5,12 +5,12 @@ Subject: [PATCH] Nameable Banner API diff --git a/src/main/java/org/bukkit/craftbukkit/block/CraftBanner.java b/src/main/java/org/bukkit/craftbukkit/block/CraftBanner.java -index 2b7fcd30b6eb0ab60b44de31ad0e0b20033f45c5..0a80bd370dd41ffbfbbe6b0d88cd6fa8a47a5725 100644 +index 26ae3fe910964193c7fb22b8b644d5c0476f8d3d..0f8de5b87deeaf2aca043c017576f7c54c4a2f8e 100644 --- a/src/main/java/org/bukkit/craftbukkit/block/CraftBanner.java +++ b/src/main/java/org/bukkit/craftbukkit/block/CraftBanner.java -@@ -108,4 +108,26 @@ public class CraftBanner extends CraftBlockEntityState implem - public CraftBanner copy() { - return new CraftBanner(this); +@@ -110,4 +110,26 @@ public class CraftBanner extends CraftBlockEntityState implem + public CraftBanner copy(Location location) { + return new CraftBanner(this, location); } + + // Paper start diff --git a/patches/unapplied/server/0767-Don-t-broadcast-messages-to-command-blocks.patch b/patches/server/0739-Don-t-broadcast-messages-to-command-blocks.patch similarity index 85% rename from patches/unapplied/server/0767-Don-t-broadcast-messages-to-command-blocks.patch rename to patches/server/0739-Don-t-broadcast-messages-to-command-blocks.patch index fa6488648d..447d041847 100644 --- a/patches/unapplied/server/0767-Don-t-broadcast-messages-to-command-blocks.patch +++ b/patches/server/0739-Don-t-broadcast-messages-to-command-blocks.patch @@ -8,10 +8,10 @@ in command blocks, and if called asynchronously, would throw an error diff --git a/src/main/java/net/minecraft/world/level/BaseCommandBlock.java b/src/main/java/net/minecraft/world/level/BaseCommandBlock.java -index c56f5173fda6b38c2dcaea196217f2f5a7d7c641..524b0f1086c01888fe0b76e180c40915d16a1eb9 100644 +index e40069d937de5fd00741ae6873abeecc46b93732..552f7ab11dc09fa69034f009235cb22429a9ed11 100644 --- a/src/main/java/net/minecraft/world/level/BaseCommandBlock.java +++ b/src/main/java/net/minecraft/world/level/BaseCommandBlock.java -@@ -172,6 +172,7 @@ public abstract class BaseCommandBlock implements CommandSource { +@@ -177,6 +177,7 @@ public abstract class BaseCommandBlock implements CommandSource { @Override public void sendSystemMessage(Component message) { if (this.trackOutput) { @@ -20,10 +20,10 @@ index c56f5173fda6b38c2dcaea196217f2f5a7d7c641..524b0f1086c01888fe0b76e180c40915 Date date = new Date(); diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 562953515e21adc1cffadfe3ffb803c2d5059df0..e849e706660bf0b0ef1748dfee3ba75e5aff9863 100644 +index 199cc5ff46a41cc15467444b3900d171803666bd..d2a02210553363fb87882904abcfbe2ccd95fa78 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -1880,7 +1880,7 @@ public final class CraftServer implements Server { +@@ -1899,7 +1899,7 @@ public final class CraftServer implements Server { // Paper end Set recipients = new HashSet<>(); for (Permissible permissible : this.getPluginManager().getPermissionSubscriptions(permission)) { diff --git a/patches/unapplied/server/0768-Prevent-empty-items-from-being-added-to-world.patch b/patches/server/0740-Prevent-empty-items-from-being-added-to-world.patch similarity index 89% rename from patches/unapplied/server/0768-Prevent-empty-items-from-being-added-to-world.patch rename to patches/server/0740-Prevent-empty-items-from-being-added-to-world.patch index c3d0b8413a..91b2222e8b 100644 --- a/patches/unapplied/server/0768-Prevent-empty-items-from-being-added-to-world.patch +++ b/patches/server/0740-Prevent-empty-items-from-being-added-to-world.patch @@ -7,10 +7,10 @@ The previous solution caused a bunch of bandaid fixes inorder to resolve edge ca Just simply prevent them from being added to the world instead. diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java -index 024f32155feb31365c8233f94b1e15ed85e929fb..57f54e3399f9d2d7fecdae62858d20e50caf7afd 100644 +index 8aa6044a60e0148d2841e7618889fbefdc8b8f60..90500b6a5b3612c85a06660fe67e89351d4c0fd1 100644 --- a/src/main/java/net/minecraft/server/level/ServerLevel.java +++ b/src/main/java/net/minecraft/server/level/ServerLevel.java -@@ -1231,6 +1231,7 @@ public class ServerLevel extends Level implements WorldGenLevel { +@@ -1237,6 +1237,7 @@ public class ServerLevel extends Level implements WorldGenLevel { // WorldServer.LOGGER.warn("Tried to add entity {} but it was marked as removed already", EntityTypes.getKey(entity.getType())); // CraftBukkit return false; } else { diff --git a/patches/unapplied/server/0769-Fix-CCE-for-SplashPotion-and-LingeringPotion-spawnin.patch b/patches/server/0741-Fix-CCE-for-SplashPotion-and-LingeringPotion-spawnin.patch similarity index 88% rename from patches/unapplied/server/0769-Fix-CCE-for-SplashPotion-and-LingeringPotion-spawnin.patch rename to patches/server/0741-Fix-CCE-for-SplashPotion-and-LingeringPotion-spawnin.patch index 5816232b91..22edd6c689 100644 --- a/patches/unapplied/server/0769-Fix-CCE-for-SplashPotion-and-LingeringPotion-spawnin.patch +++ b/patches/server/0741-Fix-CCE-for-SplashPotion-and-LingeringPotion-spawnin.patch @@ -7,10 +7,10 @@ Remove in 1.19 along with the SplashPotion and LingeringPotion interfaces diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftThrownPotion.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftThrownPotion.java -index d5f1681a476c8fe2ae128a84910f4bf04063b75a..d3aeb4b614b2b17d9613aa3ffa34ebfc81666f79 100644 +index a5edfd484737b5f6af8aa1d9a1d31d7d2710f7da..ca87f0d59e6cf4b214b8322701ad0c16e49bad48 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftThrownPotion.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftThrownPotion.java -@@ -13,7 +13,7 @@ import org.bukkit.entity.ThrownPotion; +@@ -14,7 +14,7 @@ import org.bukkit.entity.ThrownPotion; import org.bukkit.inventory.ItemStack; import org.bukkit.potion.PotionEffect; diff --git a/patches/unapplied/server/0770-Add-Player-getFishHook.patch b/patches/server/0742-Add-Player-getFishHook.patch similarity index 86% rename from patches/unapplied/server/0770-Add-Player-getFishHook.patch rename to patches/server/0742-Add-Player-getFishHook.patch index d5f8b5dc18..d87fa21619 100644 --- a/patches/unapplied/server/0770-Add-Player-getFishHook.patch +++ b/patches/server/0742-Add-Player-getFishHook.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Add Player#getFishHook diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java -index b895b3972dc48ec91dba9d44546508badef73865..98ee3a7eff6cd1dd3fdbd7cc6a94deebcefbc565 100644 +index 6c500a2ccc050fc44076e443032b0ef9d87a7de8..79faf3c64891899bf5d6d119154aba02d4665b3b 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java -@@ -162,6 +162,15 @@ public class CraftHumanEntity extends CraftLivingEntity implements HumanEntity { +@@ -160,6 +160,15 @@ public class CraftHumanEntity extends CraftLivingEntity implements HumanEntity { return new Location(worldServer.getWorld(), bed.getX(), bed.getY(), bed.getZ()); } // Paper end diff --git a/patches/unapplied/server/0771-Do-not-sync-load-chunk-for-dynamic-game-event-listen.patch b/patches/server/0743-Do-not-sync-load-chunk-for-dynamic-game-event-listen.patch similarity index 94% rename from patches/unapplied/server/0771-Do-not-sync-load-chunk-for-dynamic-game-event-listen.patch rename to patches/server/0743-Do-not-sync-load-chunk-for-dynamic-game-event-listen.patch index b5557f95ef..32aaf6dc6e 100644 --- a/patches/unapplied/server/0771-Do-not-sync-load-chunk-for-dynamic-game-event-listen.patch +++ b/patches/server/0743-Do-not-sync-load-chunk-for-dynamic-game-event-listen.patch @@ -15,7 +15,7 @@ to account for the case where the chunk is _not_ currently loaded and then later loaded. diff --git a/src/main/java/net/minecraft/world/level/gameevent/DynamicGameEventListener.java b/src/main/java/net/minecraft/world/level/gameevent/DynamicGameEventListener.java -index 53eeb59257e3e943cbe7dc113674135077f0c20d..fc316f6c6db1d39bb24daa1d272e5128c71320dd 100644 +index af9437bddf69546a1a78eca7e858ac8d2e68ed0a..134b4ceec0ec5a2475881e739d6579fa5984c3dd 100644 --- a/src/main/java/net/minecraft/world/level/gameevent/DynamicGameEventListener.java +++ b/src/main/java/net/minecraft/world/level/gameevent/DynamicGameEventListener.java @@ -41,7 +41,7 @@ public class DynamicGameEventListener { diff --git a/patches/unapplied/server/0772-Add-various-missing-EntityDropItemEvent-calls.patch b/patches/server/0744-Add-various-missing-EntityDropItemEvent-calls.patch similarity index 84% rename from patches/unapplied/server/0772-Add-various-missing-EntityDropItemEvent-calls.patch rename to patches/server/0744-Add-various-missing-EntityDropItemEvent-calls.patch index d3b144009b..bafd157cd1 100644 --- a/patches/unapplied/server/0772-Add-various-missing-EntityDropItemEvent-calls.patch +++ b/patches/server/0744-Add-various-missing-EntityDropItemEvent-calls.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Add various missing EntityDropItemEvent calls diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index 936ce33bffd93ed7210b6659c27c476e1db348bb..319bb4d94f8221e20557c0e0805c581447e2ee57 100644 +index bcf4e77ed17fa35d509b33568793a38278e2b718..3f2293ae7b84c9ec8455f41121adbaf7dbd7da71 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -2491,6 +2491,14 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, S +@@ -2519,6 +2519,14 @@ public abstract class Entity implements SyncedDataHolder, Nameable, EntityAccess stack.setCount(0); // Paper - destroy this item - if this ever leaks due to game bugs, ensure it doesn't dupe entityitem.setDefaultPickUpDelay(); @@ -24,10 +24,10 @@ index 936ce33bffd93ed7210b6659c27c476e1db348bb..319bb4d94f8221e20557c0e0805c5814 EntityDropItemEvent event = new EntityDropItemEvent(this.getBukkitEntity(), (org.bukkit.entity.Item) entityitem.getBukkitEntity()); Bukkit.getPluginManager().callEvent(event); diff --git a/src/main/java/net/minecraft/world/entity/animal/Dolphin.java b/src/main/java/net/minecraft/world/entity/animal/Dolphin.java -index 1a37be6015fb5c11301850d455a4f3807076c9be..45646c69ea73936a8916756fde37dd3f39db0d04 100644 +index ff5d117e4740fe1762b5d1f547fc5cb89ab8515b..1b1cb0e4d54e52ebe794199e386c54c5d84b3719 100644 --- a/src/main/java/net/minecraft/world/entity/animal/Dolphin.java +++ b/src/main/java/net/minecraft/world/entity/animal/Dolphin.java -@@ -593,7 +593,7 @@ public class Dolphin extends WaterAnimal { +@@ -583,7 +583,7 @@ public class Dolphin extends WaterAnimal { float f2 = 0.02F * Dolphin.this.random.nextFloat(); entityitem.setDeltaMovement((double) (0.3F * -Mth.sin(Dolphin.this.getYRot() * 0.017453292F) * Mth.cos(Dolphin.this.getXRot() * 0.017453292F) + Mth.cos(f1) * f2), (double) (0.3F * Mth.sin(Dolphin.this.getXRot() * 0.017453292F) * 1.5F), (double) (0.3F * Mth.cos(Dolphin.this.getYRot() * 0.017453292F) * Mth.cos(Dolphin.this.getXRot() * 0.017453292F) + Mth.sin(f1) * f2)); @@ -37,10 +37,10 @@ index 1a37be6015fb5c11301850d455a4f3807076c9be..45646c69ea73936a8916756fde37dd3f } } diff --git a/src/main/java/net/minecraft/world/entity/animal/Fox.java b/src/main/java/net/minecraft/world/entity/animal/Fox.java -index 4ac32078cb074a78a2bb83307013b849f8d59f23..4c2e090a72dbd5bfb928e6ccbcedb1a25231d5b1 100644 +index 82ced9f42dced65322a55579bb764fb4dc7c1b66..1aa5485f2608000e4ac07350d1c537bc9bd92de4 100644 --- a/src/main/java/net/minecraft/world/entity/animal/Fox.java +++ b/src/main/java/net/minecraft/world/entity/animal/Fox.java -@@ -513,14 +513,14 @@ public class Fox extends Animal implements VariantHolder { +@@ -507,14 +507,14 @@ public class Fox extends Animal implements VariantHolder { entityitem.setPickUpDelay(40); entityitem.setThrower(this); this.playSound(SoundEvents.FOX_SPIT, 1.0F, 1.0F); @@ -58,10 +58,10 @@ index 4ac32078cb074a78a2bb83307013b849f8d59f23..4c2e090a72dbd5bfb928e6ccbcedb1a2 @Override diff --git a/src/main/java/net/minecraft/world/entity/animal/goat/Goat.java b/src/main/java/net/minecraft/world/entity/animal/goat/Goat.java -index ee1b2c1fec4b76a821e1d52fbb07e1f302b2efa1..110dd5418b0512a2f27f0c4d5a5f1812356a6a12 100644 +index 3b2cf9ca8447321d64ffdb4fdb9569d736d63dbb..923806900ef6248576e71260d40e9caf2c8943e8 100644 --- a/src/main/java/net/minecraft/world/entity/animal/goat/Goat.java +++ b/src/main/java/net/minecraft/world/entity/animal/goat/Goat.java -@@ -357,8 +357,7 @@ public class Goat extends Animal { +@@ -361,8 +361,7 @@ public class Goat extends Animal { double d2 = (double) Mth.randomBetween(this.random, -0.2F, 0.2F); ItemEntity entityitem = new ItemEntity(this.level(), vec3d.x(), vec3d.y(), vec3d.z(), itemstack, d0, d1, d2); @@ -72,10 +72,10 @@ index ee1b2c1fec4b76a821e1d52fbb07e1f302b2efa1..110dd5418b0512a2f27f0c4d5a5f1812 } diff --git a/src/main/java/net/minecraft/world/entity/animal/sniffer/Sniffer.java b/src/main/java/net/minecraft/world/entity/animal/sniffer/Sniffer.java -index 1d9913cbc7fd0c6e29278b02c38703b52af1245b..0e85e3ab58d848b119212fa7d2eb4f92d3efe29b 100644 +index 11236a1c1705600c2317f0ea4e3b712327352b40..a0c52ce65d4035d135b1536c7408a6867a553447 100644 --- a/src/main/java/net/minecraft/world/entity/animal/sniffer/Sniffer.java +++ b/src/main/java/net/minecraft/world/entity/animal/sniffer/Sniffer.java -@@ -352,8 +352,9 @@ public class Sniffer extends Animal { +@@ -350,8 +350,9 @@ public class Sniffer extends Animal { entityitem.setDefaultPickUpDelay(); this.finalizeSpawnChildFromBreeding(world, other, (AgeableMob) null); diff --git a/patches/unapplied/server/0773-Fix-Bee-flower-NPE.patch b/patches/server/0745-Fix-Bee-flower-NPE.patch similarity index 85% rename from patches/unapplied/server/0773-Fix-Bee-flower-NPE.patch rename to patches/server/0745-Fix-Bee-flower-NPE.patch index 21a3d68e76..13dcee533d 100644 --- a/patches/unapplied/server/0773-Fix-Bee-flower-NPE.patch +++ b/patches/server/0745-Fix-Bee-flower-NPE.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Fix Bee flower NPE diff --git a/src/main/java/net/minecraft/world/entity/animal/Bee.java b/src/main/java/net/minecraft/world/entity/animal/Bee.java -index 91ea960ba223bae42655c581b9b6c0981f333c9b..f9521a6e115f0c975a7885b024c99eae300b63bf 100644 +index d317b8500e8d2c280e52140440cf2b9cb61c3b28..0dfb8109fd8c022b079da00f6a0e3fc85b57bf7a 100644 --- a/src/main/java/net/minecraft/world/entity/animal/Bee.java +++ b/src/main/java/net/minecraft/world/entity/animal/Bee.java -@@ -810,7 +810,7 @@ public class Bee extends Animal implements NeutralMob, FlyingAnimal { +@@ -794,7 +794,7 @@ public class Bee extends Animal implements NeutralMob, FlyingAnimal { ++this.pollinatingTicks; if (this.pollinatingTicks > 600) { Bee.this.savedFlowerPos = null; diff --git a/patches/unapplied/server/0774-Fix-Spigot-Config-not-using-commands.spam-exclusions.patch b/patches/server/0746-Fix-Spigot-Config-not-using-commands.spam-exclusions.patch similarity index 87% rename from patches/unapplied/server/0774-Fix-Spigot-Config-not-using-commands.spam-exclusions.patch rename to patches/server/0746-Fix-Spigot-Config-not-using-commands.spam-exclusions.patch index 03696ce783..e706beffcd 100644 --- a/patches/unapplied/server/0774-Fix-Spigot-Config-not-using-commands.spam-exclusions.patch +++ b/patches/server/0746-Fix-Spigot-Config-not-using-commands.spam-exclusions.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Fix Spigot Config not using commands.spam-exclusions diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 19bc63da6bca5b3ff62bb2a148b35e0d3f93bb1d..c26eea3adbe7013ee226f2337e85e423aac11977 100644 +index ae440c8b7597d08ae62dfe301b20886f82c720ca..31813e06e626455d72915683c7aaa7782b9b792d 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -2299,7 +2299,7 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl +@@ -2373,7 +2373,7 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl } // Spigot end // this.chatSpamTickCount += 20; diff --git a/patches/unapplied/server/0775-More-Teleport-API.patch b/patches/server/0747-More-Teleport-API.patch similarity index 95% rename from patches/unapplied/server/0775-More-Teleport-API.patch rename to patches/server/0747-More-Teleport-API.patch index 3cbd69aa87..cf2a188ba2 100644 --- a/patches/unapplied/server/0775-More-Teleport-API.patch +++ b/patches/server/0747-More-Teleport-API.patch @@ -5,10 +5,10 @@ Subject: [PATCH] More Teleport API diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index c26eea3adbe7013ee226f2337e85e423aac11977..f2b865d4e28c3d99d50088c61d0b93bf47300a02 100644 +index 31813e06e626455d72915683c7aaa7782b9b792d..3e641c26695cb1c40a6bde64ac090c4899538e80 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -1558,11 +1558,17 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl +@@ -1559,11 +1559,17 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl return false; // CraftBukkit - Return event status } @@ -29,7 +29,7 @@ index c26eea3adbe7013ee226f2337e85e423aac11977..f2b865d4e28c3d99d50088c61d0b93bf d0 = to.getX(); d1 = to.getY(); diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java -index 46bc34741394740de46546bd4ce7db35c757316c..79e58d7a72a599cd84d479be62f72c523e37dd07 100644 +index 113ca1d16cb7650d72f488cdaa9e670d51dc85f0..b6fef2ca5b564c293cb602cb8e300d35dba89b1f 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java @@ -219,15 +219,36 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity { @@ -71,7 +71,7 @@ index 46bc34741394740de46546bd4ce7db35c757316c..79e58d7a72a599cd84d479be62f72c52 // Let the server handle cross world teleports if (location.getWorld() != null && !location.getWorld().equals(this.getWorld())) { -@@ -948,6 +969,39 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity { +@@ -958,6 +979,39 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity { return CraftEntity.perm; } @@ -112,10 +112,10 @@ index 46bc34741394740de46546bd4ce7db35c757316c..79e58d7a72a599cd84d479be62f72c52 private final org.bukkit.entity.Entity.Spigot spigot = new org.bukkit.entity.Entity.Spigot() { diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -index b0e552d959f349878fc36f136f4d541f85d032fe..c5175427fdb6e990c47c014f99d1784959d83658 100644 +index d2f98aeb4a209e9ed4a7b6bddba8a299fc21d002..15f2dec16042c79303b88b6dfb1ba17ec13a5f56 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -@@ -1197,13 +1197,101 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -1273,13 +1273,101 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @Override public void setRotation(float yaw, float pitch) { @@ -218,7 +218,7 @@ index b0e552d959f349878fc36f136f4d541f85d032fe..c5175427fdb6e990c47c014f99d17849 location.checkFinite(); ServerPlayer entity = this.getHandle(); -@@ -1216,7 +1304,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -1292,7 +1380,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player { return false; } @@ -227,7 +227,7 @@ index b0e552d959f349878fc36f136f4d541f85d032fe..c5175427fdb6e990c47c014f99d17849 return false; } -@@ -1225,7 +1313,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -1301,7 +1389,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player { // To = Players new Location if Teleport is Successful Location to = location; // Create & Call the Teleport Event. @@ -236,7 +236,7 @@ index b0e552d959f349878fc36f136f4d541f85d032fe..c5175427fdb6e990c47c014f99d17849 this.server.getPluginManager().callEvent(event); // Return False to inform the Plugin that the Teleport was unsuccessful/cancelled. -@@ -1234,7 +1322,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -1310,7 +1398,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player { } // If this player is riding another entity, we must dismount before teleporting. @@ -245,7 +245,7 @@ index b0e552d959f349878fc36f136f4d541f85d032fe..c5175427fdb6e990c47c014f99d17849 // SPIGOT-5509: Wakeup, similar to riding if (this.isSleeping()) { -@@ -1250,13 +1338,19 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -1326,13 +1414,19 @@ public class CraftPlayer extends CraftHumanEntity implements Player { ServerLevel toWorld = ((CraftWorld) to.getWorld()).getHandle(); // Close any foreign inventory diff --git a/patches/unapplied/server/0776-Add-EntityPortalReadyEvent.patch b/patches/server/0748-Add-EntityPortalReadyEvent.patch similarity index 84% rename from patches/unapplied/server/0776-Add-EntityPortalReadyEvent.patch rename to patches/server/0748-Add-EntityPortalReadyEvent.patch index 99fe9a8280..50d3716266 100644 --- a/patches/unapplied/server/0776-Add-EntityPortalReadyEvent.patch +++ b/patches/server/0748-Add-EntityPortalReadyEvent.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Add EntityPortalReadyEvent diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index 319bb4d94f8221e20557c0e0805c581447e2ee57..8b44dc6cfddf77bdfe3684d1cdb15bb9125c4137 100644 +index 3f2293ae7b84c9ec8455f41121adbaf7dbd7da71..4b54b3e121508fb1590654123e86c6c5de54a755 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -2832,6 +2832,13 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, S +@@ -2862,6 +2862,13 @@ public abstract class Entity implements SyncedDataHolder, Nameable, EntityAccess if (true && !this.isPassenger() && this.portalTime++ >= i) { // CraftBukkit this.level().getProfiler().push("portal"); this.portalTime = i; @@ -22,7 +22,7 @@ index 319bb4d94f8221e20557c0e0805c581447e2ee57..8b44dc6cfddf77bdfe3684d1cdb15bb9 this.setPortalCooldown(); // CraftBukkit start if (this instanceof ServerPlayer) { -@@ -2839,6 +2846,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, S +@@ -2869,6 +2876,7 @@ public abstract class Entity implements SyncedDataHolder, Nameable, EntityAccess } else { this.changeDimension(worldserver1); } diff --git a/patches/unapplied/server/0777-Don-t-use-level-random-in-entity-constructors.patch b/patches/server/0749-Don-t-use-level-random-in-entity-constructors.patch similarity index 87% rename from patches/unapplied/server/0777-Don-t-use-level-random-in-entity-constructors.patch rename to patches/server/0749-Don-t-use-level-random-in-entity-constructors.patch index ef3475e3a3..4d7c249601 100644 --- a/patches/unapplied/server/0777-Don-t-use-level-random-in-entity-constructors.patch +++ b/patches/server/0749-Don-t-use-level-random-in-entity-constructors.patch @@ -9,10 +9,10 @@ should be supported. Some entities (for whatever reason) use the level's random in some places. diff --git a/src/main/java/net/minecraft/world/entity/item/ItemEntity.java b/src/main/java/net/minecraft/world/entity/item/ItemEntity.java -index 78acc580d66917e52d89632e3f0b7c1e979714d4..d0dac3dc89b9bb645a1d8498802fb8c6bff6a78e 100644 +index 1817e8876f13695578b0a5b2f75e738b3286db48..b392fda26982517cbc2c04156897184275ce69e5 100644 --- a/src/main/java/net/minecraft/world/entity/item/ItemEntity.java +++ b/src/main/java/net/minecraft/world/entity/item/ItemEntity.java -@@ -67,7 +67,12 @@ public class ItemEntity extends Entity implements TraceableEntity { +@@ -71,7 +71,12 @@ public class ItemEntity extends Entity implements TraceableEntity { } public ItemEntity(Level world, double x, double y, double z, ItemStack stack) { @@ -27,10 +27,10 @@ index 78acc580d66917e52d89632e3f0b7c1e979714d4..d0dac3dc89b9bb645a1d8498802fb8c6 public ItemEntity(Level world, double x, double y, double z, ItemStack stack, double velocityX, double velocityY, double velocityZ) { diff --git a/src/main/java/net/minecraft/world/entity/item/PrimedTnt.java b/src/main/java/net/minecraft/world/entity/item/PrimedTnt.java -index 16f9d38687c0fdda18468b5bfb61b09b98254968..e712bd07ea2946167782473a536e0c72fab4bccd 100644 +index 4772e7978858263702312669f400d3da9c486730..f1f352ec0e51f5db59254841a06c176c5a876fc9 100644 --- a/src/main/java/net/minecraft/world/entity/item/PrimedTnt.java +++ b/src/main/java/net/minecraft/world/entity/item/PrimedTnt.java -@@ -44,7 +44,7 @@ public class PrimedTnt extends Entity implements TraceableEntity { +@@ -42,7 +42,7 @@ public class PrimedTnt extends Entity implements TraceableEntity { public PrimedTnt(Level world, double x, double y, double z, @Nullable LivingEntity igniter) { this(EntityType.TNT, world); this.setPos(x, y, z); diff --git a/patches/unapplied/server/0778-Send-block-entities-after-destroy-prediction.patch b/patches/server/0750-Send-block-entities-after-destroy-prediction.patch similarity index 91% rename from patches/unapplied/server/0778-Send-block-entities-after-destroy-prediction.patch rename to patches/server/0750-Send-block-entities-after-destroy-prediction.patch index a6024df886..f11ba32538 100644 --- a/patches/unapplied/server/0778-Send-block-entities-after-destroy-prediction.patch +++ b/patches/server/0750-Send-block-entities-after-destroy-prediction.patch @@ -7,10 +7,10 @@ Minecraft's prediction system does not handle block entities, so if we are manua block breaking we need to set it after the prediction is finished. This fixes block entities not showing when cancelling the BlockBreakEvent. diff --git a/src/main/java/net/minecraft/server/level/ServerPlayerGameMode.java b/src/main/java/net/minecraft/server/level/ServerPlayerGameMode.java -index 8f4c9b99b638cfce8cc7c55f6369f62e757f4e48..f3389dc345d8b6e5389ae37848d9b268d4bbad83 100644 +index d8c5f8e584976a97bd909bfa20023993ab776952..77e78808171daac78502ef3fcc70f03579eaa9e3 100644 --- a/src/main/java/net/minecraft/server/level/ServerPlayerGameMode.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayerGameMode.java -@@ -62,6 +62,8 @@ public class ServerPlayerGameMode { +@@ -61,6 +61,8 @@ public class ServerPlayerGameMode { private BlockPos delayedDestroyPos; private int delayedTickStart; private int lastSentState; @@ -19,7 +19,7 @@ index 8f4c9b99b638cfce8cc7c55f6369f62e757f4e48..f3389dc345d8b6e5389ae37848d9b268 public ServerPlayerGameMode(ServerPlayer player) { this.gameModeForPlayer = GameType.DEFAULT_MODE; -@@ -188,10 +190,7 @@ public class ServerPlayerGameMode { +@@ -191,10 +193,7 @@ public class ServerPlayerGameMode { this.player.connection.send(new ClientboundBlockUpdatePacket(pos, this.level.getBlockState(pos))); this.debugLogging(pos, false, sequence, "may not interact"); // Update any tile entity data for this block @@ -31,7 +31,7 @@ index 8f4c9b99b638cfce8cc7c55f6369f62e757f4e48..f3389dc345d8b6e5389ae37848d9b268 // CraftBukkit end return; } -@@ -202,10 +201,7 @@ public class ServerPlayerGameMode { +@@ -205,10 +204,7 @@ public class ServerPlayerGameMode { // Let the client know the block still exists this.player.connection.send(new ClientboundBlockUpdatePacket(this.level, pos)); // Update any tile entity data for this block @@ -43,7 +43,7 @@ index 8f4c9b99b638cfce8cc7c55f6369f62e757f4e48..f3389dc345d8b6e5389ae37848d9b268 return; } // CraftBukkit end -@@ -387,10 +383,12 @@ public class ServerPlayerGameMode { +@@ -390,10 +386,12 @@ public class ServerPlayerGameMode { } // Update any tile entity data for this block @@ -57,10 +57,10 @@ index 8f4c9b99b638cfce8cc7c55f6369f62e757f4e48..f3389dc345d8b6e5389ae37848d9b268 } } diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index f2b865d4e28c3d99d50088c61d0b93bf47300a02..faa43550844fd3a3595bd9621b5730c209a54124 100644 +index 3e641c26695cb1c40a6bde64ac090c4899538e80..d20baa57c5367861fb5b3b6ea746a6391b6115cc 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -1704,8 +1704,28 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl +@@ -1706,8 +1706,28 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl return; } // Paper end - Don't allow digging into unloaded chunks diff --git a/patches/unapplied/server/0779-Warn-on-plugins-accessing-faraway-chunks.patch b/patches/server/0751-Warn-on-plugins-accessing-faraway-chunks.patch similarity index 93% rename from patches/unapplied/server/0779-Warn-on-plugins-accessing-faraway-chunks.patch rename to patches/server/0751-Warn-on-plugins-accessing-faraway-chunks.patch index 2b9d9f5b89..1161fdc26e 100644 --- a/patches/unapplied/server/0779-Warn-on-plugins-accessing-faraway-chunks.patch +++ b/patches/server/0751-Warn-on-plugins-accessing-faraway-chunks.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Warn on plugins accessing faraway chunks diff --git a/src/main/java/net/minecraft/world/level/Level.java b/src/main/java/net/minecraft/world/level/Level.java -index 1ed82afbc3aaa826f8067c65fdfc3ffce36a2ce5..59dba562e17e9463c1e00dee4979b61a0f68643e 100644 +index 12a104fd9aa6c02a4e983f9651e07804a8df606e..37c81d6c95efaab12a05075e6397ab2548c76722 100644 --- a/src/main/java/net/minecraft/world/level/Level.java +++ b/src/main/java/net/minecraft/world/level/Level.java -@@ -345,7 +345,7 @@ public abstract class Level implements LevelAccessor, AutoCloseable { +@@ -339,7 +339,7 @@ public abstract class Level implements LevelAccessor, AutoCloseable { } private static boolean isInWorldBoundsHorizontal(BlockPos pos) { @@ -18,7 +18,7 @@ index 1ed82afbc3aaa826f8067c65fdfc3ffce36a2ce5..59dba562e17e9463c1e00dee4979b61a private static boolean isOutsideSpawnableHeight(int y) { diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -index f2e4494a31dd7ca7e099c6960a9e6378ecac8727..51e709beb32499f2f56189a0426bba93c43e1c0d 100644 +index 4efbda6521f36ceae3b5b32ad0c79fa53b48b5bd..6231bc770ea6eb6aba47abbc74b6380fd9360d8c 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java @@ -319,9 +319,24 @@ public class CraftWorld extends CraftRegionAccessor implements World { @@ -78,7 +78,7 @@ index f2e4494a31dd7ca7e099c6960a9e6378ecac8727..51e709beb32499f2f56189a0426bba93 this.getHandle().setChunkForced(x, z, forced); } -@@ -967,6 +986,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -976,6 +995,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { @Override public int getHighestBlockYAt(int x, int z, org.bukkit.HeightMap heightMap) { @@ -86,7 +86,7 @@ index f2e4494a31dd7ca7e099c6960a9e6378ecac8727..51e709beb32499f2f56189a0426bba93 // Transient load for this tick return this.world.getChunk(x >> 4, z >> 4).getHeight(CraftHeightMap.toNMS(heightMap), x, z); } -@@ -2400,6 +2420,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -2398,6 +2418,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { // Spigot end // Paper start public java.util.concurrent.CompletableFuture getChunkAtAsync(int x, int z, boolean gen, boolean urgent) { diff --git a/patches/unapplied/server/0780-Custom-Chat-Completion-Suggestions-API.patch b/patches/server/0752-Custom-Chat-Completion-Suggestions-API.patch similarity index 90% rename from patches/unapplied/server/0780-Custom-Chat-Completion-Suggestions-API.patch rename to patches/server/0752-Custom-Chat-Completion-Suggestions-API.patch index ef47ad0def..366dba13d9 100644 --- a/patches/unapplied/server/0780-Custom-Chat-Completion-Suggestions-API.patch +++ b/patches/server/0752-Custom-Chat-Completion-Suggestions-API.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Custom Chat Completion Suggestions API diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -index c5175427fdb6e990c47c014f99d1784959d83658..ccc706733689f07f9b4e1635db4a0259817f71aa 100644 +index 15f2dec16042c79303b88b6dfb1ba17ec13a5f56..7d0cf5cba735b3726d8d9594ce0ac88360149680 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -@@ -613,6 +613,24 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -688,6 +688,24 @@ public class CraftPlayer extends CraftHumanEntity implements Player { } // Paper end - Add sendOpLevel API diff --git a/patches/unapplied/server/0781-Add-and-fix-missing-BlockFadeEvents.patch b/patches/server/0753-Add-and-fix-missing-BlockFadeEvents.patch similarity index 94% rename from patches/unapplied/server/0781-Add-and-fix-missing-BlockFadeEvents.patch rename to patches/server/0753-Add-and-fix-missing-BlockFadeEvents.patch index d164ac2642..18f8fbe87f 100644 --- a/patches/unapplied/server/0781-Add-and-fix-missing-BlockFadeEvents.patch +++ b/patches/server/0753-Add-and-fix-missing-BlockFadeEvents.patch @@ -10,7 +10,7 @@ potentially waterlogged block states fading. Co-authored-by: Lulu13022002 <41980282+Lulu13022002@users.noreply.github.com diff --git a/src/main/java/net/minecraft/world/level/block/FrogspawnBlock.java b/src/main/java/net/minecraft/world/level/block/FrogspawnBlock.java -index 6e283e8c3db31f03dd95c94887e647b8d82a3604..1a842694c076d71b14733904c2052183d86d1f5d 100644 +index a3339b47165814238351d307c729af14d5e5d1ff..2c076a5b23c09f634fa6807c207e5e06e1795e8a 100644 --- a/src/main/java/net/minecraft/world/level/block/FrogspawnBlock.java +++ b/src/main/java/net/minecraft/world/level/block/FrogspawnBlock.java @@ -92,6 +92,11 @@ public class FrogspawnBlock extends Block { @@ -26,7 +26,7 @@ index 6e283e8c3db31f03dd95c94887e647b8d82a3604..1a842694c076d71b14733904c2052183 world.playSound(null, pos, SoundEvents.FROGSPAWN_HATCH, SoundSource.BLOCKS, 1.0F, 1.0F); this.spawnTadpoles(world, pos, random); diff --git a/src/main/java/net/minecraft/world/level/block/ScaffoldingBlock.java b/src/main/java/net/minecraft/world/level/block/ScaffoldingBlock.java -index f660e58badfcc2a90e6dd618428a21bf5ad34969..13ee09f93ec325e416a2b29e3608e870e7f06aed 100644 +index 580c77eeaf88083f2aed2e46e6c57dc1fcf9564c..f4cccbc134b33758cd553a29b9f8e9967517500d 100644 --- a/src/main/java/net/minecraft/world/level/block/ScaffoldingBlock.java +++ b/src/main/java/net/minecraft/world/level/block/ScaffoldingBlock.java @@ -103,7 +103,7 @@ public class ScaffoldingBlock extends Block implements SimpleWaterloggedBlock { @@ -39,7 +39,7 @@ index f660e58badfcc2a90e6dd618428a21bf5ad34969..13ee09f93ec325e416a2b29e3608e870 FallingBlockEntity.fall(world, pos, iblockdata1); } else { diff --git a/src/main/java/net/minecraft/world/level/block/SnifferEggBlock.java b/src/main/java/net/minecraft/world/level/block/SnifferEggBlock.java -index 41bc7180d7657d43215fcb283afe1a9ccdd54e9d..1ff0e5c120418c3e5f92326580af7254fb4c699f 100644 +index 1eda49c9ce8ee009cb08b18f02f59b37c2118628..38288f20306632e6546c95b4cb1a42806be49975 100644 --- a/src/main/java/net/minecraft/world/level/block/SnifferEggBlock.java +++ b/src/main/java/net/minecraft/world/level/block/SnifferEggBlock.java @@ -60,12 +60,26 @@ public class SnifferEggBlock extends Block { diff --git a/patches/unapplied/server/0782-Collision-API.patch b/patches/server/0754-Collision-API.patch similarity index 90% rename from patches/unapplied/server/0782-Collision-API.patch rename to patches/server/0754-Collision-API.patch index 67db25ca90..b4840d04ac 100644 --- a/patches/unapplied/server/0782-Collision-API.patch +++ b/patches/server/0754-Collision-API.patch @@ -5,7 +5,7 @@ Subject: [PATCH] Collision API diff --git a/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java b/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java -index fbcf1320ef9c1817b24aa8724cd6cf07319c20b9..5680e9772a2d90e997d2d0aacdda9eddb7edef56 100644 +index d1c265733941874002f6dfc7543917af88600659..72c275d7da798ee10a224bbd3f4c92abd82601e1 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java @@ -539,5 +539,12 @@ public abstract class CraftRegionAccessor implements RegionAccessor { @@ -22,10 +22,10 @@ index fbcf1320ef9c1817b24aa8724cd6cf07319c20b9..5680e9772a2d90e997d2d0aacdda9edd // Paper end } diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java -index 79e58d7a72a599cd84d479be62f72c523e37dd07..f6d6b2c7aefc39a6e6e2b0e61fd9afb334bee764 100644 +index b6fef2ca5b564c293cb602cb8e300d35dba89b1f..92c80776273f6be43b40686c7ab7dd7371b1c06f 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java -@@ -1164,4 +1164,20 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity { +@@ -1174,4 +1174,20 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity { return this.getHandle().noPhysics; } // Paper end - missing entity api diff --git a/patches/unapplied/server/0783-Fix-suggest-command-message-for-brigadier-syntax-exc.patch b/patches/server/0755-Fix-suggest-command-message-for-brigadier-syntax-exc.patch similarity index 89% rename from patches/unapplied/server/0783-Fix-suggest-command-message-for-brigadier-syntax-exc.patch rename to patches/server/0755-Fix-suggest-command-message-for-brigadier-syntax-exc.patch index 8645146d61..42748ba6d8 100644 --- a/patches/unapplied/server/0783-Fix-suggest-command-message-for-brigadier-syntax-exc.patch +++ b/patches/server/0755-Fix-suggest-command-message-for-brigadier-syntax-exc.patch @@ -6,10 +6,10 @@ Subject: [PATCH] Fix suggest command message for brigadier syntax exceptions This is a bug accidentally introduced in upstream CB diff --git a/src/main/java/net/minecraft/commands/Commands.java b/src/main/java/net/minecraft/commands/Commands.java -index 8be58d29f2a4753a241e68bd305b3e30186ca0e9..dd7c1ac97505ce7a846aa8ee91bb654d060acc1a 100644 +index 412c21ce2dcd772e525432efadff7e1340cb58e9..4114e2b148baf9ddc489eed11fed4aacd0eab401 100644 --- a/src/main/java/net/minecraft/commands/Commands.java +++ b/src/main/java/net/minecraft/commands/Commands.java -@@ -392,7 +392,7 @@ public class Commands { +@@ -395,7 +395,7 @@ public class Commands { if (commandsyntaxexception.getInput() != null && commandsyntaxexception.getCursor() >= 0) { int i = Math.min(commandsyntaxexception.getInput().length(), commandsyntaxexception.getCursor()); MutableComponent ichatmutablecomponent = Component.empty().withStyle(ChatFormatting.GRAY).withStyle((chatmodifier) -> { diff --git a/patches/unapplied/server/0784-Block-Ticking-API.patch b/patches/server/0756-Block-Ticking-API.patch similarity index 93% rename from patches/unapplied/server/0784-Block-Ticking-API.patch rename to patches/server/0756-Block-Ticking-API.patch index d26cc16750..5a45bad712 100644 --- a/patches/unapplied/server/0784-Block-Ticking-API.patch +++ b/patches/server/0756-Block-Ticking-API.patch @@ -46,10 +46,10 @@ index 6d10396347b69d9243ab902ecc68ede93fa17b7d..af219df5267589300f0ad1d30fa5c81a // Paper end } diff --git a/src/main/java/org/bukkit/craftbukkit/block/data/CraftBlockData.java b/src/main/java/org/bukkit/craftbukkit/block/data/CraftBlockData.java -index a4252f9078c3ab7e458504496ebcdeb6875724d1..37c5d66dafd877d2231c8d191f5a84748bf24551 100644 +index 48e8d0cc267706d3d8e29333d7fd6b89fdd88553..841b6cabd319229bff9f830c2fe4de102ad74906 100644 --- a/src/main/java/org/bukkit/craftbukkit/block/data/CraftBlockData.java +++ b/src/main/java/org/bukkit/craftbukkit/block/data/CraftBlockData.java -@@ -735,4 +735,11 @@ public class CraftBlockData implements BlockData { +@@ -736,4 +736,11 @@ public class CraftBlockData implements BlockData { return speed; } // Paper end - destroy speed API diff --git a/patches/unapplied/server/0785-Add-Velocity-IP-Forwarding-Support.patch b/patches/server/0757-Add-Velocity-IP-Forwarding-Support.patch similarity index 94% rename from patches/unapplied/server/0785-Add-Velocity-IP-Forwarding-Support.patch rename to patches/server/0757-Add-Velocity-IP-Forwarding-Support.patch index 64983350da..31c9bd57a6 100644 --- a/patches/unapplied/server/0785-Add-Velocity-IP-Forwarding-Support.patch +++ b/patches/server/0757-Add-Velocity-IP-Forwarding-Support.patch @@ -106,10 +106,10 @@ index 0000000000000000000000000000000000000000..3c31ff3330c2e925e205c0c9ff4f0b83 + } +} diff --git a/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java b/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java -index 608d860b940dee870a3df3d52efaed5e9eab17cf..5675931fe3ea896027a510944fc484f41f5ef555 100644 +index 784788d8d3d1a07efbd406b6c463e046699081e2..fdff82ed5dbf5176d470b9b6c41acfe6b98c7039 100644 --- a/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java +++ b/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java -@@ -274,13 +274,20 @@ public class DedicatedServer extends MinecraftServer implements ServerInterface +@@ -287,13 +287,20 @@ public class DedicatedServer extends MinecraftServer implements ServerInterface this.server.enablePlugins(org.bukkit.plugin.PluginLoadOrder.STARTUP); // CraftBukkit end @@ -134,20 +134,20 @@ index 608d860b940dee870a3df3d52efaed5e9eab17cf..5675931fe3ea896027a510944fc484f4 DedicatedServer.LOGGER.warn("While this makes the game possible to play without internet access, it also opens up the ability for hackers to connect with any username they choose."); } diff --git a/src/main/java/net/minecraft/server/network/ServerLoginPacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerLoginPacketListenerImpl.java -index fb582acfe9e5cb68314ee39e1d54a550d6700e76..b8d8f14c30786321949901ca5184c43bee716355 100644 +index 49627a02cb15e94e7c3ddfe65aa663d982a34408..21d97c2b533a6528dd73c4e514d49273c120e171 100644 --- a/src/main/java/net/minecraft/server/network/ServerLoginPacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerLoginPacketListenerImpl.java -@@ -64,6 +64,7 @@ public class ServerLoginPacketListenerImpl implements ServerLoginPacketListener, - private final String serverId; +@@ -84,6 +84,7 @@ public class ServerLoginPacketListenerImpl implements ServerLoginPacketListener, + private final boolean transferred; private ServerPlayer player; // CraftBukkit public boolean iKnowThisMayNotBeTheBestIdeaButPleaseDisableUsernameValidation = false; // Paper - username validation overriding + private int velocityLoginMessageId = -1; // Paper - Add Velocity IP Forwarding Support - public ServerLoginPacketListenerImpl(MinecraftServer server, Connection connection) { + public ServerLoginPacketListenerImpl(MinecraftServer server, Connection connection, boolean transferred) { this.state = ServerLoginPacketListenerImpl.State.HELLO; -@@ -149,6 +150,16 @@ public class ServerLoginPacketListenerImpl implements ServerLoginPacketListener, +@@ -176,6 +177,16 @@ public class ServerLoginPacketListenerImpl implements ServerLoginPacketListener, this.state = ServerLoginPacketListenerImpl.State.KEY; - this.connection.send(new ClientboundHelloPacket("", this.server.getKeyPair().getPublic().getEncoded(), this.challenge)); + this.connection.send(new ClientboundHelloPacket("", this.server.getKeyPair().getPublic().getEncoded(), this.challenge, true)); } else { + // Paper start - Add Velocity IP Forwarding Support + if (io.papermc.paper.configuration.GlobalConfiguration.get().proxies.velocity.enabled) { @@ -162,7 +162,7 @@ index fb582acfe9e5cb68314ee39e1d54a550d6700e76..b8d8f14c30786321949901ca5184c43b // CraftBukkit start // Paper start - Cache authenticator threads authenticatorPool.execute(new Runnable() { -@@ -289,6 +300,12 @@ public class ServerLoginPacketListenerImpl implements ServerLoginPacketListener, +@@ -328,6 +339,12 @@ public class ServerLoginPacketListenerImpl implements ServerLoginPacketListener, // CraftBukkit start private GameProfile callPlayerPreLoginEvents(GameProfile gameprofile) throws Exception { // Paper - Add more fields to AsyncPlayerPreLoginEvent @@ -175,7 +175,7 @@ index fb582acfe9e5cb68314ee39e1d54a550d6700e76..b8d8f14c30786321949901ca5184c43b String playerName = gameprofile.getName(); java.net.InetAddress address = ((java.net.InetSocketAddress) this.connection.getRemoteAddress()).getAddress(); java.util.UUID uniqueId = gameprofile.getId(); -@@ -334,6 +351,51 @@ public class ServerLoginPacketListenerImpl implements ServerLoginPacketListener, +@@ -373,6 +390,51 @@ public class ServerLoginPacketListenerImpl implements ServerLoginPacketListener, @Override public void handleCustomQueryPacket(ServerboundCustomQueryAnswerPacket packet) { @@ -224,11 +224,11 @@ index fb582acfe9e5cb68314ee39e1d54a550d6700e76..b8d8f14c30786321949901ca5184c43b + return; + } + // Paper end - Add Velocity IP Forwarding Support - this.disconnect(ServerLoginPacketListenerImpl.DISCONNECT_UNEXPECTED_QUERY); + this.disconnect(ServerCommonPacketListenerImpl.DISCONNECT_UNEXPECTED_QUERY); } diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index e849e706660bf0b0ef1748dfee3ba75e5aff9863..10450a2bb6973a647fb6969d3c142e7a6a1011a4 100644 +index d2a02210553363fb87882904abcfbe2ccd95fa78..d5575fcc1458fe3083821792f09f9ed53c12e825 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java @@ -815,7 +815,7 @@ public final class CraftServer implements Server { diff --git a/patches/unapplied/server/0759-Disable-component-selector-resolving-in-books-by-def.patch b/patches/unapplied/server/0759-Disable-component-selector-resolving-in-books-by-def.patch deleted file mode 100644 index 97082feba7..0000000000 --- a/patches/unapplied/server/0759-Disable-component-selector-resolving-in-books-by-def.patch +++ /dev/null @@ -1,19 +0,0 @@ -From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 -From: Nassim Jahnke -Date: Thu, 2 Jun 2022 20:35:58 +0200 -Subject: [PATCH] Disable component selector resolving in books by default - - -diff --git a/src/main/java/net/minecraft/world/item/WrittenBookItem.java b/src/main/java/net/minecraft/world/item/WrittenBookItem.java -index 81bb0abea7ebd2705f84fae31e4a3d2de92d7d18..793ab8acd7445984cff2628e3f001661dc20c8e5 100644 ---- a/src/main/java/net/minecraft/world/item/WrittenBookItem.java -+++ b/src/main/java/net/minecraft/world/item/WrittenBookItem.java -@@ -112,7 +112,7 @@ public class WrittenBookItem extends Item { - - public static boolean resolveBookComponents(ItemStack book, @Nullable CommandSourceStack commandSource, @Nullable Player player) { - CompoundTag compoundTag = book.getTag(); -- if (compoundTag != null && !compoundTag.getBoolean("resolved")) { -+ if (io.papermc.paper.configuration.GlobalConfiguration.get().itemValidation.resolveSelectorsInBooks && compoundTag != null && !compoundTag.getBoolean("resolved")) { // Paper - Disable component selector resolving in books by default - compoundTag.putBoolean("resolved", true); - if (!makeSureTagIsValid(compoundTag)) { - return false; diff --git a/patches/unapplied/server/0757-properly-read-and-store-sus-effect-duration.patch b/removed-patches-1-20-5/0757-properly-read-and-store-sus-effect-duration.patch similarity index 100% rename from patches/unapplied/server/0757-properly-read-and-store-sus-effect-duration.patch rename to removed-patches-1-20-5/0757-properly-read-and-store-sus-effect-duration.patch