From 2e363c73ba3c0a7b3d5138ec55a6e93c7befb5bb Mon Sep 17 00:00:00 2001
From: Jason <11360596+jpenilla@users.noreply.github.com>
Date: Tue, 13 Jun 2023 00:10:07 -0700
Subject: [PATCH] 1.20.1 (#9333)
---
README.md | 4 +--
build.gradle.kts | 2 +-
gradle.properties | 4 +--
.../api/0001-Convert-project-to-Gradle.patch | 4 +--
...-option-to-load-extra-plugin-jars-no.patch | 4 +--
...mation-to-version-command-on-startup.patch | 2 +-
patches/api/0194-Expose-game-version.patch | 4 +--
.../server/0001-Setup-Gradle-project.patch | 4 +--
.../server/0003-Build-system-changes.patch | 2 +-
patches/server/0004-Test-changes.patch | 2 +-
patches/server/0009-MC-Utils.patch | 2 +-
patches/server/0010-Adventure.patch | 2 +-
patches/server/0013-Paper-Plugins.patch | 2 +-
patches/server/0014-Timings-v2.patch | 2 +-
patches/server/0016-Starlight.patch | 4 +--
.../server/0019-Rewrite-chunk-system.patch | 14 +++++-----
.../0028-Implement-Paper-VersionChecker.patch | 2 +-
...nfigurable-top-of-nether-void-damage.patch | 2 +-
.../0037-Always-tick-falling-blocks.patch | 2 +-
.../0038-Configurable-end-credits.patch | 2 +-
...4-Configurable-mob-spawner-tick-rate.patch | 2 +-
...figurable-container-update-tick-rate.patch | 2 +-
.../0050-Add-PlayerInitialSpawnEvent.patch | 2 +-
...dd-configurable-portal-search-radius.patch | 2 +-
...oreboards-for-non-players-by-default.patch | 2 +-
...074-Use-a-Shared-Random-for-Entities.patch | 2 +-
...-API-Replenishable-Lootables-Feature.patch | 2 +-
...08-Configurable-flying-kick-messages.patch | 2 +-
.../0125-Enforce-Sync-Player-Saves.patch | 2 +-
...llow-entities-to-ride-themselves-572.patch | 2 +-
.../server/0128-Cap-Entity-Collisions.patch | 2 +-
...-profile-lookups-to-worldgen-threads.patch | 2 +-
.../0149-ProfileWhitelistVerifyEvent.patch | 2 +-
...n-prefixes-using-Log4J-configuration.patch | 2 +-
patches/server/0157-Add-PlayerJumpEvent.patch | 2 +-
...nt-protocol-version-and-virtual-host.patch | 4 +--
...rt-serverside-behavior-of-keepalives.patch | 2 +-
...0-PlayerNaturallySpawnCreaturesEvent.patch | 2 +-
.../server/0172-PreCreatureSpawnEvent.patch | 2 +-
...le-Explicit-Network-Manager-Flushing.patch | 6 ++---
patches/server/0190-EndermanEscapeEvent.patch | 2 +-
.../0191-Enderman.teleportRandomly.patch | 13 ----------
.../0196-EndermanAttackPlayerEvent.patch | 2 +-
...KnockbackByEntityEvent-and-EntityPus.patch | 2 +-
...r-to-keep-logging-IO-off-main-thread.patch | 2 +-
...-more-information-to-Entity.toString.patch | 2 +-
...nd-make-tab-spam-limits-configurable.patch | 2 +-
...ies-option-to-debug-dupe-uuid-issues.patch | 2 +-
...38-Use-ConcurrentHashMap-in-JsonList.patch | 2 +-
.../server/0264-PreSpawnerSpawnEvent.patch | 2 +-
...tator-target-events-and-improve-impl.patch | 2 +-
...event-players-from-moving-into-unloa.patch | 2 +-
...store-custom-InventoryHolder-support.patch | 4 +--
...e-Large-Packets-disconnecting-client.patch | 4 +--
...entity-dismount-during-teleportation.patch | 2 +-
patches/server/0287-Book-Size-Limits.patch | 2 +-
.../0288-Add-PlayerConnectionCloseEvent.patch | 4 +--
...Prevent-Enderman-from-loading-chunks.patch | 2 +-
...vehicle-tracking-issue-on-disconnect.patch | 2 +-
.../0295-Implement-Brigadier-Mojang-API.patch | 4 +--
...-Manager-and-add-advanced-packet-sup.patch | 26 +++++++++----------
...oggleEvent-when-whitelist-is-toggled.patch | 2 +-
...303-Implement-PlayerPostRespawnEvent.patch | 2 +-
...0306-PlayerDeathEvent-getItemsToKeep.patch | 2 +-
...l-to-changed-postToMainThread-method.patch | 2 +-
patches/server/0321-Fix-MC-158900.patch | 2 +-
...layerDeathEvent-shouldDropExperience.patch | 2 +-
...0333-Fix-items-not-falling-correctly.patch | 2 +-
...x-items-vanishing-through-end-portal.patch | 2 +-
...ement-optional-per-player-mob-spawns.patch | 2 +-
...n-to-nerf-pigmen-from-nether-portals.patch | 2 +-
.../0352-Make-the-GUI-graph-fancier.patch | 2 +-
...353-add-hand-to-BlockMultiPlaceEvent.patch | 2 +-
...Add-Raw-Byte-ItemStack-Serialization.patch | 2 +-
...spawn-settings-and-per-player-option.patch | 2 +-
.../server/0366-Don-t-tick-dead-players.patch | 2 +-
...ptimize-Collision-to-not-load-chunks.patch | 4 +--
...move-existing-players-to-world-spawn.patch | 4 +--
...g-Broken-behavior-of-PlayerJoinEvent.patch | 4 +--
...pawn-point-if-spawn-in-unloaded-worl.patch | 2 +-
...m-duplication-issues-and-teleport-is.patch | 4 +--
...PickItem-Packet-and-kick-for-invalid.patch | 2 +-
...ktraces-in-log-messages-crash-report.patch | 6 ++---
.../server/0393-Implement-Mob-Goal-API.patch | 2 +-
...-maximum-exp-value-when-merging-orbs.patch | 2 +-
.../server/0396-ExperienceOrbMergeEvent.patch | 2 +-
patches/server/0399-Potential-bed-API.patch | 2 +-
...-desync-in-playerconnection-causing-.patch | 2 +-
...tance-map-to-optimise-entity-tracker.patch | 2 +-
...19-Add-permission-for-command-blocks.patch | 2 +-
...sure-Entity-AABB-s-are-never-invalid.patch | 2 +-
...awn-player-in-correct-world-on-login.patch | 2 +-
patches/server/0442-Fix-SPIGOT-5989.patch | 2 +-
.../server/0457-Buffer-joins-to-world.patch | 4 +--
...y-Counter-to-allow-plugins-to-use-va.patch | 2 +-
...ix-client-lag-on-advancement-loading.patch | 2 +-
.../server/0491-Add-API-for-quit-reason.patch | 4 +--
.../server/0570-Expand-world-key-API.patch | 2 +-
patches/server/0572-Item-Rarity-API.patch | 2 +-
.../server/0576-Expose-protocol-version.patch | 2 +-
...Add-Channel-initialization-listeners.patch | 6 ++---
.../0606-ItemStack-repair-check-API.patch | 2 +-
...613-Attributes-API-for-item-defaults.patch | 2 +-
.../0633-Missing-Entity-Behavior-API.patch | 2 +-
.../0669-Get-entity-default-attributes.patch | 2 +-
...Collidable-methods-to-various-places.patch | 2 +-
...78-Add-Raw-Byte-Entity-Serialization.patch | 2 +-
...trolled-flushing-for-network-manager.patch | 18 ++++++-------
...l-more-information-in-watchdog-dumps.patch | 4 +--
.../0697-Add-packet-limiter-config.patch | 6 ++---
...07-Optimise-non-flush-packet-sending.patch | 4 +--
...ocity-compression-and-cipher-natives.patch | 8 +++---
.../0827-Add-support-for-Proxy-Protocol.patch | 2 +-
...0863-Add-NamespacedKey-biome-methods.patch | 2 +-
work/BuildData | 2 +-
work/Bukkit | 2 +-
work/CraftBukkit | 2 +-
work/Spigot | 2 +-
118 files changed, 174 insertions(+), 187 deletions(-)
diff --git a/README.md b/README.md
index 95d0d66253..204ab5abcd 100644
--- a/README.md
+++ b/README.md
@@ -38,7 +38,7 @@ How To (Plugin Developers)
io.papermc.paper
paper-api
- 1.20-R0.1-SNAPSHOT
+ 1.20.1-R0.1-SNAPSHOT
provided
```
@@ -54,7 +54,7 @@ repositories {
}
dependencies {
- compileOnly("io.papermc.paper:paper-api:1.20-R0.1-SNAPSHOT")
+ compileOnly("io.papermc.paper:paper-api:1.20.1-R0.1-SNAPSHOT")
}
java {
diff --git a/build.gradle.kts b/build.gradle.kts
index ef118f52f7..aa78c58d53 100644
--- a/build.gradle.kts
+++ b/build.gradle.kts
@@ -61,7 +61,7 @@ repositories {
}
dependencies {
- paramMappings("net.fabricmc:yarn:1.20+build.1:mergedv2")
+ paramMappings("net.fabricmc:yarn:1.20.1+build.1:mergedv2")
remapper("net.fabricmc:tiny-remapper:0.8.6:fat")
decompiler("net.minecraftforge:forgeflower:2.0.627.2")
spigotDecompiler("io.papermc:patched-spigot-fernflower:0.1+build.6")
diff --git a/gradle.properties b/gradle.properties
index 5fb6c52862..469b0f4f33 100644
--- a/gradle.properties
+++ b/gradle.properties
@@ -1,6 +1,6 @@
group=io.papermc.paper
-version=1.20-R0.1-SNAPSHOT
-mcVersion=1.20
+version=1.20.1-R0.1-SNAPSHOT
+mcVersion=1.20.1
org.gradle.caching=true
org.gradle.parallel=true
diff --git a/patches/api/0001-Convert-project-to-Gradle.patch b/patches/api/0001-Convert-project-to-Gradle.patch
index 0c2b472b98..fc709129d9 100644
--- a/patches/api/0001-Convert-project-to-Gradle.patch
+++ b/patches/api/0001-Convert-project-to-Gradle.patch
@@ -118,7 +118,7 @@ index 0000000000000000000000000000000000000000..73bc33e7a498f8eca2d68c4588b04de4
+}
diff --git a/pom.xml b/pom.xml
deleted file mode 100644
-index 3c8af751e4b445dd65c9618633f16e181800a73b..0000000000000000000000000000000000000000
+index e6d48b5fdc484ed2443ddf1d60079a13ea2c9677..0000000000000000000000000000000000000000
--- a/pom.xml
+++ /dev/null
@@ -1,270 +0,0 @@
@@ -129,7 +129,7 @@ index 3c8af751e4b445dd65c9618633f16e181800a73b..00000000000000000000000000000000
-
- org.spigotmc
- spigot-api
-- 1.20-R0.1-SNAPSHOT
+- 1.20.1-R0.1-SNAPSHOT
- jar
-
- Spigot-API
diff --git a/patches/api/0011-Add-command-line-option-to-load-extra-plugin-jars-no.patch b/patches/api/0011-Add-command-line-option-to-load-extra-plugin-jars-no.patch
index 4d6266c64b..bd1f1a2e40 100644
--- a/patches/api/0011-Add-command-line-option-to-load-extra-plugin-jars-no.patch
+++ b/patches/api/0011-Add-command-line-option-to-load-extra-plugin-jars-no.patch
@@ -7,7 +7,7 @@ Subject: [PATCH] Add command line option to load extra plugin jars not in the
ex: java -jar paperclip.jar nogui -add-plugin=/path/to/plugin.jar -add-plugin=/path/to/another/plugin_jar.jar
diff --git a/src/main/java/org/bukkit/Bukkit.java b/src/main/java/org/bukkit/Bukkit.java
-index ffacdd168e2b68663becfcfc5c917a41f8ec817d..003d1613fb1b5a24146fb3eeba0be7bf5a4eb8b8 100644
+index 1f4df6984a8b8bd3e72a5eb7fb1c66b6bfddfbf5..d77a7acb3ea82a331cb773bfda3e66d26a2bbd68 100644
--- a/src/main/java/org/bukkit/Bukkit.java
+++ b/src/main/java/org/bukkit/Bukkit.java
@@ -77,6 +77,20 @@ public final class Bukkit {
@@ -32,7 +32,7 @@ index ffacdd168e2b68663becfcfc5c917a41f8ec817d..003d1613fb1b5a24146fb3eeba0be7bf
* Attempts to set the {@link Server} singleton.
*
diff --git a/src/main/java/org/bukkit/Server.java b/src/main/java/org/bukkit/Server.java
-index cadf590c7e597a503078892b3d5671642a80eb3f..15b07d05d948d5df21591dc9e1b0fc0232c984ec 100644
+index e773b40ff5fa9890c72e45e5c75a155bd7d02954..76d28815a51d73fc79ef8bb5abe8fc7758e6fd23 100644
--- a/src/main/java/org/bukkit/Server.java
+++ b/src/main/java/org/bukkit/Server.java
@@ -62,6 +62,18 @@ import org.jetbrains.annotations.Nullable;
diff --git a/patches/api/0146-Add-Git-information-to-version-command-on-startup.patch b/patches/api/0146-Add-Git-information-to-version-command-on-startup.patch
index 91979498d6..da996bbc7b 100644
--- a/patches/api/0146-Add-Git-information-to-version-command-on-startup.patch
+++ b/patches/api/0146-Add-Git-information-to-version-command-on-startup.patch
@@ -48,7 +48,7 @@ index 0000000000000000000000000000000000000000..909617079db61b675cc7b60b44ef96b3
+ }
+}
diff --git a/src/main/java/org/bukkit/Bukkit.java b/src/main/java/org/bukkit/Bukkit.java
-index 7113f38eac400bc86a427972e501b0ca5653dae6..733b537d4236e5cb06efc188183ad876db31c0ff 100644
+index 36c5294e6169c3aa4517cd2c945b5dfb7a2a0c51..36a127864be2a75a38bcc6eacafde5109e5c6c69 100644
--- a/src/main/java/org/bukkit/Bukkit.java
+++ b/src/main/java/org/bukkit/Bukkit.java
@@ -55,6 +55,7 @@ import org.bukkit.util.CachedServerIcon;
diff --git a/patches/api/0194-Expose-game-version.patch b/patches/api/0194-Expose-game-version.patch
index dcec8271d6..c2cef85ee5 100644
--- a/patches/api/0194-Expose-game-version.patch
+++ b/patches/api/0194-Expose-game-version.patch
@@ -5,7 +5,7 @@ Subject: [PATCH] Expose game version
diff --git a/src/main/java/org/bukkit/Bukkit.java b/src/main/java/org/bukkit/Bukkit.java
-index 39fdcada6aa98058491aa6b5e5b9943c8a57a59d..e1a9a0ec6036133aa8fb195d22611df221bf5661 100644
+index 725de23dc102e3b63da5e49bb1eafca96e33fc4c..dfeaddc2d71f8569c349740c00c96868f9a56a12 100644
--- a/src/main/java/org/bukkit/Bukkit.java
+++ b/src/main/java/org/bukkit/Bukkit.java
@@ -156,6 +156,18 @@ public final class Bukkit {
@@ -28,7 +28,7 @@ index 39fdcada6aa98058491aa6b5e5b9943c8a57a59d..e1a9a0ec6036133aa8fb195d22611df2
* Gets a view of all currently logged in players. This {@linkplain
* Collections#unmodifiableCollection(Collection) view} is a reused
diff --git a/src/main/java/org/bukkit/Server.java b/src/main/java/org/bukkit/Server.java
-index 65daa359f000cf1acc3067af62e3210ced378519..357f59f07387d3de75a0792e7e883cb82aafa2e2 100644
+index 960fc19a04bc3475bd81301ec283c9bb32f62821..ccec37c00f8ab318d41350907b40a64118e4fab1 100644
--- a/src/main/java/org/bukkit/Server.java
+++ b/src/main/java/org/bukkit/Server.java
@@ -114,6 +114,16 @@ public interface Server extends PluginMessageRecipient, net.kyori.adventure.audi
diff --git a/patches/server/0001-Setup-Gradle-project.patch b/patches/server/0001-Setup-Gradle-project.patch
index c5a9d523e5..a98810c6eb 100644
--- a/patches/server/0001-Setup-Gradle-project.patch
+++ b/patches/server/0001-Setup-Gradle-project.patch
@@ -172,7 +172,7 @@ index 0000000000000000000000000000000000000000..9a355bbbe57629d0b66f8260ecf461e3
+}
diff --git a/pom.xml b/pom.xml
deleted file mode 100644
-index 53123c08cf84a56fdc21929f3006829ea362a31c..0000000000000000000000000000000000000000
+index ccb57a056138549ec39ddaef2f09590b1fddd127..0000000000000000000000000000000000000000
--- a/pom.xml
+++ /dev/null
@@ -1,587 +0,0 @@
@@ -182,7 +182,7 @@ index 53123c08cf84a56fdc21929f3006829ea362a31c..00000000000000000000000000000000
- org.spigotmc
- spigot
- jar
-- 1.20-R0.1-SNAPSHOT
+- 1.20.1-R0.1-SNAPSHOT
- Spigot
- https://www.spigotmc.org/
-
diff --git a/patches/server/0003-Build-system-changes.patch b/patches/server/0003-Build-system-changes.patch
index b8086f8648..b1dc518ce6 100644
--- a/patches/server/0003-Build-system-changes.patch
+++ b/patches/server/0003-Build-system-changes.patch
@@ -5,7 +5,7 @@ Subject: [PATCH] Build system changes
diff --git a/build.gradle.kts b/build.gradle.kts
-index ca692b4758172cb139938f28457cf5639a4411cf..592d2cd1114ee9fbf7b16068ef729f7db4de83d1 100644
+index 9a355bbbe57629d0b66f8260ecf461e3bf1a539b..8a8467bef44269e4c831a81fc0dc852b44c8f6cb 100644
--- a/build.gradle.kts
+++ b/build.gradle.kts
@@ -9,10 +9,9 @@ plugins {
diff --git a/patches/server/0004-Test-changes.patch b/patches/server/0004-Test-changes.patch
index c5fd94f438..8cf786ee53 100644
--- a/patches/server/0004-Test-changes.patch
+++ b/patches/server/0004-Test-changes.patch
@@ -5,7 +5,7 @@ Subject: [PATCH] Test changes
diff --git a/build.gradle.kts b/build.gradle.kts
-index 592d2cd1114ee9fbf7b16068ef729f7db4de83d1..f3f20b34a3ebcbb75004003892e903ee4fd0edd3 100644
+index 8a8467bef44269e4c831a81fc0dc852b44c8f6cb..952dde5d0d9fa6bcf97ae5cafe482cca1f5b3a78 100644
--- a/build.gradle.kts
+++ b/build.gradle.kts
@@ -12,6 +12,7 @@ dependencies {
diff --git a/patches/server/0009-MC-Utils.patch b/patches/server/0009-MC-Utils.patch
index 27baee9eca..f5174018a6 100644
--- a/patches/server/0009-MC-Utils.patch
+++ b/patches/server/0009-MC-Utils.patch
@@ -7612,7 +7612,7 @@ index 0000000000000000000000000000000000000000..909b2c98e7a9117d2f737245e4661792
+ }
+}
diff --git a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
-index 9026e98b6b03de7a51e853d6ca4a3d20584740d4..fee5c6809ea3d4ebe1b17fb8da580f3b058d7363 100644
+index afde61e784dada8df1f34bd15b1d3b71e842bb52..6deffd223ff995d83244e941576f8286e1171c1f 100644
--- a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
+++ b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
@@ -104,8 +104,17 @@ public final class CraftMagicNumbers implements UnsafeValues {
diff --git a/patches/server/0010-Adventure.patch b/patches/server/0010-Adventure.patch
index c1a071f638..a7d32a2301 100644
--- a/patches/server/0010-Adventure.patch
+++ b/patches/server/0010-Adventure.patch
@@ -4915,7 +4915,7 @@ index 78ea79b66cc9e90402ef5cdc2e5e04e0c74b1c26..4fede2161792ba3e7cdf0cc5a1f53318
boolean hadFormat = false;
diff --git a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
-index fee5c6809ea3d4ebe1b17fb8da580f3b058d7363..a3cb26b4ba108b3c621f74034480a522492fdf2f 100644
+index 6deffd223ff995d83244e941576f8286e1171c1f..412dce72064533a260db591a94c8b39eb498331d 100644
--- a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
+++ b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
@@ -74,6 +74,43 @@ public final class CraftMagicNumbers implements UnsafeValues {
diff --git a/patches/server/0013-Paper-Plugins.patch b/patches/server/0013-Paper-Plugins.patch
index f2fac081cc..a3ec0d2db5 100644
--- a/patches/server/0013-Paper-Plugins.patch
+++ b/patches/server/0013-Paper-Plugins.patch
@@ -7062,7 +7062,7 @@ index 909b2c98e7a9117d2f737245e4661792ffafb744..d96399e9bf1a58db5a4a22e58abb99e7
@Override
public FileConfiguration getConfig() {
diff --git a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
-index a3cb26b4ba108b3c621f74034480a522492fdf2f..23d594d7e24389e99f7c589d4cd7d6f3987d42c4 100644
+index 412dce72064533a260db591a94c8b39eb498331d..0d5202f6bc14bc0cec77f86bed2f1f590e0fffeb 100644
--- a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
+++ b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
@@ -437,6 +437,12 @@ public final class CraftMagicNumbers implements UnsafeValues {
diff --git a/patches/server/0014-Timings-v2.patch b/patches/server/0014-Timings-v2.patch
index ac01109fe4..26fed824bc 100644
--- a/patches/server/0014-Timings-v2.patch
+++ b/patches/server/0014-Timings-v2.patch
@@ -2046,7 +2046,7 @@ index f97eccb6a17c7876e1e002d798eb67bbe80571a0..76effc345d362047e64d064eb64a5222
+ } // Paper
}
diff --git a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
-index 23d594d7e24389e99f7c589d4cd7d6f3987d42c4..fda157258a5c96c8ef82dbad31b3a3da257f2fd2 100644
+index 0d5202f6bc14bc0cec77f86bed2f1f590e0fffeb..3a7a498003d70cf9e31acffee70b23dec0be6845 100644
--- a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
+++ b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
@@ -224,6 +224,12 @@ public final class CraftMagicNumbers implements UnsafeValues {
diff --git a/patches/server/0016-Starlight.patch b/patches/server/0016-Starlight.patch
index f36edc5066..5f43306bab 100644
--- a/patches/server/0016-Starlight.patch
+++ b/patches/server/0016-Starlight.patch
@@ -4917,10 +4917,10 @@ index e5e562f75e7d4b6a750f192842940c5e3af81e7d..2caac1a3d80e6c490aa16aa6bc106706
public ChunkAccess(ChunkPos pos, UpgradeData upgradeData, LevelHeightAccessor heightLimitView, Registry biomeRegistry, long inhabitedTime, @Nullable LevelChunkSection[] sectionArray, @Nullable BlendingData blendingData) {
this.locX = pos.x; this.locZ = pos.z; // Paper - reduce need for field lookups
diff --git a/src/main/java/net/minecraft/world/level/chunk/ChunkStatus.java b/src/main/java/net/minecraft/world/level/chunk/ChunkStatus.java
-index 70a05fe758565131bbb39c18d6b674a6368ffa45..fb5a06a908d2b42bf0530b62ed648548499d9f87 100644
+index d5b1fd0ff3f64675f90dd9f7f328a106e0992d51..846ae3fd184a1d63b743aa25e045604576697c96 100644
--- a/src/main/java/net/minecraft/world/level/chunk/ChunkStatus.java
+++ b/src/main/java/net/minecraft/world/level/chunk/ChunkStatus.java
-@@ -258,6 +258,17 @@ public class ChunkStatus {
+@@ -260,6 +260,17 @@ public class ChunkStatus {
return this.chunkType;
}
diff --git a/patches/server/0019-Rewrite-chunk-system.patch b/patches/server/0019-Rewrite-chunk-system.patch
index 68ccf237b6..4cc9430916 100644
--- a/patches/server/0019-Rewrite-chunk-system.patch
+++ b/patches/server/0019-Rewrite-chunk-system.patch
@@ -16719,12 +16719,12 @@ index 0000000000000000000000000000000000000000..ce449b7b6f615f2c8240e4207f06d4e5
+ }
+}
diff --git a/src/main/java/net/minecraft/network/Connection.java b/src/main/java/net/minecraft/network/Connection.java
-index 3ab557277cff7c8a43b0f3de45d17f2bf78f7747..c457bdcb93fa306a2d67b31c0abb53465d809862 100644
+index 047b07c7443c0d6a403506b869d63806ec2a85f7..18092ddfd000ef36f0e182ac064c2f667b1e611b 100644
--- a/src/main/java/net/minecraft/network/Connection.java
+++ b/src/main/java/net/minecraft/network/Connection.java
-@@ -92,6 +92,28 @@ public class Connection extends SimpleChannelInboundHandler> {
- private int tickCount;
- private boolean handlingFault;
+@@ -94,6 +94,28 @@ public class Connection extends SimpleChannelInboundHandler> {
+ @Nullable
+ private volatile Component delayedDisconnect;
public String hostname = ""; // CraftBukkit - add field
+ // Paper start - add pending task queue
+ private final Queue pendingTasks = new java.util.concurrent.ConcurrentLinkedQueue<>();
@@ -16751,7 +16751,7 @@ index 3ab557277cff7c8a43b0f3de45d17f2bf78f7747..c457bdcb93fa306a2d67b31c0abb5346
public Connection(PacketFlow side) {
this.receiving = side;
-@@ -255,6 +277,7 @@ public class Connection extends SimpleChannelInboundHandler> {
+@@ -261,6 +283,7 @@ public class Connection extends SimpleChannelInboundHandler> {
}
private void flushQueue() {
@@ -16759,7 +16759,7 @@ index 3ab557277cff7c8a43b0f3de45d17f2bf78f7747..c457bdcb93fa306a2d67b31c0abb5346
if (this.channel != null && this.channel.isOpen()) {
Queue queue = this.queue;
-@@ -267,6 +290,12 @@ public class Connection extends SimpleChannelInboundHandler> {
+@@ -273,6 +296,12 @@ public class Connection extends SimpleChannelInboundHandler> {
}
}
@@ -21228,7 +21228,7 @@ index f739a175e26f250c652c73b8985158fe37c2823a..5f4fa76fe3a1a0a4fc11064fcf57bfab
structurestart = structureAccessor.getStartForStructure(SectionPos.bottomOf(ichunkaccess), (Structure) holder.value(), ichunkaccess);
} while (structurestart == null);
diff --git a/src/main/java/net/minecraft/world/level/chunk/ChunkStatus.java b/src/main/java/net/minecraft/world/level/chunk/ChunkStatus.java
-index fb5a06a908d2b42bf0530b62ed648548499d9f87..ec55711e912fe6cb8f797c0b21bcef273966a47a 100644
+index 846ae3fd184a1d63b743aa25e045604576697c96..a907b79fd8291a0e92db138f37239d17424188a1 100644
--- a/src/main/java/net/minecraft/world/level/chunk/ChunkStatus.java
+++ b/src/main/java/net/minecraft/world/level/chunk/ChunkStatus.java
@@ -30,6 +30,30 @@ import net.minecraft.world.level.levelgen.structure.templatesystem.StructureTemp
diff --git a/patches/server/0028-Implement-Paper-VersionChecker.patch b/patches/server/0028-Implement-Paper-VersionChecker.patch
index e72b095594..739cfaf126 100644
--- a/patches/server/0028-Implement-Paper-VersionChecker.patch
+++ b/patches/server/0028-Implement-Paper-VersionChecker.patch
@@ -140,7 +140,7 @@ index 0000000000000000000000000000000000000000..22a55be34fde453fedd987173d95b8b3
+ }
+}
diff --git a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
-index fda157258a5c96c8ef82dbad31b3a3da257f2fd2..e608b7542f6de7b3f2d7af25bb28f2705f6a9688 100644
+index 3a7a498003d70cf9e31acffee70b23dec0be6845..bf8cb65df8e6ecc76e065625e89fd296d71b15b4 100644
--- a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
+++ b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
@@ -461,6 +461,11 @@ public final class CraftMagicNumbers implements UnsafeValues {
diff --git a/patches/server/0035-Configurable-top-of-nether-void-damage.patch b/patches/server/0035-Configurable-top-of-nether-void-damage.patch
index 829398b2a2..f51f189908 100644
--- a/patches/server/0035-Configurable-top-of-nether-void-damage.patch
+++ b/patches/server/0035-Configurable-top-of-nether-void-damage.patch
@@ -6,7 +6,7 @@ Subject: [PATCH] Configurable top of nether void damage
Co-authored-by: Jake Potrebic
diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
-index c0d19d31aece8abab310b4c7bffa2ffe7a8ac845..d20722a79aa87cae72b1b3b9039d342c9ff9570a 100644
+index b3e239df3528d149bf950a2c8a64df3444b0e013..b20b25f3271e7f7a6f3b128b8b85331362acd2ac 100644
--- a/src/main/java/net/minecraft/world/entity/Entity.java
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
@@ -715,7 +715,11 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource {
diff --git a/patches/server/0037-Always-tick-falling-blocks.patch b/patches/server/0037-Always-tick-falling-blocks.patch
index ff78994090..2e80c8ca6a 100644
--- a/patches/server/0037-Always-tick-falling-blocks.patch
+++ b/patches/server/0037-Always-tick-falling-blocks.patch
@@ -5,7 +5,7 @@ Subject: [PATCH] Always tick falling blocks
diff --git a/src/main/java/org/spigotmc/ActivationRange.java b/src/main/java/org/spigotmc/ActivationRange.java
-index b47b740186c200c420dcb4d1537a93c743a887c1..a526816f261de2a75a04be82596a7d8d674ead4a 100644
+index 6606a118e7bff01aa51440aea7540ec9feec6cc5..1d9ce6dae17ff572d4528971c69c63d0f85b313c 100644
--- a/src/main/java/org/spigotmc/ActivationRange.java
+++ b/src/main/java/org/spigotmc/ActivationRange.java
@@ -89,6 +89,7 @@ public class ActivationRange
diff --git a/patches/server/0038-Configurable-end-credits.patch b/patches/server/0038-Configurable-end-credits.patch
index 292210bb6d..eccadb5d8a 100644
--- a/patches/server/0038-Configurable-end-credits.patch
+++ b/patches/server/0038-Configurable-end-credits.patch
@@ -5,7 +5,7 @@ Subject: [PATCH] Configurable end credits
diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java
-index 32ef9f1ae0c35e927133572ebb6fbf50b0729a63..e42c07dfba3c18464f1f8e35fbd764812d8c4e50 100644
+index 172ea32dfc93b2a2f28b5cdd520c07f8a04f2665..1ef48b8415242942f00c6a76faa1de2865e11358 100644
--- a/src/main/java/net/minecraft/server/level/ServerPlayer.java
+++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java
@@ -1066,6 +1066,7 @@ public class ServerPlayer extends Player {
diff --git a/patches/server/0044-Configurable-mob-spawner-tick-rate.patch b/patches/server/0044-Configurable-mob-spawner-tick-rate.patch
index 128b5274ef..30b29b9251 100644
--- a/patches/server/0044-Configurable-mob-spawner-tick-rate.patch
+++ b/patches/server/0044-Configurable-mob-spawner-tick-rate.patch
@@ -5,7 +5,7 @@ Subject: [PATCH] Configurable mob spawner tick rate
diff --git a/src/main/java/net/minecraft/world/level/BaseSpawner.java b/src/main/java/net/minecraft/world/level/BaseSpawner.java
-index 213fed3a2b32226fc128d213ee3e9fa3ae76e88e..64bd7d265a45575ce46c1a792f90cadc76763871 100644
+index 124703a7c043b6c3b651fa1a81c5ba3e99e47938..7ae0465091db8e8061737bf93884afa3db49feeb 100644
--- a/src/main/java/net/minecraft/world/level/BaseSpawner.java
+++ b/src/main/java/net/minecraft/world/level/BaseSpawner.java
@@ -45,6 +45,7 @@ public abstract class BaseSpawner {
diff --git a/patches/server/0047-Configurable-container-update-tick-rate.patch b/patches/server/0047-Configurable-container-update-tick-rate.patch
index 5d4f79d3b0..e2bf354a38 100644
--- a/patches/server/0047-Configurable-container-update-tick-rate.patch
+++ b/patches/server/0047-Configurable-container-update-tick-rate.patch
@@ -5,7 +5,7 @@ Subject: [PATCH] Configurable container update tick rate
diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java
-index ee422a97a63749172f9f9643513ae9ab111c2400..321d14f241df1246061ba73b2488f5ab5326a734 100644
+index bcf0d4cfbfbae254bc74ad6389af372a8aa319be..b4ea4c63a6cd767684d6c3c68a192a90c82d2e91 100644
--- a/src/main/java/net/minecraft/server/level/ServerPlayer.java
+++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java
@@ -241,6 +241,7 @@ public class ServerPlayer extends Player {
diff --git a/patches/server/0050-Add-PlayerInitialSpawnEvent.patch b/patches/server/0050-Add-PlayerInitialSpawnEvent.patch
index d4862e9492..99d9a71065 100644
--- a/patches/server/0050-Add-PlayerInitialSpawnEvent.patch
+++ b/patches/server/0050-Add-PlayerInitialSpawnEvent.patch
@@ -12,7 +12,7 @@ improve setPosition to use raw
public net.minecraft.world.entity.Entity setRot(FF)V
diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java
-index 0363ad83af48ddcec37b5bd2fee49c3b1350576c..d9c45fb7a97797de2af2811f816110cc6c3681f6 100644
+index b40ddd8fb3e2d2bafaa2ece46714815d0d6d5f75..9e835d63e1592fc064b73c51eecd8b84cbedfa33 100644
--- a/src/main/java/net/minecraft/server/players/PlayerList.java
+++ b/src/main/java/net/minecraft/server/players/PlayerList.java
@@ -240,7 +240,7 @@ public abstract class PlayerList {
diff --git a/patches/server/0057-Add-configurable-portal-search-radius.patch b/patches/server/0057-Add-configurable-portal-search-radius.patch
index 74e39c8fd3..bd0d2ee1d3 100644
--- a/patches/server/0057-Add-configurable-portal-search-radius.patch
+++ b/patches/server/0057-Add-configurable-portal-search-radius.patch
@@ -5,7 +5,7 @@ Subject: [PATCH] Add configurable portal search radius
diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
-index d20722a79aa87cae72b1b3b9039d342c9ff9570a..faf60cc9c4a3bfd7c30b07bb1b3fbabaaffd1d6d 100644
+index b20b25f3271e7f7a6f3b128b8b85331362acd2ac..856f858c2e63e8a10d4b10826db72a95c24b1b6d 100644
--- a/src/main/java/net/minecraft/world/entity/Entity.java
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
@@ -3174,7 +3174,13 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource {
diff --git a/patches/server/0062-Disable-Scoreboards-for-non-players-by-default.patch b/patches/server/0062-Disable-Scoreboards-for-non-players-by-default.patch
index 0fd0480405..992265ec32 100644
--- a/patches/server/0062-Disable-Scoreboards-for-non-players-by-default.patch
+++ b/patches/server/0062-Disable-Scoreboards-for-non-players-by-default.patch
@@ -11,7 +11,7 @@ So avoid looking up scoreboards and short circuit to the "not on a team"
logic which is most likely to be true.
diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
-index faf60cc9c4a3bfd7c30b07bb1b3fbabaaffd1d6d..47369a5cdf37872fa91daf6425f7cfacbbdeec69 100644
+index 856f858c2e63e8a10d4b10826db72a95c24b1b6d..9239f184f51f23a6f6373e018f9f00f05fdc92ea 100644
--- a/src/main/java/net/minecraft/world/entity/Entity.java
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
@@ -2805,6 +2805,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource {
diff --git a/patches/server/0074-Use-a-Shared-Random-for-Entities.patch b/patches/server/0074-Use-a-Shared-Random-for-Entities.patch
index 59b330e61a..6ed52a86c2 100644
--- a/patches/server/0074-Use-a-Shared-Random-for-Entities.patch
+++ b/patches/server/0074-Use-a-Shared-Random-for-Entities.patch
@@ -6,7 +6,7 @@ Subject: [PATCH] Use a Shared Random for Entities
Reduces memory usage and provides ensures more randomness, Especially since a lot of garbage entity objects get created.
diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
-index 47369a5cdf37872fa91daf6425f7cfacbbdeec69..713052e936d75173cd038b0565d94f9ff451168f 100644
+index 9239f184f51f23a6f6373e018f9f00f05fdc92ea..9fadfb41a41b575aa1ca1c28e34118708eded498 100644
--- a/src/main/java/net/minecraft/world/entity/Entity.java
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
@@ -162,6 +162,79 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource {
diff --git a/patches/server/0095-LootTable-API-Replenishable-Lootables-Feature.patch b/patches/server/0095-LootTable-API-Replenishable-Lootables-Feature.patch
index 510f514f04..cda572decc 100644
--- a/patches/server/0095-LootTable-API-Replenishable-Lootables-Feature.patch
+++ b/patches/server/0095-LootTable-API-Replenishable-Lootables-Feature.patch
@@ -490,7 +490,7 @@ index 0000000000000000000000000000000000000000..9cfa5d36a6991067a3866e0d437749fa
+ }
+}
diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
-index 713052e936d75173cd038b0565d94f9ff451168f..b7b7500c580548fcdcfa2ba36137abf45b43ddf9 100644
+index 9fadfb41a41b575aa1ca1c28e34118708eded498..fbd28a3f571766e6ed4ba73f337b2e835ef50453 100644
--- a/src/main/java/net/minecraft/world/entity/Entity.java
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
@@ -235,6 +235,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource {
diff --git a/patches/server/0108-Configurable-flying-kick-messages.patch b/patches/server/0108-Configurable-flying-kick-messages.patch
index a7a46a8d7b..3af4d087e4 100644
--- a/patches/server/0108-Configurable-flying-kick-messages.patch
+++ b/patches/server/0108-Configurable-flying-kick-messages.patch
@@ -5,7 +5,7 @@ Subject: [PATCH] Configurable flying kick messages
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
-index 3ac549815895e6cbb43cbfc04377337f8b7ebd43..c33b94701a8c4f3198671405d32467d9645bf87f 100644
+index 7c48f10be178186886a2f497c162c87c35369053..949b192a2b25920fcc6fc8192685f2c6bca64fda 100644
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
@@ -355,7 +355,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic
diff --git a/patches/server/0125-Enforce-Sync-Player-Saves.patch b/patches/server/0125-Enforce-Sync-Player-Saves.patch
index ec18713f40..d19cbd3de8 100644
--- a/patches/server/0125-Enforce-Sync-Player-Saves.patch
+++ b/patches/server/0125-Enforce-Sync-Player-Saves.patch
@@ -7,7 +7,7 @@ Saving players async is extremely dangerous. This will force it to main
the same way we handle async chunk loads.
diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java
-index 66b1a4593f9c96dbf7e098411f89dbacd6baf4ba..0eceacb8b58339820a515c59d978239bc5be0731 100644
+index 7901a8e3659be05d901fd5140e025392ffa0c27c..cf110171ba47051eab94c0195eb155b685a25dca 100644
--- a/src/main/java/net/minecraft/server/players/PlayerList.java
+++ b/src/main/java/net/minecraft/server/players/PlayerList.java
@@ -1069,11 +1069,13 @@ public abstract class PlayerList {
diff --git a/patches/server/0126-Don-t-allow-entities-to-ride-themselves-572.patch b/patches/server/0126-Don-t-allow-entities-to-ride-themselves-572.patch
index 9e87843997..4301ca360c 100644
--- a/patches/server/0126-Don-t-allow-entities-to-ride-themselves-572.patch
+++ b/patches/server/0126-Don-t-allow-entities-to-ride-themselves-572.patch
@@ -5,7 +5,7 @@ Subject: [PATCH] Don't allow entities to ride themselves - #572
diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
-index b7b7500c580548fcdcfa2ba36137abf45b43ddf9..1546c13dd185ac10d573873d68658193fe110fb7 100644
+index fbd28a3f571766e6ed4ba73f337b2e835ef50453..293f6c0be399419560f45bf6c834220f123b3c24 100644
--- a/src/main/java/net/minecraft/world/entity/Entity.java
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
@@ -2537,6 +2537,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource {
diff --git a/patches/server/0128-Cap-Entity-Collisions.patch b/patches/server/0128-Cap-Entity-Collisions.patch
index 5f80b9e089..c60e51a4a8 100644
--- a/patches/server/0128-Cap-Entity-Collisions.patch
+++ b/patches/server/0128-Cap-Entity-Collisions.patch
@@ -12,7 +12,7 @@ just as it does in Vanilla, but entity pushing logic will be capped.
You can set this to 0 to disable collisions.
diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
-index 1546c13dd185ac10d573873d68658193fe110fb7..5c616afddc9a0403787fd2ea2467220d81253541 100644
+index 293f6c0be399419560f45bf6c834220f123b3c24..875516b17452968e53efda9d777676ec4bee0f79 100644
--- a/src/main/java/net/minecraft/world/entity/Entity.java
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
@@ -387,6 +387,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource {
diff --git a/patches/server/0139-Do-not-submit-profile-lookups-to-worldgen-threads.patch b/patches/server/0139-Do-not-submit-profile-lookups-to-worldgen-threads.patch
index c382a8f740..20757105e9 100644
--- a/patches/server/0139-Do-not-submit-profile-lookups-to-worldgen-threads.patch
+++ b/patches/server/0139-Do-not-submit-profile-lookups-to-worldgen-threads.patch
@@ -63,7 +63,7 @@ index 24ed280a31a10c822cb8b2d2e9bf43ad81d92924..a2fc2c0437999dd09f080eafe8ea466b
Property property = Iterables.getFirst(profilex.getProperties().get("textures"), (Property)null);
if (property == null) {
diff --git a/src/main/java/org/bukkit/craftbukkit/profile/CraftPlayerProfile.java b/src/main/java/org/bukkit/craftbukkit/profile/CraftPlayerProfile.java
-index 3030c153725415802f68c144e0b577d919307058..3e40d47f504248cd7caeef6b841a8aa6f1976170 100644
+index aa4760ae56d3ba16779d1b04301f0fd75527f9ec..2375b0bac17dd73d6ee12a94b9e4a4143a2e1c65 100644
--- a/src/main/java/org/bukkit/craftbukkit/profile/CraftPlayerProfile.java
+++ b/src/main/java/org/bukkit/craftbukkit/profile/CraftPlayerProfile.java
@@ -121,7 +121,7 @@ public final class CraftPlayerProfile implements PlayerProfile {
diff --git a/patches/server/0149-ProfileWhitelistVerifyEvent.patch b/patches/server/0149-ProfileWhitelistVerifyEvent.patch
index 24204b1026..cfe284e035 100644
--- a/patches/server/0149-ProfileWhitelistVerifyEvent.patch
+++ b/patches/server/0149-ProfileWhitelistVerifyEvent.patch
@@ -5,7 +5,7 @@ Subject: [PATCH] ProfileWhitelistVerifyEvent
diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java
-index 03ea44619bc3445956f3e4539fc0e2923a29a92d..493099d1a1df085ec909ed6cd65a250c24f28bd1 100644
+index 82db70c548336ada2af556251b8ae8d189417024..875b08503fbbac256fad1b3f3d9c742bf1cdced2 100644
--- a/src/main/java/net/minecraft/server/players/PlayerList.java
+++ b/src/main/java/net/minecraft/server/players/PlayerList.java
@@ -646,9 +646,9 @@ public abstract class PlayerList {
diff --git a/patches/server/0155-Handle-plugin-prefixes-using-Log4J-configuration.patch b/patches/server/0155-Handle-plugin-prefixes-using-Log4J-configuration.patch
index f502abb948..ed8fc4f190 100644
--- a/patches/server/0155-Handle-plugin-prefixes-using-Log4J-configuration.patch
+++ b/patches/server/0155-Handle-plugin-prefixes-using-Log4J-configuration.patch
@@ -15,7 +15,7 @@ This may cause additional prefixes to be disabled for plugins bypassing
the plugin logger.
diff --git a/build.gradle.kts b/build.gradle.kts
-index 700be2fdc10d14222f06e482681bb3a2e9a0aee6..5524d44f8b97480bce3ed5ec7e154aae1fb13a2d 100644
+index 3a72c4b2f5f2404518bb606c148a431d98f0b5f4..bfa7e0cb164bdf31b5f54945c6b4345379cfc747 100644
--- a/build.gradle.kts
+++ b/build.gradle.kts
@@ -18,7 +18,7 @@ dependencies {
diff --git a/patches/server/0157-Add-PlayerJumpEvent.patch b/patches/server/0157-Add-PlayerJumpEvent.patch
index fc9a3cd8b7..97996bef18 100644
--- a/patches/server/0157-Add-PlayerJumpEvent.patch
+++ b/patches/server/0157-Add-PlayerJumpEvent.patch
@@ -5,7 +5,7 @@ Subject: [PATCH] Add PlayerJumpEvent
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
-index 054776624f6df25b69d1e3c480e8b7effbb592a7..6928d2fb7493206ab84bedc39434285f45d9dc38 100644
+index 316607ca41ee4973c8dbc1ea806b18dff483bbff..38227e58773a4e47b2bd71daec7ce479892a19f3 100644
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
@@ -1292,7 +1292,34 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic
diff --git a/patches/server/0159-Expose-client-protocol-version-and-virtual-host.patch b/patches/server/0159-Expose-client-protocol-version-and-virtual-host.patch
index 1e8e7329f9..2441430b36 100644
--- a/patches/server/0159-Expose-client-protocol-version-and-virtual-host.patch
+++ b/patches/server/0159-Expose-client-protocol-version-and-virtual-host.patch
@@ -60,10 +60,10 @@ index 0000000000000000000000000000000000000000..a5a7624f1f372a26b982836cd31cff15
+
+}
diff --git a/src/main/java/net/minecraft/network/Connection.java b/src/main/java/net/minecraft/network/Connection.java
-index c457bdcb93fa306a2d67b31c0abb53465d809862..c8e34e4f1519163fcac77606fe20c2ec9a282901 100644
+index 18092ddfd000ef36f0e182ac064c2f667b1e611b..f2c5764a447d0895e90a5aa73ee28a9feb453483 100644
--- a/src/main/java/net/minecraft/network/Connection.java
+++ b/src/main/java/net/minecraft/network/Connection.java
-@@ -114,6 +114,10 @@ public class Connection extends SimpleChannelInboundHandler> {
+@@ -116,6 +116,10 @@ public class Connection extends SimpleChannelInboundHandler> {
}
}
// Paper end - add pending task queue
diff --git a/patches/server/0160-revert-serverside-behavior-of-keepalives.patch b/patches/server/0160-revert-serverside-behavior-of-keepalives.patch
index 93fbdc15ca..4b7d49de52 100644
--- a/patches/server/0160-revert-serverside-behavior-of-keepalives.patch
+++ b/patches/server/0160-revert-serverside-behavior-of-keepalives.patch
@@ -17,7 +17,7 @@ from networking or during connections flood of chunk packets on slower clients,
at the cost of dead connections being kept open for longer.
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
-index 95256c095626f429315b80df86876b18112989bc..575ecae47633e7a30c8bca57d686dcfc0b31a0df 100644
+index cb8b31c34fe4d3ee6f383ff9d32cf13552879332..b4c0e41b1d6e6c9411e1bbf6af07533b8dbb68f7 100644
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
@@ -259,7 +259,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic
diff --git a/patches/server/0170-PlayerNaturallySpawnCreaturesEvent.patch b/patches/server/0170-PlayerNaturallySpawnCreaturesEvent.patch
index 3ca5021685..5a63f111ca 100644
--- a/patches/server/0170-PlayerNaturallySpawnCreaturesEvent.patch
+++ b/patches/server/0170-PlayerNaturallySpawnCreaturesEvent.patch
@@ -60,7 +60,7 @@ index b0687dcf8af84af627b67e7fbb68170a2fd28da0..5cb151a7d89c7281b03f24c5f79afb7e
while (iterator1.hasNext()) {
diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java
-index 0cb86afa3732eaf04dd6369d7499bd628df7e12f..8b5b66c8f55660085ff3af824b8bf0c455be79bc 100644
+index 6051ad00973c80ad3478e2ff9063c268489f358b..dda3b911fcaa294ec7b8e9d696880fcb8325f69c 100644
--- a/src/main/java/net/minecraft/server/level/ServerPlayer.java
+++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java
@@ -1,5 +1,6 @@
diff --git a/patches/server/0172-PreCreatureSpawnEvent.patch b/patches/server/0172-PreCreatureSpawnEvent.patch
index e211931fe7..4da8e04bb8 100644
--- a/patches/server/0172-PreCreatureSpawnEvent.patch
+++ b/patches/server/0172-PreCreatureSpawnEvent.patch
@@ -97,7 +97,7 @@ index 68594d2621267f4b112b4d14d2bec3a0dd6a044a..73a5750dd47cf8869070f92594cfb926
}
}
diff --git a/src/main/java/net/minecraft/world/level/BaseSpawner.java b/src/main/java/net/minecraft/world/level/BaseSpawner.java
-index 8540905242fc84ab8a26cf0a8e875ef252bc3d5d..3294e5b5ed0288af08067c36ca34514d02d200d3 100644
+index 20c39481bcf05e0d43c97b7e841ec9f5f6a0d45d..fc7719d12b5f6011aec2e41a36b4bacd77672b6d 100644
--- a/src/main/java/net/minecraft/world/level/BaseSpawner.java
+++ b/src/main/java/net/minecraft/world/level/BaseSpawner.java
@@ -128,6 +128,27 @@ public abstract class BaseSpawner {
diff --git a/patches/server/0179-Disable-Explicit-Network-Manager-Flushing.patch b/patches/server/0179-Disable-Explicit-Network-Manager-Flushing.patch
index b69e3f67f6..0c92845887 100644
--- a/patches/server/0179-Disable-Explicit-Network-Manager-Flushing.patch
+++ b/patches/server/0179-Disable-Explicit-Network-Manager-Flushing.patch
@@ -12,10 +12,10 @@ flushing on the netty event loop, so it won't do the flush on the main thread.
Renable flushing by passing -Dpaper.explicit-flush=true
diff --git a/src/main/java/net/minecraft/network/Connection.java b/src/main/java/net/minecraft/network/Connection.java
-index c8e34e4f1519163fcac77606fe20c2ec9a282901..39b1d17cfb7d5c1b0f0ee449ee1c24ef050b0c0e 100644
+index f2c5764a447d0895e90a5aa73ee28a9feb453483..7065d8e2b0782f1dbaf9932db9201b94ae455a31 100644
--- a/src/main/java/net/minecraft/network/Connection.java
+++ b/src/main/java/net/minecraft/network/Connection.java
-@@ -117,6 +117,7 @@ public class Connection extends SimpleChannelInboundHandler> {
+@@ -119,6 +119,7 @@ public class Connection extends SimpleChannelInboundHandler> {
// Paper start - NetworkClient implementation
public int protocolVersion;
public java.net.InetSocketAddress virtualHost;
@@ -23,7 +23,7 @@ index c8e34e4f1519163fcac77606fe20c2ec9a282901..39b1d17cfb7d5c1b0f0ee449ee1c24ef
// Paper end
public Connection(PacketFlow side) {
-@@ -317,7 +318,7 @@ public class Connection extends SimpleChannelInboundHandler> {
+@@ -323,7 +324,7 @@ public class Connection extends SimpleChannelInboundHandler> {
}
if (this.channel != null) {
diff --git a/patches/server/0190-EndermanEscapeEvent.patch b/patches/server/0190-EndermanEscapeEvent.patch
index a70e6c8bb2..cb976a660c 100644
--- a/patches/server/0190-EndermanEscapeEvent.patch
+++ b/patches/server/0190-EndermanEscapeEvent.patch
@@ -8,7 +8,7 @@ Fires an event anytime an enderman intends to teleport away from the player
You may cancel this, enabling ranged attacks to damage the enderman for example.
diff --git a/src/main/java/net/minecraft/world/entity/monster/EnderMan.java b/src/main/java/net/minecraft/world/entity/monster/EnderMan.java
-index 045f9d569305786b882db915e431cb45f6aa3375..9df51c1108f4e9a3d8391783b7394286d6e1eb24 100644
+index 90f8d659893736a40051e485473695d45ed5b35d..0e16d223bc81cad120056a92979ef14ecc899c48 100644
--- a/src/main/java/net/minecraft/world/entity/monster/EnderMan.java
+++ b/src/main/java/net/minecraft/world/entity/monster/EnderMan.java
@@ -118,6 +118,12 @@ public class EnderMan extends Monster implements NeutralMob {
diff --git a/patches/server/0191-Enderman.teleportRandomly.patch b/patches/server/0191-Enderman.teleportRandomly.patch
index 2c50d7e636..82b9e32359 100644
--- a/patches/server/0191-Enderman.teleportRandomly.patch
+++ b/patches/server/0191-Enderman.teleportRandomly.patch
@@ -5,19 +5,6 @@ Subject: [PATCH] Enderman.teleportRandomly()
Ability to trigger the vanilla "teleport randomly" mechanic of an enderman.
-diff --git a/src/main/java/net/minecraft/world/entity/monster/EnderMan.java b/src/main/java/net/minecraft/world/entity/monster/EnderMan.java
-index 9df51c1108f4e9a3d8391783b7394286d6e1eb24..67dab95d562f4d1acc2a78bb9d45cba92cb6d38b 100644
---- a/src/main/java/net/minecraft/world/entity/monster/EnderMan.java
-+++ b/src/main/java/net/minecraft/world/entity/monster/EnderMan.java
-@@ -287,7 +287,7 @@ public class EnderMan extends Monster implements NeutralMob {
- super.customServerAiStep();
- }
-
-- protected boolean teleport() {
-+ public boolean teleport() { // Paper - protected->public
- if (!this.level().isClientSide() && this.isAlive()) {
- double d0 = this.getX() + (this.random.nextDouble() - 0.5D) * 64.0D;
- double d1 = this.getY() + (double) (this.random.nextInt(64) - 32);
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftEnderman.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftEnderman.java
index b72d7ade10075a13a617a370e2b8021326c9478d..ae669a970aa1f17ed786640de8a481364543c58e 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftEnderman.java
diff --git a/patches/server/0196-EndermanAttackPlayerEvent.patch b/patches/server/0196-EndermanAttackPlayerEvent.patch
index e8780b4150..c4cea6af64 100644
--- a/patches/server/0196-EndermanAttackPlayerEvent.patch
+++ b/patches/server/0196-EndermanAttackPlayerEvent.patch
@@ -8,7 +8,7 @@ Allow control over whether or not an enderman aggros a player.
This allows you to override/extend the pumpkin/stare logic.
diff --git a/src/main/java/net/minecraft/world/entity/monster/EnderMan.java b/src/main/java/net/minecraft/world/entity/monster/EnderMan.java
-index 67dab95d562f4d1acc2a78bb9d45cba92cb6d38b..acd41b474fadee12c571f390b937f455cbe393ad 100644
+index 0e16d223bc81cad120056a92979ef14ecc899c48..a8b3ae30d48173a699cd0e612df3d4de8a5d53e4 100644
--- a/src/main/java/net/minecraft/world/entity/monster/EnderMan.java
+++ b/src/main/java/net/minecraft/world/entity/monster/EnderMan.java
@@ -230,7 +230,15 @@ public class EnderMan extends Monster implements NeutralMob {
diff --git a/patches/server/0210-Implement-EntityKnockbackByEntityEvent-and-EntityPus.patch b/patches/server/0210-Implement-EntityKnockbackByEntityEvent-and-EntityPus.patch
index bd1c306d4b..39fe4ee4ba 100644
--- a/patches/server/0210-Implement-EntityKnockbackByEntityEvent-and-EntityPus.patch
+++ b/patches/server/0210-Implement-EntityKnockbackByEntityEvent-and-EntityPus.patch
@@ -9,7 +9,7 @@ Co-authored-by: aerulion
This event is called when an entity receives knockback by another entity.
diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
-index 7232c22ca7f0ed995934db3937861e562525e906..05c595c710541c2f4f68a391764fec3cc1fdfd7a 100644
+index 16658764ddced4c8e5af6b9f86ad6e99a2b1adee..de03319757f6174b63b70c076ea8447a06b776c1 100644
--- a/src/main/java/net/minecraft/world/entity/Entity.java
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
@@ -1894,8 +1894,17 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource {
diff --git a/patches/server/0219-Use-AsyncAppender-to-keep-logging-IO-off-main-thread.patch b/patches/server/0219-Use-AsyncAppender-to-keep-logging-IO-off-main-thread.patch
index 4e4cf25665..448b0f8554 100644
--- a/patches/server/0219-Use-AsyncAppender-to-keep-logging-IO-off-main-thread.patch
+++ b/patches/server/0219-Use-AsyncAppender-to-keep-logging-IO-off-main-thread.patch
@@ -5,7 +5,7 @@ Subject: [PATCH] Use AsyncAppender to keep logging IO off main thread
diff --git a/build.gradle.kts b/build.gradle.kts
-index 5524d44f8b97480bce3ed5ec7e154aae1fb13a2d..02f26dd4a4a75ca35a124ab2e6e426e72121f55b 100644
+index bfa7e0cb164bdf31b5f54945c6b4345379cfc747..a00d4f3763929e605bb3ffbbd838e51a77006992 100644
--- a/build.gradle.kts
+++ b/build.gradle.kts
@@ -29,6 +29,7 @@ dependencies {
diff --git a/patches/server/0220-add-more-information-to-Entity.toString.patch b/patches/server/0220-add-more-information-to-Entity.toString.patch
index 12a2609c58..0b06cba95a 100644
--- a/patches/server/0220-add-more-information-to-Entity.toString.patch
+++ b/patches/server/0220-add-more-information-to-Entity.toString.patch
@@ -6,7 +6,7 @@ Subject: [PATCH] add more information to Entity.toString()
UUID, ticks lived, valid, dead
diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
-index 05c595c710541c2f4f68a391764fec3cc1fdfd7a..231a2644f7150abebcbbe7464a24cccdf1fcd561 100644
+index de03319757f6174b63b70c076ea8447a06b776c1..00167a1df7a3d0657cdbf814899ccd833d6dcd15 100644
--- a/src/main/java/net/minecraft/world/entity/Entity.java
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
@@ -3148,7 +3148,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource {
diff --git a/patches/server/0233-Break-up-and-make-tab-spam-limits-configurable.patch b/patches/server/0233-Break-up-and-make-tab-spam-limits-configurable.patch
index 8320863636..1a0ad57f33 100644
--- a/patches/server/0233-Break-up-and-make-tab-spam-limits-configurable.patch
+++ b/patches/server/0233-Break-up-and-make-tab-spam-limits-configurable.patch
@@ -22,7 +22,7 @@ to take the burden of this into their own hand without having to rely on
plugins doing unsafe things.
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
-index 8a2f8b48b23ddfc86746696021e62b96016afa2f..c1558f261e80d1fbb5dc66e6db741c140c5e99b8 100644
+index bd608e7ad27fd409442b524600c7a290320c40a7..7196154686d9d4828cc024d9c57dbbf7037836a7 100644
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
@@ -265,6 +265,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic
diff --git a/patches/server/0236-Add-Debug-Entities-option-to-debug-dupe-uuid-issues.patch b/patches/server/0236-Add-Debug-Entities-option-to-debug-dupe-uuid-issues.patch
index c0853a577d..7354364aac 100644
--- a/patches/server/0236-Add-Debug-Entities-option-to-debug-dupe-uuid-issues.patch
+++ b/patches/server/0236-Add-Debug-Entities-option-to-debug-dupe-uuid-issues.patch
@@ -72,7 +72,7 @@ index 33ce550ea68d4862e0966ed827200cf426909d85..6b157b362cffedae26133fc0f0af1094
return false;
} else {
diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
-index 231a2644f7150abebcbbe7464a24cccdf1fcd561..caeaa3907c1455726a0eeda7e473aacd9f8c3937 100644
+index 00167a1df7a3d0657cdbf814899ccd833d6dcd15..541de453e67dce21543a24d1f4544d84a813e3cb 100644
--- a/src/main/java/net/minecraft/world/entity/Entity.java
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
@@ -238,6 +238,8 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource {
diff --git a/patches/server/0238-Use-ConcurrentHashMap-in-JsonList.patch b/patches/server/0238-Use-ConcurrentHashMap-in-JsonList.patch
index d30a099146..eb7576c511 100644
--- a/patches/server/0238-Use-ConcurrentHashMap-in-JsonList.patch
+++ b/patches/server/0238-Use-ConcurrentHashMap-in-JsonList.patch
@@ -23,7 +23,7 @@ Modified isEmpty to use the isEmpty() method instead of the slightly confusing s
The point of this is readability, but does have a side-benefit of a small microptimization
diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java
-index 233e79c71e2c46f4220dd7423ac421be9742f53e..a9930382c39e20f30a3d613eb3c27144637c033b 100644
+index e00c1916202a4e0550cc19c9cb279448a9fcdd1e..2bccba03bb12cf17a82c1e54c2bb10535b7c8964 100644
--- a/src/main/java/net/minecraft/server/players/PlayerList.java
+++ b/src/main/java/net/minecraft/server/players/PlayerList.java
@@ -649,7 +649,7 @@ public abstract class PlayerList {
diff --git a/patches/server/0264-PreSpawnerSpawnEvent.patch b/patches/server/0264-PreSpawnerSpawnEvent.patch
index c1f27a722a..f9634b126c 100644
--- a/patches/server/0264-PreSpawnerSpawnEvent.patch
+++ b/patches/server/0264-PreSpawnerSpawnEvent.patch
@@ -9,7 +9,7 @@ SpawnerSpawnEvent gets called instead of the CreatureSpawnEvent for
spawners.
diff --git a/src/main/java/net/minecraft/world/level/BaseSpawner.java b/src/main/java/net/minecraft/world/level/BaseSpawner.java
-index 3294e5b5ed0288af08067c36ca34514d02d200d3..b5d605feff68181269f23d95d60a3ed555133d85 100644
+index fc7719d12b5f6011aec2e41a36b4bacd77672b6d..a9be524edb03c51300bc45d424fcf87c7491a8c0 100644
--- a/src/main/java/net/minecraft/world/level/BaseSpawner.java
+++ b/src/main/java/net/minecraft/world/level/BaseSpawner.java
@@ -134,11 +134,11 @@ public abstract class BaseSpawner {
diff --git a/patches/server/0269-Call-player-spectator-target-events-and-improve-impl.patch b/patches/server/0269-Call-player-spectator-target-events-and-improve-impl.patch
index 6af02e37e6..f172bc5382 100644
--- a/patches/server/0269-Call-player-spectator-target-events-and-improve-impl.patch
+++ b/patches/server/0269-Call-player-spectator-target-events-and-improve-impl.patch
@@ -19,7 +19,7 @@ spectate the target entity.
Co-authored-by: Spottedleaf
diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java
-index 2b4c0042b1971a9d922c8d32aa74c7f2e4c43341..323ed570882a3cd9b7e8bfdc1390f02e155c2448 100644
+index 0282a467268564c55d9d6e10b0602f952b2ca7ae..c151777af839ef237c004a1dd1cd0e849e402f5b 100644
--- a/src/main/java/net/minecraft/server/level/ServerPlayer.java
+++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java
@@ -1978,6 +1978,19 @@ public class ServerPlayer extends Player {
diff --git a/patches/server/0273-Add-option-to-prevent-players-from-moving-into-unloa.patch b/patches/server/0273-Add-option-to-prevent-players-from-moving-into-unloa.patch
index 916144eb4f..b72be0af0f 100644
--- a/patches/server/0273-Add-option-to-prevent-players-from-moving-into-unloa.patch
+++ b/patches/server/0273-Add-option-to-prevent-players-from-moving-into-unloa.patch
@@ -6,7 +6,7 @@ Subject: [PATCH] Add option to prevent players from moving into unloaded
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
-index c1558f261e80d1fbb5dc66e6db741c140c5e99b8..d05d088a5294f092f921961ec38053c8ccd6b6bd 100644
+index 7196154686d9d4828cc024d9c57dbbf7037836a7..6da3c9d0947c022e5565302221db0d3d71f8ddcd 100644
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
@@ -567,9 +567,9 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic
diff --git a/patches/server/0278-Restore-custom-InventoryHolder-support.patch b/patches/server/0278-Restore-custom-InventoryHolder-support.patch
index 6cfc768685..4dd682813b 100644
--- a/patches/server/0278-Restore-custom-InventoryHolder-support.patch
+++ b/patches/server/0278-Restore-custom-InventoryHolder-support.patch
@@ -194,7 +194,7 @@ index 8ea031537c27b219c22316bff191670c48ebd602..bdaa739aa18a95894a165e9333a3e9d5
// SPIGOT-4598 - we should still delegate the shift click handler
diff --git a/src/main/java/org/bukkit/craftbukkit/inventory/CraftInventory.java b/src/main/java/org/bukkit/craftbukkit/inventory/CraftInventory.java
-index 41c6bb644749b350c2e3552bbd0913b10fcb0abd..8018ad8e5952c714f1bd445c91b4d5c846b9ba7a 100644
+index 287b17ba34f1261a708b9fbf41f6422d92d9c37b..7bdb2e52d36feb9e0ce517ae95f5edb28ddc67d6 100644
--- a/src/main/java/org/bukkit/craftbukkit/inventory/CraftInventory.java
+++ b/src/main/java/org/bukkit/craftbukkit/inventory/CraftInventory.java
@@ -492,6 +492,10 @@ public class CraftInventory implements Inventory {
@@ -209,7 +209,7 @@ index 41c6bb644749b350c2e3552bbd0913b10fcb0abd..8018ad8e5952c714f1bd445c91b4d5c8
return InventoryType.ENDER_CHEST;
} else if (this.inventory instanceof MerchantContainer) {
diff --git a/src/main/java/org/bukkit/craftbukkit/inventory/CraftInventoryCustom.java b/src/main/java/org/bukkit/craftbukkit/inventory/CraftInventoryCustom.java
-index f3ebaefd949ae73afad3dcb69b8d9c632cc782f7..08f8ea0716ef8fa850f1f2f7b8a6e636f57ae872 100644
+index fc0e1212022d1aa3506699b60ef338196eb54eba..da1c1fe0faf6819b15a81d6ad53370948e5f984f 100644
--- a/src/main/java/org/bukkit/craftbukkit/inventory/CraftInventoryCustom.java
+++ b/src/main/java/org/bukkit/craftbukkit/inventory/CraftInventoryCustom.java
@@ -15,6 +15,11 @@ import org.bukkit.event.inventory.InventoryType;
diff --git a/patches/server/0284-Handle-Large-Packets-disconnecting-client.patch b/patches/server/0284-Handle-Large-Packets-disconnecting-client.patch
index e1544d8b12..52dc146bd6 100644
--- a/patches/server/0284-Handle-Large-Packets-disconnecting-client.patch
+++ b/patches/server/0284-Handle-Large-Packets-disconnecting-client.patch
@@ -7,10 +7,10 @@ If a players inventory is too big to send in a single packet,
split the inventory set into multiple packets instead.
diff --git a/src/main/java/net/minecraft/network/Connection.java b/src/main/java/net/minecraft/network/Connection.java
-index 39b1d17cfb7d5c1b0f0ee449ee1c24ef050b0c0e..410a174ae444a657cc6e753ac4f57eeece2e9365 100644
+index 7065d8e2b0782f1dbaf9932db9201b94ae455a31..f5106ed464d496420ac575b09d6c9a7dfeb87bec 100644
--- a/src/main/java/net/minecraft/network/Connection.java
+++ b/src/main/java/net/minecraft/network/Connection.java
-@@ -152,6 +152,18 @@ public class Connection extends SimpleChannelInboundHandler> {
+@@ -158,6 +158,18 @@ public class Connection extends SimpleChannelInboundHandler> {
}
public void exceptionCaught(ChannelHandlerContext channelhandlercontext, Throwable throwable) {
diff --git a/patches/server/0285-force-entity-dismount-during-teleportation.patch b/patches/server/0285-force-entity-dismount-during-teleportation.patch
index 2fb4a6c466..c5b4421ae9 100644
--- a/patches/server/0285-force-entity-dismount-during-teleportation.patch
+++ b/patches/server/0285-force-entity-dismount-during-teleportation.patch
@@ -20,7 +20,7 @@ this is going to be the best soultion all around.
Improvements/suggestions welcome!
diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
-index caeaa3907c1455726a0eeda7e473aacd9f8c3937..9db5795009389c3ca9ba70486dcd7225c3a83296 100644
+index 541de453e67dce21543a24d1f4544d84a813e3cb..9780ebabd27def10b09deebc5be2043d063de9f3 100644
--- a/src/main/java/net/minecraft/world/entity/Entity.java
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
@@ -2542,11 +2542,16 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource {
diff --git a/patches/server/0287-Book-Size-Limits.patch b/patches/server/0287-Book-Size-Limits.patch
index df4b84fad7..c29e626172 100644
--- a/patches/server/0287-Book-Size-Limits.patch
+++ b/patches/server/0287-Book-Size-Limits.patch
@@ -6,7 +6,7 @@ Subject: [PATCH] Book Size Limits
Puts some limits on the size of books.
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
-index 024b5fe3eb90c447522141454d3f733e5381bb24..ee150e432cb8ca69749dc20c8d2140c2b49bcdc2 100644
+index e6e34e5464c77dc9d349865690fa15bab0252aef..61b3a420a5e7c615a7434a7398b108015d4b62ec 100644
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
@@ -1124,6 +1124,45 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic
diff --git a/patches/server/0288-Add-PlayerConnectionCloseEvent.patch b/patches/server/0288-Add-PlayerConnectionCloseEvent.patch
index 48e9a3bb2a..78296cb243 100644
--- a/patches/server/0288-Add-PlayerConnectionCloseEvent.patch
+++ b/patches/server/0288-Add-PlayerConnectionCloseEvent.patch
@@ -39,10 +39,10 @@ public net.minecraft.server.network.ServerLoginPacketListenerImpl state
public net.minecraft.server.network.ServerLoginPacketListenerImpl gameProfile
diff --git a/src/main/java/net/minecraft/network/Connection.java b/src/main/java/net/minecraft/network/Connection.java
-index 410a174ae444a657cc6e753ac4f57eeece2e9365..38b3934b4a81972285c1c2bd0297c4458aa08e41 100644
+index f5106ed464d496420ac575b09d6c9a7dfeb87bec..b293ac99e436b02c9ef30994a394bcc53ebbf2f9 100644
--- a/src/main/java/net/minecraft/network/Connection.java
+++ b/src/main/java/net/minecraft/network/Connection.java
-@@ -493,6 +493,26 @@ public class Connection extends SimpleChannelInboundHandler> {
+@@ -509,6 +509,26 @@ public class Connection extends SimpleChannelInboundHandler> {
this.getPacketListener().onDisconnect(Component.translatable("multiplayer.disconnect.generic"));
}
this.queue.clear(); // Free up packet queue.
diff --git a/patches/server/0289-Prevent-Enderman-from-loading-chunks.patch b/patches/server/0289-Prevent-Enderman-from-loading-chunks.patch
index 9b632446b0..b467426b0b 100644
--- a/patches/server/0289-Prevent-Enderman-from-loading-chunks.patch
+++ b/patches/server/0289-Prevent-Enderman-from-loading-chunks.patch
@@ -5,7 +5,7 @@ Subject: [PATCH] Prevent Enderman from loading chunks
diff --git a/src/main/java/net/minecraft/world/entity/monster/EnderMan.java b/src/main/java/net/minecraft/world/entity/monster/EnderMan.java
-index acd41b474fadee12c571f390b937f455cbe393ad..fd608b1461ef28a5181ed3beb31f356272f8328f 100644
+index a8b3ae30d48173a699cd0e612df3d4de8a5d53e4..58c52872d07130825922bcde32011647d46e171f 100644
--- a/src/main/java/net/minecraft/world/entity/monster/EnderMan.java
+++ b/src/main/java/net/minecraft/world/entity/monster/EnderMan.java
@@ -506,7 +506,8 @@ public class EnderMan extends Monster implements NeutralMob {
diff --git a/patches/server/0291-Workaround-for-vehicle-tracking-issue-on-disconnect.patch b/patches/server/0291-Workaround-for-vehicle-tracking-issue-on-disconnect.patch
index 990ec84f7e..b3fddc1ffa 100644
--- a/patches/server/0291-Workaround-for-vehicle-tracking-issue-on-disconnect.patch
+++ b/patches/server/0291-Workaround-for-vehicle-tracking-issue-on-disconnect.patch
@@ -5,7 +5,7 @@ Subject: [PATCH] Workaround for vehicle tracking issue on disconnect
diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java
-index 47b3a068e1e8759648b24b362a34a0454f21c42d..49760077e2cfd346cc3cb4be5a60a3ea3df148ca 100644
+index 7cb4f05a8d23a60a89dd4934ccb99bb89bb44141..a2b26c5dc446b896736cf478b282e0ee8845dda7 100644
--- a/src/main/java/net/minecraft/server/level/ServerPlayer.java
+++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java
@@ -1644,6 +1644,13 @@ public class ServerPlayer extends Player {
diff --git a/patches/server/0295-Implement-Brigadier-Mojang-API.patch b/patches/server/0295-Implement-Brigadier-Mojang-API.patch
index 9deabc574b..2164b75486 100644
--- a/patches/server/0295-Implement-Brigadier-Mojang-API.patch
+++ b/patches/server/0295-Implement-Brigadier-Mojang-API.patch
@@ -10,7 +10,7 @@ Adds CommandRegisteredEvent
- Allows manipulating the CommandNode to add more children/metadata for the client
diff --git a/build.gradle.kts b/build.gradle.kts
-index 41485437cdf438cfb837a9fcd276c2dd70b84b42..9617477e8ef0ef5b1af4733ce4e87ddd796a7be2 100644
+index a00d4f3763929e605bb3ffbbd838e51a77006992..ffa1df9af1ff38ac7bbd64bca764659f308b147a 100644
--- a/build.gradle.kts
+++ b/build.gradle.kts
@@ -8,6 +8,7 @@ plugins {
@@ -131,7 +131,7 @@ index b7f1569c662df13f278fc704cabec0400ba7c382..87ce129e1d592bcf68169feb559f44d5
if (commandnode2.canUse(source)) {
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
-index ee150e432cb8ca69749dc20c8d2140c2b49bcdc2..0222181b0dddffc3b0e91dc53b5424317bb191c7 100644
+index 61b3a420a5e7c615a7434a7398b108015d4b62ec..ce163795ff4385800800e2850bcfe44e2a97c141 100644
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
@@ -840,8 +840,12 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic
diff --git a/patches/server/0298-Optimize-Network-Manager-and-add-advanced-packet-sup.patch b/patches/server/0298-Optimize-Network-Manager-and-add-advanced-packet-sup.patch
index 042c76c15f..28ba534dc3 100644
--- a/patches/server/0298-Optimize-Network-Manager-and-add-advanced-packet-sup.patch
+++ b/patches/server/0298-Optimize-Network-Manager-and-add-advanced-packet-sup.patch
@@ -28,10 +28,10 @@ and then catch exceptions and close if they fire.
Part of this commit was authored by: Spottedleaf, sandtechnology
diff --git a/src/main/java/net/minecraft/network/Connection.java b/src/main/java/net/minecraft/network/Connection.java
-index 38b3934b4a81972285c1c2bd0297c4458aa08e41..5308f016baf3001ffd1468633cde446493ca581e 100644
+index b293ac99e436b02c9ef30994a394bcc53ebbf2f9..99d5fd192a4cf1ac2739520a111b8dd854ff2f57 100644
--- a/src/main/java/net/minecraft/network/Connection.java
+++ b/src/main/java/net/minecraft/network/Connection.java
-@@ -118,6 +118,10 @@ public class Connection extends SimpleChannelInboundHandler> {
+@@ -120,6 +120,10 @@ public class Connection extends SimpleChannelInboundHandler> {
public int protocolVersion;
public java.net.InetSocketAddress virtualHost;
private static boolean enableExplicitFlush = Boolean.getBoolean("paper.explicit-flush");
@@ -42,7 +42,7 @@ index 38b3934b4a81972285c1c2bd0297c4458aa08e41..5308f016baf3001ffd1468633cde4464
// Paper end
public Connection(PacketFlow side) {
-@@ -141,6 +145,7 @@ public class Connection extends SimpleChannelInboundHandler> {
+@@ -147,6 +151,7 @@ public class Connection extends SimpleChannelInboundHandler> {
}
public void setProtocol(ConnectionProtocol state) {
@@ -50,7 +50,7 @@ index 38b3934b4a81972285c1c2bd0297c4458aa08e41..5308f016baf3001ffd1468633cde4464
this.channel.attr(Connection.ATTRIBUTE_PROTOCOL).set(state);
this.channel.attr(BundlerInfo.BUNDLER_PROVIDER).set(state);
this.channel.config().setAutoRead(true);
-@@ -223,19 +228,88 @@ public class Connection extends SimpleChannelInboundHandler> {
+@@ -229,19 +234,88 @@ public class Connection extends SimpleChannelInboundHandler> {
Validate.notNull(listener, "packetListener", new Object[0]);
this.packetListener = listener;
}
@@ -143,7 +143,7 @@ index 38b3934b4a81972285c1c2bd0297c4458aa08e41..5308f016baf3001ffd1468633cde4464
}
private void sendPacket(Packet> packet, @Nullable PacketSendListener callbacks) {
-@@ -267,6 +341,15 @@ public class Connection extends SimpleChannelInboundHandler> {
+@@ -273,6 +347,15 @@ public class Connection extends SimpleChannelInboundHandler> {
this.setProtocol(packetState);
}
@@ -159,7 +159,7 @@ index 38b3934b4a81972285c1c2bd0297c4458aa08e41..5308f016baf3001ffd1468633cde4464
ChannelFuture channelfuture = this.channel.writeAndFlush(packet);
if (callbacks != null) {
-@@ -285,28 +368,72 @@ public class Connection extends SimpleChannelInboundHandler> {
+@@ -291,28 +374,72 @@ public class Connection extends SimpleChannelInboundHandler> {
});
}
@@ -240,7 +240,7 @@ index 38b3934b4a81972285c1c2bd0297c4458aa08e41..5308f016baf3001ffd1468633cde4464
} finally { // Paper start - add pending task queue
Runnable r;
while ((r = this.pendingTasks.poll()) != null) {
-@@ -314,6 +441,7 @@ public class Connection extends SimpleChannelInboundHandler> {
+@@ -320,6 +447,7 @@ public class Connection extends SimpleChannelInboundHandler> {
}
} // Paper end - add pending task queue
}
@@ -248,7 +248,7 @@ index 38b3934b4a81972285c1c2bd0297c4458aa08e41..5308f016baf3001ffd1468633cde4464
public void tick() {
this.flushQueue();
-@@ -350,9 +478,22 @@ public class Connection extends SimpleChannelInboundHandler> {
+@@ -356,9 +484,22 @@ public class Connection extends SimpleChannelInboundHandler> {
return this.address;
}
@@ -269,9 +269,9 @@ index 38b3934b4a81972285c1c2bd0297c4458aa08e41..5308f016baf3001ffd1468633cde4464
this.preparing = false;
+ clearPacketQueue(); // Paper
// Spigot End
- if (this.channel.isOpen()) {
- this.channel.close(); // We can't wait as this may be called from an event loop.
-@@ -484,7 +625,7 @@ public class Connection extends SimpleChannelInboundHandler> {
+ if (this.channel == null) {
+ this.delayedDisconnect = disconnectReason;
+@@ -500,7 +641,7 @@ public class Connection extends SimpleChannelInboundHandler> {
public void handleDisconnection() {
if (this.channel != null && !this.channel.isOpen()) {
if (this.disconnectionHandled) {
@@ -280,7 +280,7 @@ index 38b3934b4a81972285c1c2bd0297c4458aa08e41..5308f016baf3001ffd1468633cde4464
} else {
this.disconnectionHandled = true;
if (this.getDisconnectedReason() != null) {
-@@ -492,7 +633,7 @@ public class Connection extends SimpleChannelInboundHandler> {
+@@ -508,7 +649,7 @@ public class Connection extends SimpleChannelInboundHandler> {
} else if (this.getPacketListener() != null) {
this.getPacketListener().onDisconnect(Component.translatable("multiplayer.disconnect.generic"));
}
@@ -289,7 +289,7 @@ index 38b3934b4a81972285c1c2bd0297c4458aa08e41..5308f016baf3001ffd1468633cde4464
// Paper start - Add PlayerConnectionCloseEvent
final PacketListener packetListener = this.getPacketListener();
if (packetListener instanceof net.minecraft.server.network.ServerGamePacketListenerImpl) {
-@@ -532,6 +673,18 @@ public class Connection extends SimpleChannelInboundHandler> {
+@@ -548,6 +689,18 @@ public class Connection extends SimpleChannelInboundHandler> {
@Nullable
final PacketSendListener listener;
diff --git a/patches/server/0300-Call-WhitelistToggleEvent-when-whitelist-is-toggled.patch b/patches/server/0300-Call-WhitelistToggleEvent-when-whitelist-is-toggled.patch
index 8e092efed4..3da6a62965 100644
--- a/patches/server/0300-Call-WhitelistToggleEvent-when-whitelist-is-toggled.patch
+++ b/patches/server/0300-Call-WhitelistToggleEvent-when-whitelist-is-toggled.patch
@@ -5,7 +5,7 @@ Subject: [PATCH] Call WhitelistToggleEvent when whitelist is toggled
diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java
-index d3a4de9d140440eb9dda9138bd73e8bd481d0139..888547c662b99193af8f803817bc830ab3cc9378 100644
+index 5657493e215a17f3132f9d411424875160fda6d9..e038240042366e1c491c04016982c91c91ee86cd 100644
--- a/src/main/java/net/minecraft/server/players/PlayerList.java
+++ b/src/main/java/net/minecraft/server/players/PlayerList.java
@@ -1157,6 +1157,7 @@ public abstract class PlayerList {
diff --git a/patches/server/0303-Implement-PlayerPostRespawnEvent.patch b/patches/server/0303-Implement-PlayerPostRespawnEvent.patch
index 702c26f8f3..410baaf9d7 100644
--- a/patches/server/0303-Implement-PlayerPostRespawnEvent.patch
+++ b/patches/server/0303-Implement-PlayerPostRespawnEvent.patch
@@ -5,7 +5,7 @@ Subject: [PATCH] Implement PlayerPostRespawnEvent
diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java
-index 6151563936d5863bd44487da6fc6c0341e25df14..bbc2cbc4e08f0cd7d82233f5168abda81d583d0b 100644
+index cccaf594392a0283f00986f182cc89d56181bc40..94a0d17a0339249c1c97e36d6e13b5958cfa2e49 100644
--- a/src/main/java/net/minecraft/server/players/PlayerList.java
+++ b/src/main/java/net/minecraft/server/players/PlayerList.java
@@ -758,9 +758,14 @@ public abstract class PlayerList {
diff --git a/patches/server/0306-PlayerDeathEvent-getItemsToKeep.patch b/patches/server/0306-PlayerDeathEvent-getItemsToKeep.patch
index 1e8e32c427..7960fa6a1c 100644
--- a/patches/server/0306-PlayerDeathEvent-getItemsToKeep.patch
+++ b/patches/server/0306-PlayerDeathEvent-getItemsToKeep.patch
@@ -11,7 +11,7 @@ Example Usage: https://gist.github.com/aikar/5bb202de6057a051a950ce1f29feb0b4
public net.minecraft.world.entity.player.Inventory compartments
diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java
-index 49760077e2cfd346cc3cb4be5a60a3ea3df148ca..ca0be3e09e19925176185736007db633a97b42ec 100644
+index a2b26c5dc446b896736cf478b282e0ee8845dda7..488b32a6c09102ccc041dde9ed7294a90753c1bb 100644
--- a/src/main/java/net/minecraft/server/level/ServerPlayer.java
+++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java
@@ -847,6 +847,46 @@ public class ServerPlayer extends Player {
diff --git a/patches/server/0310-Fix-CB-call-to-changed-postToMainThread-method.patch b/patches/server/0310-Fix-CB-call-to-changed-postToMainThread-method.patch
index b23c6532ef..4e1a9dfe83 100644
--- a/patches/server/0310-Fix-CB-call-to-changed-postToMainThread-method.patch
+++ b/patches/server/0310-Fix-CB-call-to-changed-postToMainThread-method.patch
@@ -5,7 +5,7 @@ Subject: [PATCH] Fix CB call to changed postToMainThread method
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
-index ebd48880cd7256c8f26b9a2565a756efd0188746..4a92305dd0ac5db459f0a716b4ac8d6a0aa2c437 100644
+index c227373a0fcd6c365b766973fa1ce3d8bf16ee42..de8259ce91125bf9522a9b98f4022eee45aabf3e 100644
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
@@ -515,7 +515,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic
diff --git a/patches/server/0321-Fix-MC-158900.patch b/patches/server/0321-Fix-MC-158900.patch
index dae886600a..daca6f31cc 100644
--- a/patches/server/0321-Fix-MC-158900.patch
+++ b/patches/server/0321-Fix-MC-158900.patch
@@ -7,7 +7,7 @@ The problem was we were checking isExpired() on the entry, but if it
was expired at that point, then it would be null.
diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java
-index bbc2cbc4e08f0cd7d82233f5168abda81d583d0b..8371a95cf3c4b8df73e8bfb68e45291da80fac0d 100644
+index 94a0d17a0339249c1c97e36d6e13b5958cfa2e49..2848e657209a699b12fc0e1fd2bde54d661f07f0 100644
--- a/src/main/java/net/minecraft/server/players/PlayerList.java
+++ b/src/main/java/net/minecraft/server/players/PlayerList.java
@@ -642,8 +642,10 @@ public abstract class PlayerList {
diff --git a/patches/server/0329-PlayerDeathEvent-shouldDropExperience.patch b/patches/server/0329-PlayerDeathEvent-shouldDropExperience.patch
index 6631be458f..a542430630 100644
--- a/patches/server/0329-PlayerDeathEvent-shouldDropExperience.patch
+++ b/patches/server/0329-PlayerDeathEvent-shouldDropExperience.patch
@@ -5,7 +5,7 @@ Subject: [PATCH] PlayerDeathEvent#shouldDropExperience
diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java
-index ca0be3e09e19925176185736007db633a97b42ec..4d0e586aef645af40ef0f8715796190cbddbfda8 100644
+index 488b32a6c09102ccc041dde9ed7294a90753c1bb..5ea537b98fc038798ada3d60570aaf908571d6b9 100644
--- a/src/main/java/net/minecraft/server/level/ServerPlayer.java
+++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java
@@ -967,7 +967,7 @@ public class ServerPlayer extends Player {
diff --git a/patches/server/0333-Fix-items-not-falling-correctly.patch b/patches/server/0333-Fix-items-not-falling-correctly.patch
index 6f2bb185e1..463f65c6fb 100644
--- a/patches/server/0333-Fix-items-not-falling-correctly.patch
+++ b/patches/server/0333-Fix-items-not-falling-correctly.patch
@@ -28,7 +28,7 @@ index 21773aea4d5e5f3946202e03afdc00f7bb109618..080b574d28b07e59b234a927a50ba897
float f1 = 0.98F;
diff --git a/src/main/java/org/spigotmc/ActivationRange.java b/src/main/java/org/spigotmc/ActivationRange.java
-index a526816f261de2a75a04be82596a7d8d674ead4a..0bdd57e214a8652c2ce7c923c28fc17e52624fb5 100644
+index 1d9ce6dae17ff572d4528971c69c63d0f85b313c..305d9772f2af22e8bdf73235cdb15ea01ac2c3b3 100644
--- a/src/main/java/org/spigotmc/ActivationRange.java
+++ b/src/main/java/org/spigotmc/ActivationRange.java
@@ -257,7 +257,7 @@ public class ActivationRange
diff --git a/patches/server/0341-Fix-items-vanishing-through-end-portal.patch b/patches/server/0341-Fix-items-vanishing-through-end-portal.patch
index 97c6bc8bff..942e4f56d7 100644
--- a/patches/server/0341-Fix-items-vanishing-through-end-portal.patch
+++ b/patches/server/0341-Fix-items-vanishing-through-end-portal.patch
@@ -13,7 +13,7 @@ Quickly loading the exact world spawn chunk before searching the
heightmap resolves the issue without having to load all spawn chunks.
diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
-index 948ea6e93170902a771950a56f0ce1a41e2bffd7..f0f1aee5f2613f81d8f600ecb9137856b09e2319 100644
+index e35a8e118db04143b29b4c8e56b6fae277e18ca3..8664c86b62fb05eb0a3fb9333583cedd29fbf289 100644
--- a/src/main/java/net/minecraft/world/entity/Entity.java
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
@@ -3353,6 +3353,9 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource {
diff --git a/patches/server/0342-implement-optional-per-player-mob-spawns.patch b/patches/server/0342-implement-optional-per-player-mob-spawns.patch
index 9425f87cb9..b287591270 100644
--- a/patches/server/0342-implement-optional-per-player-mob-spawns.patch
+++ b/patches/server/0342-implement-optional-per-player-mob-spawns.patch
@@ -362,7 +362,7 @@ index 5cb151a7d89c7281b03f24c5f79afb7edf7cbfea..d9743139d1cb932c6aac56da85f073e4
this.lastSpawnState = spawnercreature_d;
diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java
-index 4d0e586aef645af40ef0f8715796190cbddbfda8..95ba44eb591e963663b18ae73ca42679ca5fddfe 100644
+index 5ea537b98fc038798ada3d60570aaf908571d6b9..9e4e2a23891031589a03a5e8dc3e67091acd360b 100644
--- a/src/main/java/net/minecraft/server/level/ServerPlayer.java
+++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java
@@ -248,6 +248,11 @@ public class ServerPlayer extends Player {
diff --git a/patches/server/0351-Add-option-to-nerf-pigmen-from-nether-portals.patch b/patches/server/0351-Add-option-to-nerf-pigmen-from-nether-portals.patch
index 2cf3485746..2e308c9787 100644
--- a/patches/server/0351-Add-option-to-nerf-pigmen-from-nether-portals.patch
+++ b/patches/server/0351-Add-option-to-nerf-pigmen-from-nether-portals.patch
@@ -5,7 +5,7 @@ Subject: [PATCH] Add option to nerf pigmen from nether portals
diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
-index f0f1aee5f2613f81d8f600ecb9137856b09e2319..8619d3d81c9ce9b85fcfee37de564630f5ae0be6 100644
+index 8664c86b62fb05eb0a3fb9333583cedd29fbf289..1f6317d945e1dc72dc7c840fc9841e0c964ff006 100644
--- a/src/main/java/net/minecraft/world/entity/Entity.java
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
@@ -392,6 +392,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource {
diff --git a/patches/server/0352-Make-the-GUI-graph-fancier.patch b/patches/server/0352-Make-the-GUI-graph-fancier.patch
index b97ce20f84..2768fc5d7c 100644
--- a/patches/server/0352-Make-the-GUI-graph-fancier.patch
+++ b/patches/server/0352-Make-the-GUI-graph-fancier.patch
@@ -384,7 +384,7 @@ index 0000000000000000000000000000000000000000..c3e54da4ab6440811aab2f9dd1e21880
+ }
+}
diff --git a/src/main/java/net/minecraft/server/gui/MinecraftServerGui.java b/src/main/java/net/minecraft/server/gui/MinecraftServerGui.java
-index 75083eeb9b413e6dd5375007360dce6857a08fff..66464c10a6b33414c6d1b67b926a66c343d5f887 100644
+index d292fdb165436f0b9b46b32110f5e09ad0e517a1..2e93eec8733c5b548a15269a322fe4dd1f189b7d 100644
--- a/src/main/java/net/minecraft/server/gui/MinecraftServerGui.java
+++ b/src/main/java/net/minecraft/server/gui/MinecraftServerGui.java
@@ -95,7 +95,7 @@ public class MinecraftServerGui extends JComponent {
diff --git a/patches/server/0353-add-hand-to-BlockMultiPlaceEvent.patch b/patches/server/0353-add-hand-to-BlockMultiPlaceEvent.patch
index 9c117f925a..c28dd4a82b 100644
--- a/patches/server/0353-add-hand-to-BlockMultiPlaceEvent.patch
+++ b/patches/server/0353-add-hand-to-BlockMultiPlaceEvent.patch
@@ -5,7 +5,7 @@ Subject: [PATCH] add hand to BlockMultiPlaceEvent
diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
-index 68b1e24a497c052c8e20b946b5b5dabc59e7f539..90cd8b87205a7b96eab8a9de5114d6c8ff339c8e 100644
+index e8783b2c7083c847770e9f08e796b58e9f8ea6ec..8fbe5a10ba6eeff70c9b4907717c281b6f30a454 100644
--- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
+++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
@@ -366,13 +366,18 @@ public class CraftEventFactory {
diff --git a/patches/server/0361-Add-Raw-Byte-ItemStack-Serialization.patch b/patches/server/0361-Add-Raw-Byte-ItemStack-Serialization.patch
index 6fece81d45..6af14e1082 100644
--- a/patches/server/0361-Add-Raw-Byte-ItemStack-Serialization.patch
+++ b/patches/server/0361-Add-Raw-Byte-ItemStack-Serialization.patch
@@ -6,7 +6,7 @@ Subject: [PATCH] Add Raw Byte ItemStack Serialization
Serializes using NBT which is safer for server data migrations than bukkits format.
diff --git a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
-index e608b7542f6de7b3f2d7af25bb28f2705f6a9688..00dc3da665c295133931b80f92c19333d18b5f9a 100644
+index bf8cb65df8e6ecc76e065625e89fd296d71b15b4..173d17adb76f5f08828048236f544d25f53152ea 100644
--- a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
+++ b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
@@ -466,6 +466,52 @@ public final class CraftMagicNumbers implements UnsafeValues {
diff --git a/patches/server/0362-Pillager-patrol-spawn-settings-and-per-player-option.patch b/patches/server/0362-Pillager-patrol-spawn-settings-and-per-player-option.patch
index 67be08c3ea..27efec7f20 100644
--- a/patches/server/0362-Pillager-patrol-spawn-settings-and-per-player-option.patch
+++ b/patches/server/0362-Pillager-patrol-spawn-settings-and-per-player-option.patch
@@ -10,7 +10,7 @@ When not per player it will use the Vanilla mechanic of one delay per
world and the world age for the start day.
diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java
-index 95ba44eb591e963663b18ae73ca42679ca5fddfe..b712690fd011533d6d55718f96a94f6a9a25ad8d 100644
+index 9e4e2a23891031589a03a5e8dc3e67091acd360b..0642fbe2e2fa5ab3e0919f71903e6545bd7121fe 100644
--- a/src/main/java/net/minecraft/server/level/ServerPlayer.java
+++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java
@@ -244,6 +244,7 @@ public class ServerPlayer extends Player {
diff --git a/patches/server/0366-Don-t-tick-dead-players.patch b/patches/server/0366-Don-t-tick-dead-players.patch
index 9396dd66c9..b84a5ebc65 100644
--- a/patches/server/0366-Don-t-tick-dead-players.patch
+++ b/patches/server/0366-Don-t-tick-dead-players.patch
@@ -7,7 +7,7 @@ Causes sync chunk loads and who knows what all else.
This is safe because Spectators are skipped in unloaded chunks too in vanilla.
diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java
-index b712690fd011533d6d55718f96a94f6a9a25ad8d..1d322c8d7e072cea923edcb92e28fa82de8daba8 100644
+index 0642fbe2e2fa5ab3e0919f71903e6545bd7121fe..2d51abce5d5de66bbf6daaf699931bb9d3afc397 100644
--- a/src/main/java/net/minecraft/server/level/ServerPlayer.java
+++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java
@@ -724,7 +724,7 @@ public class ServerPlayer extends Player {
diff --git a/patches/server/0368-Optimize-Collision-to-not-load-chunks.patch b/patches/server/0368-Optimize-Collision-to-not-load-chunks.patch
index 6ea667dd23..96cf0f4ee2 100644
--- a/patches/server/0368-Optimize-Collision-to-not-load-chunks.patch
+++ b/patches/server/0368-Optimize-Collision-to-not-load-chunks.patch
@@ -14,7 +14,7 @@ movement will load only the chunk the player enters anyways and avoids loading
massive amounts of surrounding chunks due to large AABB lookups.
diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java
-index 8371a95cf3c4b8df73e8bfb68e45291da80fac0d..6eb33551b05152a5ea98f047f072ea4d663d72d8 100644
+index 2848e657209a699b12fc0e1fd2bde54d661f07f0..9c3ab91555f60a1a3cd8a89e883cfbdedc53f3f8 100644
--- a/src/main/java/net/minecraft/server/players/PlayerList.java
+++ b/src/main/java/net/minecraft/server/players/PlayerList.java
@@ -827,6 +827,7 @@ public abstract class PlayerList {
@@ -26,7 +26,7 @@ index 8371a95cf3c4b8df73e8bfb68e45291da80fac0d..6eb33551b05152a5ea98f047f072ea4d
entityplayer1.setPos(entityplayer1.getX(), entityplayer1.getY() + 1.0D, entityplayer1.getZ());
}
diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
-index 8619d3d81c9ce9b85fcfee37de564630f5ae0be6..fb6f5c43f2e06824b1e78404f422bee29ca40293 100644
+index 1f6317d945e1dc72dc7c840fc9841e0c964ff006..89bd0267cbdf3bc412eeca461b83fe931dce2cba 100644
--- a/src/main/java/net/minecraft/world/entity/Entity.java
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
@@ -237,6 +237,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource {
diff --git a/patches/server/0369-Don-t-move-existing-players-to-world-spawn.patch b/patches/server/0369-Don-t-move-existing-players-to-world-spawn.patch
index 0c044d867e..c7c861c0ec 100644
--- a/patches/server/0369-Don-t-move-existing-players-to-world-spawn.patch
+++ b/patches/server/0369-Don-t-move-existing-players-to-world-spawn.patch
@@ -13,7 +13,7 @@ By skipping this, we avoid potential for a large spike on server start.
public net.minecraft.server.level.ServerPlayer fudgeSpawnLocation(Lnet/minecraft/server/level/ServerLevel;)V
diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java
-index 1d322c8d7e072cea923edcb92e28fa82de8daba8..e8a1aff3ddd94925e1c0f554cc8e7ff9e9864242 100644
+index 2d51abce5d5de66bbf6daaf699931bb9d3afc397..6ad3b7e7c7808cb40697e2eb6185f431fc431a20 100644
--- a/src/main/java/net/minecraft/server/level/ServerPlayer.java
+++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java
@@ -377,7 +377,7 @@ public class ServerPlayer extends Player {
@@ -35,7 +35,7 @@ index 1d322c8d7e072cea923edcb92e28fa82de8daba8..e8a1aff3ddd94925e1c0f554cc8e7ff9
this.gameMode.setLevel((ServerLevel) world);
}
diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java
-index 6eb33551b05152a5ea98f047f072ea4d663d72d8..5b3e8adde28d11aec4ea526ebba61d561ec06cb6 100644
+index 9c3ab91555f60a1a3cd8a89e883cfbdedc53f3f8..5b8b345ade30012371bdda744ba82c585f74db07 100644
--- a/src/main/java/net/minecraft/server/players/PlayerList.java
+++ b/src/main/java/net/minecraft/server/players/PlayerList.java
@@ -236,6 +236,7 @@ public abstract class PlayerList {
diff --git a/patches/server/0379-Fix-Longstanding-Broken-behavior-of-PlayerJoinEvent.patch b/patches/server/0379-Fix-Longstanding-Broken-behavior-of-PlayerJoinEvent.patch
index db0c03d70f..6442bd23eb 100644
--- a/patches/server/0379-Fix-Longstanding-Broken-behavior-of-PlayerJoinEvent.patch
+++ b/patches/server/0379-Fix-Longstanding-Broken-behavior-of-PlayerJoinEvent.patch
@@ -43,7 +43,7 @@ index a8c4c7298e127e5b60a3b43ad168976d29901bc5..48586780da5d260894fe59efaa97cb1f
if (!(entity instanceof EnderDragonPart)) {
EntityType> entitytypes = entity.getType();
diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java
-index cc3ebc15e25e132870bbc336e68216459a4545da..af6b92056d924f7cb9a7a583fd089025c95f88ad 100644
+index fd34a2ace2efc819b06674ceab44ff78ec11f805..6dcac005b57234983d0ed05fe825a16c98eb4557 100644
--- a/src/main/java/net/minecraft/server/level/ServerPlayer.java
+++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java
@@ -267,6 +267,7 @@ public class ServerPlayer extends Player {
@@ -55,7 +55,7 @@ index cc3ebc15e25e132870bbc336e68216459a4545da..af6b92056d924f7cb9a7a583fd089025
public String kickLeaveMessage = null; // SPIGOT-3034: Forward leave message to PlayerQuitEvent
// CraftBukkit end
diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java
-index 95356cfb36f2103889a21d6c360d29a318c871dd..8a67971d67230b30b769eea5745919946d868bd8 100644
+index 0d100788312a234616c1401656f09835458e79f6..97199ae30edfaaacb9ea9d29846ee131395815e6 100644
--- a/src/main/java/net/minecraft/server/players/PlayerList.java
+++ b/src/main/java/net/minecraft/server/players/PlayerList.java
@@ -311,6 +311,12 @@ public abstract class PlayerList {
diff --git a/patches/server/0380-Move-player-to-spawn-point-if-spawn-in-unloaded-worl.patch b/patches/server/0380-Move-player-to-spawn-point-if-spawn-in-unloaded-worl.patch
index e39c1d0ec7..d5ceb349d2 100644
--- a/patches/server/0380-Move-player-to-spawn-point-if-spawn-in-unloaded-worl.patch
+++ b/patches/server/0380-Move-player-to-spawn-point-if-spawn-in-unloaded-worl.patch
@@ -7,7 +7,7 @@ The code following this has better support for null worlds to move
them back to the world spawn.
diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
-index fb6f5c43f2e06824b1e78404f422bee29ca40293..997f73e86d62b546e363382a3126bc43b4b17b7f 100644
+index 89bd0267cbdf3bc412eeca461b83fe931dce2cba..595f58d9eb74fd934009bc1e4aa459074678ee94 100644
--- a/src/main/java/net/minecraft/world/entity/Entity.java
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
@@ -2319,9 +2319,11 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource {
diff --git a/patches/server/0384-Fix-numerous-item-duplication-issues-and-teleport-is.patch b/patches/server/0384-Fix-numerous-item-duplication-issues-and-teleport-is.patch
index 1397d07d0d..95bd7a94e7 100644
--- a/patches/server/0384-Fix-numerous-item-duplication-issues-and-teleport-is.patch
+++ b/patches/server/0384-Fix-numerous-item-duplication-issues-and-teleport-is.patch
@@ -16,7 +16,7 @@ So even if something NEW comes up, it would be impossible to drop the
same item twice because the source was destroyed.
diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
-index 997f73e86d62b546e363382a3126bc43b4b17b7f..909d0c96840724033bd907560db46d4cbb7f41aa 100644
+index 595f58d9eb74fd934009bc1e4aa459074678ee94..077466f62bb09cc1bf0c101f6a1fbdc1519590bb 100644
--- a/src/main/java/net/minecraft/world/entity/Entity.java
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
@@ -2449,11 +2449,12 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource {
@@ -135,7 +135,7 @@ index 4413b609f1250cf9477fcb3fecd7b67afee0b896..101e3a1f0f52b67b55c99c2619cc4329
}
}
diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
-index 90cd8b87205a7b96eab8a9de5114d6c8ff339c8e..4a1699b56f2111881653404b38f18c9e2e7473b4 100644
+index 8fbe5a10ba6eeff70c9b4907717c281b6f30a454..f9f9292a99bf35d49916e1380781cc9bc0e19842 100644
--- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
+++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
@@ -827,6 +827,11 @@ public class CraftEventFactory {
diff --git a/patches/server/0386-Validate-PickItem-Packet-and-kick-for-invalid.patch b/patches/server/0386-Validate-PickItem-Packet-and-kick-for-invalid.patch
index c5e06fdba4..3a3dea4df9 100644
--- a/patches/server/0386-Validate-PickItem-Packet-and-kick-for-invalid.patch
+++ b/patches/server/0386-Validate-PickItem-Packet-and-kick-for-invalid.patch
@@ -5,7 +5,7 @@ Subject: [PATCH] Validate PickItem Packet and kick for invalid
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
-index 4a92305dd0ac5db459f0a716b4ac8d6a0aa2c437..1bf4ed4878f900730f66e2245106e66bd1927a5f 100644
+index de8259ce91125bf9522a9b98f4022eee45aabf3e..ee7c9f1efcc0de58bb2bf7126a589e5ca8f3c409 100644
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
@@ -967,7 +967,14 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic
diff --git a/patches/server/0392-Deobfuscate-stacktraces-in-log-messages-crash-report.patch b/patches/server/0392-Deobfuscate-stacktraces-in-log-messages-crash-report.patch
index 16a9f30507..fb8b5a6606 100644
--- a/patches/server/0392-Deobfuscate-stacktraces-in-log-messages-crash-report.patch
+++ b/patches/server/0392-Deobfuscate-stacktraces-in-log-messages-crash-report.patch
@@ -6,7 +6,7 @@ Subject: [PATCH] Deobfuscate stacktraces in log messages, crash reports, and
diff --git a/build.gradle.kts b/build.gradle.kts
-index 9183b71f6ca78b4a3bc7d804f8d9c4c6db65d5cc..f1fd98bd3d39b4c34043b269e8c43cff073f2726 100644
+index ffa1df9af1ff38ac7bbd64bca764659f308b147a..03bf39337d32b1947b6c57070bfa1de08da72179 100644
--- a/build.gradle.kts
+++ b/build.gradle.kts
@@ -28,6 +28,7 @@ dependencies {
@@ -466,7 +466,7 @@ index 52eb3176437113f9a0ff85d10ce5c2415e1b5570..b54ddd0ba0b001fbcb1838a838ca4890
}
}
diff --git a/src/main/java/net/minecraft/network/Connection.java b/src/main/java/net/minecraft/network/Connection.java
-index 5308f016baf3001ffd1468633cde446493ca581e..1b6d090afea5b0a49b601b73cefeedc0b832ba9d 100644
+index 99d5fd192a4cf1ac2739520a111b8dd854ff2f57..dc3dea801a673462e767ad37268ec77ac95d214c 100644
--- a/src/main/java/net/minecraft/network/Connection.java
+++ b/src/main/java/net/minecraft/network/Connection.java
@@ -64,13 +64,13 @@ public class Connection extends SimpleChannelInboundHandler> {
@@ -486,7 +486,7 @@ index 5308f016baf3001ffd1468633cde446493ca581e..1b6d090afea5b0a49b601b73cefeedc0
});
private final PacketFlow receiving;
private final Queue queue = Queues.newConcurrentLinkedQueue();
-@@ -199,7 +199,7 @@ public class Connection extends SimpleChannelInboundHandler> {
+@@ -205,7 +205,7 @@ public class Connection extends SimpleChannelInboundHandler> {
}
}
diff --git a/patches/server/0393-Implement-Mob-Goal-API.patch b/patches/server/0393-Implement-Mob-Goal-API.patch
index 591df060da..71744d7fd7 100644
--- a/patches/server/0393-Implement-Mob-Goal-API.patch
+++ b/patches/server/0393-Implement-Mob-Goal-API.patch
@@ -5,7 +5,7 @@ Subject: [PATCH] Implement Mob Goal API
diff --git a/build.gradle.kts b/build.gradle.kts
-index f1fd98bd3d39b4c34043b269e8c43cff073f2726..b65278b9addf9a26b0f63975f439d333fd3fdf87 100644
+index 03bf39337d32b1947b6c57070bfa1de08da72179..96866069c69ce230ea499ac7208f98627c081586 100644
--- a/build.gradle.kts
+++ b/build.gradle.kts
@@ -37,6 +37,7 @@ dependencies {
diff --git a/patches/server/0395-Option-for-maximum-exp-value-when-merging-orbs.patch b/patches/server/0395-Option-for-maximum-exp-value-when-merging-orbs.patch
index bb103e920e..d4ec4f243f 100644
--- a/patches/server/0395-Option-for-maximum-exp-value-when-merging-orbs.patch
+++ b/patches/server/0395-Option-for-maximum-exp-value-when-merging-orbs.patch
@@ -5,7 +5,7 @@ Subject: [PATCH] Option for maximum exp value when merging orbs
diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
-index 4a1699b56f2111881653404b38f18c9e2e7473b4..3f6d9c6b88e14135917bdfe5e5df019213dde325 100644
+index f9f9292a99bf35d49916e1380781cc9bc0e19842..e8532d35f8c3bf10e5c9c17839dbce2bf927ec77 100644
--- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
+++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
@@ -648,16 +648,30 @@ public class CraftEventFactory {
diff --git a/patches/server/0396-ExperienceOrbMergeEvent.patch b/patches/server/0396-ExperienceOrbMergeEvent.patch
index d679d0f411..a2a81f9fa5 100644
--- a/patches/server/0396-ExperienceOrbMergeEvent.patch
+++ b/patches/server/0396-ExperienceOrbMergeEvent.patch
@@ -9,7 +9,7 @@ Plugins can cancel this if they want to ensure experience orbs do not lose impor
metadata such as spawn reason, or conditionally move data from source to target.
diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
-index 3f6d9c6b88e14135917bdfe5e5df019213dde325..7af0710c40c1453bd0bd8ecb4ea7606bbe76c20f 100644
+index e8532d35f8c3bf10e5c9c17839dbce2bf927ec77..f35cba8f45f96cd9504ccce73fea592532c36702 100644
--- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
+++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
@@ -658,7 +658,7 @@ public class CraftEventFactory {
diff --git a/patches/server/0399-Potential-bed-API.patch b/patches/server/0399-Potential-bed-API.patch
index cf11492434..7f753c1b92 100644
--- a/patches/server/0399-Potential-bed-API.patch
+++ b/patches/server/0399-Potential-bed-API.patch
@@ -8,7 +8,7 @@ Adds a new method to fetch the location of a player's bed without generating any
getPotentialBedLocation - Gets the last known location of a player's bed. This does not preform any check if the bed is still valid and does not load any chunks.
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java
-index c31c9ccbefb1f6ed1e3f56c7ca445813ec635a12..35ef23db3e135c8057ea00ef0930628bced54779 100644
+index 82314358220b064a0f8a29cc1d663cc266c13916..55a3035516552f4d429ae5f36bacb1b4c4d5666c 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java
@@ -12,6 +12,7 @@ import net.minecraft.nbt.CompoundTag;
diff --git a/patches/server/0413-Prevent-position-desync-in-playerconnection-causing-.patch b/patches/server/0413-Prevent-position-desync-in-playerconnection-causing-.patch
index 55653050e7..3290779495 100644
--- a/patches/server/0413-Prevent-position-desync-in-playerconnection-causing-.patch
+++ b/patches/server/0413-Prevent-position-desync-in-playerconnection-causing-.patch
@@ -14,7 +14,7 @@ behaviour, we need to move all of this dangerous logic outside
of the move call and into an appropriate place in the tick method.
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
-index 817db930347b0a83f3cea8cbcbd823622c1be7c0..23d576cebf10bc0f35b9fb99df7b323a744dd111 100644
+index 9788b50ca86be8cf8412b5c53ad75bda5d8615e3..bc05121fcda77b1672901fa9bf05ba68af51c77c 100644
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
@@ -1441,6 +1441,11 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic
diff --git a/patches/server/0414-Use-distance-map-to-optimise-entity-tracker.patch b/patches/server/0414-Use-distance-map-to-optimise-entity-tracker.patch
index c295c91a7e..54f0d92fb1 100644
--- a/patches/server/0414-Use-distance-map-to-optimise-entity-tracker.patch
+++ b/patches/server/0414-Use-distance-map-to-optimise-entity-tracker.patch
@@ -279,7 +279,7 @@ index dadf403ac91887f0fae87889170deb6d5732cbc1..93dea79180ebaef3ffb6abffd47f0026
return object instanceof ChunkMap.TrackedEntity ? ((ChunkMap.TrackedEntity) object).entity.getId() == this.entity.getId() : false;
}
diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
-index 909d0c96840724033bd907560db46d4cbb7f41aa..a9a845f6a7967d306ec935c4f32414053da591f0 100644
+index 077466f62bb09cc1bf0c101f6a1fbdc1519590bb..283c541a431aad061da20f9bff49cb8686a24cd7 100644
--- a/src/main/java/net/minecraft/world/entity/Entity.java
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
@@ -57,6 +57,7 @@ import net.minecraft.network.syncher.EntityDataSerializers;
diff --git a/patches/server/0419-Add-permission-for-command-blocks.patch b/patches/server/0419-Add-permission-for-command-blocks.patch
index 72df584e4a..b39b80f9a9 100644
--- a/patches/server/0419-Add-permission-for-command-blocks.patch
+++ b/patches/server/0419-Add-permission-for-command-blocks.patch
@@ -18,7 +18,7 @@ index 84ffc86e2eba089d0200183847e879d638e8460d..6a45cd61d2590aa25b9cb38028d2dcf3
return false;
} else if (this.player.blockActionRestricted(this.level, pos, this.gameModeForPlayer)) {
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
-index 4f43f6ff06ab3b68631b8e9c8dd1e9d4a5e76880..04a9cef0a80aaa401ce0ed560a16f3ada6e6a953 100644
+index 4181eaef05589eb1f54c6a3cf76ca98a71bcfed3..e6b53060aaf7c2b7ed8b24240be2bbe7cc962f67 100644
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
@@ -878,7 +878,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic
diff --git a/patches/server/0420-Ensure-Entity-AABB-s-are-never-invalid.patch b/patches/server/0420-Ensure-Entity-AABB-s-are-never-invalid.patch
index 8532475e71..0779b97f55 100644
--- a/patches/server/0420-Ensure-Entity-AABB-s-are-never-invalid.patch
+++ b/patches/server/0420-Ensure-Entity-AABB-s-are-never-invalid.patch
@@ -5,7 +5,7 @@ Subject: [PATCH] Ensure Entity AABB's are never invalid
diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
-index a9a845f6a7967d306ec935c4f32414053da591f0..886db1055c69f2b0ce7a5bf61e53d3b1119d2c19 100644
+index 283c541a431aad061da20f9bff49cb8686a24cd7..5a1959a16070a49e935bfd7a43fbf3fabdd2b1e6 100644
--- a/src/main/java/net/minecraft/world/entity/Entity.java
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
@@ -721,8 +721,8 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource {
diff --git a/patches/server/0436-Spawn-player-in-correct-world-on-login.patch b/patches/server/0436-Spawn-player-in-correct-world-on-login.patch
index 3ce67aea63..9eca8932f2 100644
--- a/patches/server/0436-Spawn-player-in-correct-world-on-login.patch
+++ b/patches/server/0436-Spawn-player-in-correct-world-on-login.patch
@@ -5,7 +5,7 @@ Subject: [PATCH] Spawn player in correct world on login
diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java
-index 3c98a55a1b9eee854d8c48af449b876d3a46501f..0cd93062ffc2bf824e99f8776254a5269e9117c3 100644
+index a8dcd1a07b835f665c74a8a531fef84435716b13..abfd8510c726e17d7a0c99d13cfe065615583fcd 100644
--- a/src/main/java/net/minecraft/server/players/PlayerList.java
+++ b/src/main/java/net/minecraft/server/players/PlayerList.java
@@ -212,7 +212,18 @@ public abstract class PlayerList {
diff --git a/patches/server/0442-Fix-SPIGOT-5989.patch b/patches/server/0442-Fix-SPIGOT-5989.patch
index dd3c399748..431e528ce9 100644
--- a/patches/server/0442-Fix-SPIGOT-5989.patch
+++ b/patches/server/0442-Fix-SPIGOT-5989.patch
@@ -10,7 +10,7 @@ This fixes that by checking if the modified spawn location is
still at a respawn anchor.
diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java
-index 0cd93062ffc2bf824e99f8776254a5269e9117c3..36715e8bc9047962a2ced70d6838672159665771 100644
+index abfd8510c726e17d7a0c99d13cfe065615583fcd..31e6da864b0ddf2f65ecc43ce8ef74d6c4e9d0aa 100644
--- a/src/main/java/net/minecraft/server/players/PlayerList.java
+++ b/src/main/java/net/minecraft/server/players/PlayerList.java
@@ -794,6 +794,7 @@ public abstract class PlayerList {
diff --git a/patches/server/0457-Buffer-joins-to-world.patch b/patches/server/0457-Buffer-joins-to-world.patch
index 8c45d682cf..c7c84cfc24 100644
--- a/patches/server/0457-Buffer-joins-to-world.patch
+++ b/patches/server/0457-Buffer-joins-to-world.patch
@@ -8,10 +8,10 @@ the world per tick, this attempts to reduce the impact that join floods
has on the server
diff --git a/src/main/java/net/minecraft/network/Connection.java b/src/main/java/net/minecraft/network/Connection.java
-index 1b6d090afea5b0a49b601b73cefeedc0b832ba9d..ee8d1bb909cf2a3bbe3434aa085762d952198063 100644
+index dc3dea801a673462e767ad37268ec77ac95d214c..959d39e81cdde6fda90fcc95f842146448b4c6e4 100644
--- a/src/main/java/net/minecraft/network/Connection.java
+++ b/src/main/java/net/minecraft/network/Connection.java
-@@ -443,14 +443,29 @@ public class Connection extends SimpleChannelInboundHandler> {
+@@ -449,14 +449,29 @@ public class Connection extends SimpleChannelInboundHandler> {
}
// Paper end
diff --git a/patches/server/0469-Expose-the-Entity-Counter-to-allow-plugins-to-use-va.patch b/patches/server/0469-Expose-the-Entity-Counter-to-allow-plugins-to-use-va.patch
index 0ce23cbd0f..f761190a9f 100644
--- a/patches/server/0469-Expose-the-Entity-Counter-to-allow-plugins-to-use-va.patch
+++ b/patches/server/0469-Expose-the-Entity-Counter-to-allow-plugins-to-use-va.patch
@@ -21,7 +21,7 @@ index 11675a7611a42277ed0625509aa98a2f69611698..bda94c9c34c7f1f6b56103de5be253c6
+ // Paper end
}
diff --git a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
-index 00dc3da665c295133931b80f92c19333d18b5f9a..8f8d69adb8e0a02f9540bc2feb1ccf9e6f635aab 100644
+index 173d17adb76f5f08828048236f544d25f53152ea..6c6587c775162655581bd09e5eb7cc2d7fb8f782 100644
--- a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
+++ b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
@@ -512,6 +512,11 @@ public final class CraftMagicNumbers implements UnsafeValues {
diff --git a/patches/server/0487-Fix-client-lag-on-advancement-loading.patch b/patches/server/0487-Fix-client-lag-on-advancement-loading.patch
index 2f6ff73ac8..d32bf05036 100644
--- a/patches/server/0487-Fix-client-lag-on-advancement-loading.patch
+++ b/patches/server/0487-Fix-client-lag-on-advancement-loading.patch
@@ -15,7 +15,7 @@ manually reload the advancement data for all players, which
normally takes place as a part of the datapack reloading.
diff --git a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
-index 8f8d69adb8e0a02f9540bc2feb1ccf9e6f635aab..355d736f2cf6580c21365be2b3a0a3cb124d6d16 100644
+index 6c6587c775162655581bd09e5eb7cc2d7fb8f782..c168dbfa5bc4aa49a1d743fe4b53d8169f01e1a0 100644
--- a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
+++ b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
@@ -345,7 +345,13 @@ public final class CraftMagicNumbers implements UnsafeValues {
diff --git a/patches/server/0491-Add-API-for-quit-reason.patch b/patches/server/0491-Add-API-for-quit-reason.patch
index 168509707f..ccce1bc21a 100644
--- a/patches/server/0491-Add-API-for-quit-reason.patch
+++ b/patches/server/0491-Add-API-for-quit-reason.patch
@@ -5,10 +5,10 @@ Subject: [PATCH] Add API for quit reason
diff --git a/src/main/java/net/minecraft/network/Connection.java b/src/main/java/net/minecraft/network/Connection.java
-index ee8d1bb909cf2a3bbe3434aa085762d952198063..f8ffc5238320d2c665d80adb1ad3786c86eef968 100644
+index 959d39e81cdde6fda90fcc95f842146448b4c6e4..a1467e8edd3ca66c306d01e0688a9fece69652f3 100644
--- a/src/main/java/net/minecraft/network/Connection.java
+++ b/src/main/java/net/minecraft/network/Connection.java
-@@ -176,12 +176,15 @@ public class Connection extends SimpleChannelInboundHandler> {
+@@ -182,12 +182,15 @@ public class Connection extends SimpleChannelInboundHandler> {
this.handlingFault = true;
if (this.channel.isOpen()) {
diff --git a/patches/server/0570-Expand-world-key-API.patch b/patches/server/0570-Expand-world-key-API.patch
index 022aa9fbaa..4f0094406b 100644
--- a/patches/server/0570-Expand-world-key-API.patch
+++ b/patches/server/0570-Expand-world-key-API.patch
@@ -67,7 +67,7 @@ index b6c9dd5b3fd746ef7e863c27fd581c9f23a795a2..ed6125d52eb0e406e44a2c3ded1ed1d1
// Check if a World already exists with the UID.
if (this.getWorld(world.getUID()) != null) {
diff --git a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
-index 355d736f2cf6580c21365be2b3a0a3cb124d6d16..19c0754e87834577e166412af6936f88557c9614 100644
+index c168dbfa5bc4aa49a1d743fe4b53d8169f01e1a0..16ef907b9443b9feedd768d0116762799fee9ab3 100644
--- a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
+++ b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
@@ -523,6 +523,11 @@ public final class CraftMagicNumbers implements UnsafeValues {
diff --git a/patches/server/0572-Item-Rarity-API.patch b/patches/server/0572-Item-Rarity-API.patch
index acf29f2cbe..3e21a97a84 100644
--- a/patches/server/0572-Item-Rarity-API.patch
+++ b/patches/server/0572-Item-Rarity-API.patch
@@ -7,7 +7,7 @@ Subject: [PATCH] Item Rarity API
public net.minecraft.world.item.Item rarity
diff --git a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
-index 19c0754e87834577e166412af6936f88557c9614..47e035d384c68d5584afb228b0adb6be05add239 100644
+index 16ef907b9443b9feedd768d0116762799fee9ab3..2a08fca2c863717b72341772630cd4b690f34968 100644
--- a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
+++ b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
@@ -528,6 +528,20 @@ public final class CraftMagicNumbers implements UnsafeValues {
diff --git a/patches/server/0576-Expose-protocol-version.patch b/patches/server/0576-Expose-protocol-version.patch
index 4baad66755..79834b44b7 100644
--- a/patches/server/0576-Expose-protocol-version.patch
+++ b/patches/server/0576-Expose-protocol-version.patch
@@ -5,7 +5,7 @@ Subject: [PATCH] Expose protocol version
diff --git a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
-index 47e035d384c68d5584afb228b0adb6be05add239..507bffe09ffdc1ea8357f9ca2c5455d7704bfae8 100644
+index 2a08fca2c863717b72341772630cd4b690f34968..e540a219e26ecb1b2f93df01a34dd754faea1f10 100644
--- a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
+++ b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
@@ -542,6 +542,11 @@ public final class CraftMagicNumbers implements UnsafeValues {
diff --git a/patches/server/0594-Add-Channel-initialization-listeners.patch b/patches/server/0594-Add-Channel-initialization-listeners.patch
index efd683b7d1..e6a071010b 100644
--- a/patches/server/0594-Add-Channel-initialization-listeners.patch
+++ b/patches/server/0594-Add-Channel-initialization-listeners.patch
@@ -122,10 +122,10 @@ index 0000000000000000000000000000000000000000..0d7e7db9e37ef0183c32b217bd944fb4
+ COMPRESSION_DISABLED
+}
diff --git a/src/main/java/net/minecraft/network/Connection.java b/src/main/java/net/minecraft/network/Connection.java
-index f8ffc5238320d2c665d80adb1ad3786c86eef968..1a6326ce5160b18ecbef26d719b0a207ccad2783 100644
+index a1467e8edd3ca66c306d01e0688a9fece69652f3..0968827df66057ec73185ce688a62e8b27abba0c 100644
--- a/src/main/java/net/minecraft/network/Connection.java
+++ b/src/main/java/net/minecraft/network/Connection.java
-@@ -628,6 +628,7 @@ public class Connection extends SimpleChannelInboundHandler> {
+@@ -644,6 +644,7 @@ public class Connection extends SimpleChannelInboundHandler> {
} else {
this.channel.pipeline().addBefore("encoder", "compress", new CompressionEncoder(compressionThreshold));
}
@@ -133,7 +133,7 @@ index f8ffc5238320d2c665d80adb1ad3786c86eef968..1a6326ce5160b18ecbef26d719b0a207
} else {
if (this.channel.pipeline().get("decompress") instanceof CompressionDecoder) {
this.channel.pipeline().remove("decompress");
-@@ -636,6 +637,7 @@ public class Connection extends SimpleChannelInboundHandler> {
+@@ -652,6 +653,7 @@ public class Connection extends SimpleChannelInboundHandler> {
if (this.channel.pipeline().get("compress") instanceof CompressionEncoder) {
this.channel.pipeline().remove("compress");
}
diff --git a/patches/server/0606-ItemStack-repair-check-API.patch b/patches/server/0606-ItemStack-repair-check-API.patch
index 10e1c3e707..51821ed50d 100644
--- a/patches/server/0606-ItemStack-repair-check-API.patch
+++ b/patches/server/0606-ItemStack-repair-check-API.patch
@@ -5,7 +5,7 @@ Subject: [PATCH] ItemStack repair check API
diff --git a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
-index 507bffe09ffdc1ea8357f9ca2c5455d7704bfae8..0ad72425648eb9af806211068b5c14661749e030 100644
+index e540a219e26ecb1b2f93df01a34dd754faea1f10..cab2f4ae154a6159ead1b95dbf02ebcbb1051dd8 100644
--- a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
+++ b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
@@ -543,6 +543,14 @@ public final class CraftMagicNumbers implements UnsafeValues {
diff --git a/patches/server/0613-Attributes-API-for-item-defaults.patch b/patches/server/0613-Attributes-API-for-item-defaults.patch
index 7a942f3f03..003b920e39 100644
--- a/patches/server/0613-Attributes-API-for-item-defaults.patch
+++ b/patches/server/0613-Attributes-API-for-item-defaults.patch
@@ -5,7 +5,7 @@ Subject: [PATCH] Attributes API for item defaults
diff --git a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
-index 0ad72425648eb9af806211068b5c14661749e030..ef9a1d7e23be8ffe9a1669161de9310c6e566b40 100644
+index cab2f4ae154a6159ead1b95dbf02ebcbb1051dd8..7f870317139db136103cb72b2aa57bcba9f6e793 100644
--- a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
+++ b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
@@ -551,6 +551,19 @@ public final class CraftMagicNumbers implements UnsafeValues {
diff --git a/patches/server/0633-Missing-Entity-Behavior-API.patch b/patches/server/0633-Missing-Entity-Behavior-API.patch
index 2b270fa0e0..d086494e52 100644
--- a/patches/server/0633-Missing-Entity-Behavior-API.patch
+++ b/patches/server/0633-Missing-Entity-Behavior-API.patch
@@ -269,7 +269,7 @@ index 4576c96f85fe5a614a78e53926dfbc2705618423..9adff51029781795c2cdf479a89111b3
@Override
diff --git a/src/main/java/net/minecraft/world/entity/monster/EnderMan.java b/src/main/java/net/minecraft/world/entity/monster/EnderMan.java
-index fd608b1461ef28a5181ed3beb31f356272f8328f..4616addb05fcc20b1ec6ca1dea01cbefed697acd 100644
+index 58c52872d07130825922bcde32011647d46e171f..5519ccf558c09f32e19b35f4b403fc9ed966ed65 100644
--- a/src/main/java/net/minecraft/world/entity/monster/EnderMan.java
+++ b/src/main/java/net/minecraft/world/entity/monster/EnderMan.java
@@ -446,6 +446,16 @@ public class EnderMan extends Monster implements NeutralMob {
diff --git a/patches/server/0669-Get-entity-default-attributes.patch b/patches/server/0669-Get-entity-default-attributes.patch
index 15b48bb9b1..666afc9487 100644
--- a/patches/server/0669-Get-entity-default-attributes.patch
+++ b/patches/server/0669-Get-entity-default-attributes.patch
@@ -81,7 +81,7 @@ index 0000000000000000000000000000000000000000..cf9d28ea97d93cec05c9fb768d59e283
+ }
+}
diff --git a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
-index ef9a1d7e23be8ffe9a1669161de9310c6e566b40..78e1932852e002fc4d928ff9869678e308f9b7a4 100644
+index 7f870317139db136103cb72b2aa57bcba9f6e793..53e40ab7d37ef707151c165831b24737a9f3683c 100644
--- a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
+++ b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
@@ -568,6 +568,18 @@ public final class CraftMagicNumbers implements UnsafeValues {
diff --git a/patches/server/0675-Add-isCollidable-methods-to-various-places.patch b/patches/server/0675-Add-isCollidable-methods-to-various-places.patch
index 2cead6b67f..70fc349cfe 100644
--- a/patches/server/0675-Add-isCollidable-methods-to-various-places.patch
+++ b/patches/server/0675-Add-isCollidable-methods-to-various-places.patch
@@ -39,7 +39,7 @@ index b722a207c0e745bb172d93b90e1241d7bfa173ce..792bfc7eab33b26462e76a1912bd712e
+ // Paper end
}
diff --git a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
-index 78e1932852e002fc4d928ff9869678e308f9b7a4..ec3cb84a4ac59a27e194e66686273496276b80c4 100644
+index 53e40ab7d37ef707151c165831b24737a9f3683c..bbc3724769497e7687a27d800cd7511c5f1fe667 100644
--- a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
+++ b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
@@ -580,6 +580,12 @@ public final class CraftMagicNumbers implements UnsafeValues {
diff --git a/patches/server/0678-Add-Raw-Byte-Entity-Serialization.patch b/patches/server/0678-Add-Raw-Byte-Entity-Serialization.patch
index 3ea2d20740..b547dbbbe9 100644
--- a/patches/server/0678-Add-Raw-Byte-Entity-Serialization.patch
+++ b/patches/server/0678-Add-Raw-Byte-Entity-Serialization.patch
@@ -47,7 +47,7 @@ index 02dc40b6f7b82ce503c33fb4af26cbb20c9d5b7a..5fad5dbc0815ec3ee86a3fb34fe0c68b
// Paper end
}
diff --git a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
-index ec3cb84a4ac59a27e194e66686273496276b80c4..8f185a0b1a9037c1458b3ce41347e2c733e4d4de 100644
+index bbc3724769497e7687a27d800cd7511c5f1fe667..e8e26cca7fc8090a3b22925ae37e2362a44ced80 100644
--- a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
+++ b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
@@ -491,6 +491,29 @@ public final class CraftMagicNumbers implements UnsafeValues {
diff --git a/patches/server/0685-Allow-controlled-flushing-for-network-manager.patch b/patches/server/0685-Allow-controlled-flushing-for-network-manager.patch
index 0cecd8e3e4..fd7bf47eb3 100644
--- a/patches/server/0685-Allow-controlled-flushing-for-network-manager.patch
+++ b/patches/server/0685-Allow-controlled-flushing-for-network-manager.patch
@@ -9,10 +9,10 @@ This patch will be used to optimise out flush calls in later
patches.
diff --git a/src/main/java/net/minecraft/network/Connection.java b/src/main/java/net/minecraft/network/Connection.java
-index 1a6326ce5160b18ecbef26d719b0a207ccad2783..1cd00de0e55f99f0266ae2e720dbc16f218b6e20 100644
+index 0968827df66057ec73185ce688a62e8b27abba0c..95f5ec348ab24b28c19b46cea7b023a1d49998b5 100644
--- a/src/main/java/net/minecraft/network/Connection.java
+++ b/src/main/java/net/minecraft/network/Connection.java
-@@ -124,6 +124,39 @@ public class Connection extends SimpleChannelInboundHandler> {
+@@ -126,6 +126,39 @@ public class Connection extends SimpleChannelInboundHandler> {
public ConnectionProtocol protocol;
// Paper end
@@ -52,7 +52,7 @@ index 1a6326ce5160b18ecbef26d719b0a207ccad2783..1cd00de0e55f99f0266ae2e720dbc16f
public Connection(PacketFlow side) {
this.receiving = side;
}
-@@ -292,7 +325,7 @@ public class Connection extends SimpleChannelInboundHandler> {
+@@ -298,7 +331,7 @@ public class Connection extends SimpleChannelInboundHandler> {
io.papermc.paper.util.MCUtil.isMainThread() && packet.isReady() && this.queue.isEmpty() &&
(packet.getExtraPackets() == null || packet.getExtraPackets().isEmpty())
))) {
@@ -61,7 +61,7 @@ index 1a6326ce5160b18ecbef26d719b0a207ccad2783..1cd00de0e55f99f0266ae2e720dbc16f
return;
}
// write the packets to the queue, then flush - antixray hooks there already
-@@ -316,6 +349,14 @@ public class Connection extends SimpleChannelInboundHandler> {
+@@ -322,6 +355,14 @@ public class Connection extends SimpleChannelInboundHandler> {
}
private void sendPacket(Packet> packet, @Nullable PacketSendListener callbacks) {
@@ -76,7 +76,7 @@ index 1a6326ce5160b18ecbef26d719b0a207ccad2783..1cd00de0e55f99f0266ae2e720dbc16f
ConnectionProtocol enumprotocol = ConnectionProtocol.getProtocolForPacket(packet);
ConnectionProtocol enumprotocol1 = this.getCurrentProtocol();
-@@ -330,16 +371,21 @@ public class Connection extends SimpleChannelInboundHandler> {
+@@ -336,16 +377,21 @@ public class Connection extends SimpleChannelInboundHandler> {
}
if (this.channel.eventLoop().inEventLoop()) {
@@ -100,7 +100,7 @@ index 1a6326ce5160b18ecbef26d719b0a207ccad2783..1cd00de0e55f99f0266ae2e720dbc16f
if (packetState != currentState) {
this.setProtocol(packetState);
}
-@@ -353,7 +399,7 @@ public class Connection extends SimpleChannelInboundHandler> {
+@@ -359,7 +405,7 @@ public class Connection extends SimpleChannelInboundHandler> {
try {
// Paper end
@@ -109,7 +109,7 @@ index 1a6326ce5160b18ecbef26d719b0a207ccad2783..1cd00de0e55f99f0266ae2e720dbc16f
if (callbacks != null) {
channelfuture.addListener((future) -> {
-@@ -409,6 +455,10 @@ public class Connection extends SimpleChannelInboundHandler> {
+@@ -415,6 +461,10 @@ public class Connection extends SimpleChannelInboundHandler> {
private boolean processQueue() {
try { // Paper - add pending task queue
if (this.queue.isEmpty()) return true;
@@ -120,7 +120,7 @@ index 1a6326ce5160b18ecbef26d719b0a207ccad2783..1cd00de0e55f99f0266ae2e720dbc16f
// If we are on main, we are safe here in that nothing else should be processing queue off main anymore
// But if we are not on main due to login/status, the parent is synchronized on packetQueue
java.util.Iterator iterator = this.queue.iterator();
-@@ -416,7 +466,7 @@ public class Connection extends SimpleChannelInboundHandler> {
+@@ -422,7 +472,7 @@ public class Connection extends SimpleChannelInboundHandler> {
PacketHolder queued = iterator.next(); // poll -> peek
// Fix NPE (Spigot bug caused by handleDisconnection())
@@ -129,7 +129,7 @@ index 1a6326ce5160b18ecbef26d719b0a207ccad2783..1cd00de0e55f99f0266ae2e720dbc16f
return true;
}
-@@ -428,11 +478,17 @@ public class Connection extends SimpleChannelInboundHandler> {
+@@ -434,11 +484,17 @@ public class Connection extends SimpleChannelInboundHandler> {
Packet> packet = queued.packet;
if (!packet.isReady()) {
diff --git a/patches/server/0692-Detail-more-information-in-watchdog-dumps.patch b/patches/server/0692-Detail-more-information-in-watchdog-dumps.patch
index 48ecc20997..7c18ec69e5 100644
--- a/patches/server/0692-Detail-more-information-in-watchdog-dumps.patch
+++ b/patches/server/0692-Detail-more-information-in-watchdog-dumps.patch
@@ -7,10 +7,10 @@ Subject: [PATCH] Detail more information in watchdog dumps
- Dump player name, player uuid, position, and world for packet handling
diff --git a/src/main/java/net/minecraft/network/Connection.java b/src/main/java/net/minecraft/network/Connection.java
-index 1cd00de0e55f99f0266ae2e720dbc16f218b6e20..71cedd62689e721d71b47098ad52e63189748600 100644
+index 95f5ec348ab24b28c19b46cea7b023a1d49998b5..890d14503e157d6c07a6db1f180f49f81118e301 100644
--- a/src/main/java/net/minecraft/network/Connection.java
+++ b/src/main/java/net/minecraft/network/Connection.java
-@@ -522,7 +522,13 @@ public class Connection extends SimpleChannelInboundHandler> {
+@@ -528,7 +528,13 @@ public class Connection extends SimpleChannelInboundHandler> {
if (!(this.packetListener instanceof net.minecraft.server.network.ServerLoginPacketListenerImpl loginPacketListener)
|| loginPacketListener.state != net.minecraft.server.network.ServerLoginPacketListenerImpl.State.READY_TO_ACCEPT
|| Connection.joinAttemptsThisTick++ < MAX_PER_TICK) {
diff --git a/patches/server/0697-Add-packet-limiter-config.patch b/patches/server/0697-Add-packet-limiter-config.patch
index 52e12fb5a0..4e51d69d3a 100644
--- a/patches/server/0697-Add-packet-limiter-config.patch
+++ b/patches/server/0697-Add-packet-limiter-config.patch
@@ -24,10 +24,10 @@ and an action can be defined: DROP or KICK
If interval or rate are less-than 0, the limit is ignored
diff --git a/src/main/java/net/minecraft/network/Connection.java b/src/main/java/net/minecraft/network/Connection.java
-index 71cedd62689e721d71b47098ad52e63189748600..1690626b8a62e078ce23e725c0384983af9c9e23 100644
+index 890d14503e157d6c07a6db1f180f49f81118e301..347e1da7b5b890c297863736e62a8c225b112db2 100644
--- a/src/main/java/net/minecraft/network/Connection.java
+++ b/src/main/java/net/minecraft/network/Connection.java
-@@ -156,6 +156,22 @@ public class Connection extends SimpleChannelInboundHandler> {
+@@ -158,6 +158,22 @@ public class Connection extends SimpleChannelInboundHandler> {
}
}
// Paper end - allow controlled flushing
@@ -50,7 +50,7 @@ index 71cedd62689e721d71b47098ad52e63189748600..1690626b8a62e078ce23e725c0384983
public Connection(PacketFlow side) {
this.receiving = side;
-@@ -240,6 +256,45 @@ public class Connection extends SimpleChannelInboundHandler> {
+@@ -246,6 +262,45 @@ public class Connection extends SimpleChannelInboundHandler> {
protected void channelRead0(ChannelHandlerContext channelhandlercontext, Packet> packet) {
if (this.channel.isOpen()) {
diff --git a/patches/server/0707-Optimise-non-flush-packet-sending.patch b/patches/server/0707-Optimise-non-flush-packet-sending.patch
index fdc4b312bf..f9efebf60a 100644
--- a/patches/server/0707-Optimise-non-flush-packet-sending.patch
+++ b/patches/server/0707-Optimise-non-flush-packet-sending.patch
@@ -20,10 +20,10 @@ up on this optimisation before he came along.
Locally this patch drops the entity tracker tick by a full 1.5x.
diff --git a/src/main/java/net/minecraft/network/Connection.java b/src/main/java/net/minecraft/network/Connection.java
-index 1690626b8a62e078ce23e725c0384983af9c9e23..bff8267b72f5e4a0530055ee58add657fa553dcd 100644
+index 347e1da7b5b890c297863736e62a8c225b112db2..5237eb10ca12f786bba66f5db2a2553fa10ffe62 100644
--- a/src/main/java/net/minecraft/network/Connection.java
+++ b/src/main/java/net/minecraft/network/Connection.java
-@@ -428,9 +428,19 @@ public class Connection extends SimpleChannelInboundHandler> {
+@@ -434,9 +434,19 @@ public class Connection extends SimpleChannelInboundHandler> {
if (this.channel.eventLoop().inEventLoop()) {
this.doSendPacket(packet, callbacks, enumprotocol, enumprotocol1, flush); // Paper
} else {
diff --git a/patches/server/0710-Use-Velocity-compression-and-cipher-natives.patch b/patches/server/0710-Use-Velocity-compression-and-cipher-natives.patch
index 49eaa6b1a0..e8388c5724 100644
--- a/patches/server/0710-Use-Velocity-compression-and-cipher-natives.patch
+++ b/patches/server/0710-Use-Velocity-compression-and-cipher-natives.patch
@@ -5,7 +5,7 @@ Subject: [PATCH] Use Velocity compression and cipher natives
diff --git a/build.gradle.kts b/build.gradle.kts
-index b65278b9addf9a26b0f63975f439d333fd3fdf87..23782232e4d334502721b8fd1d69f5e916624f14 100644
+index 96866069c69ce230ea499ac7208f98627c081586..f49355493f2637b0b508ba5a685fd88caf239655 100644
--- a/build.gradle.kts
+++ b/build.gradle.kts
@@ -32,6 +32,11 @@ dependencies {
@@ -268,10 +268,10 @@ index 792883afe53d2b7989c25a81c2f9a639d5e21d20..c04379ca8a4db0f4de46ad2b3b338431
return this.threshold;
}
diff --git a/src/main/java/net/minecraft/network/Connection.java b/src/main/java/net/minecraft/network/Connection.java
-index bff8267b72f5e4a0530055ee58add657fa553dcd..c45c1d519aba414557bf1a4c9260f928bd8d9b14 100644
+index 5237eb10ca12f786bba66f5db2a2553fa10ffe62..1b634b303105a0f8424e1e40b7c39f9938232d95 100644
--- a/src/main/java/net/minecraft/network/Connection.java
+++ b/src/main/java/net/minecraft/network/Connection.java
-@@ -708,11 +708,28 @@ public class Connection extends SimpleChannelInboundHandler> {
+@@ -724,11 +724,28 @@ public class Connection extends SimpleChannelInboundHandler> {
return networkmanager;
}
@@ -304,7 +304,7 @@ index bff8267b72f5e4a0530055ee58add657fa553dcd..c45c1d519aba414557bf1a4c9260f928
public boolean isEncrypted() {
return this.encrypted;
-@@ -744,16 +761,17 @@ public class Connection extends SimpleChannelInboundHandler> {
+@@ -760,16 +777,17 @@ public class Connection extends SimpleChannelInboundHandler> {
public void setupCompression(int compressionThreshold, boolean rejectsBadPackets) {
if (compressionThreshold >= 0) {
diff --git a/patches/server/0827-Add-support-for-Proxy-Protocol.patch b/patches/server/0827-Add-support-for-Proxy-Protocol.patch
index c117b9d366..36b9f115e5 100644
--- a/patches/server/0827-Add-support-for-Proxy-Protocol.patch
+++ b/patches/server/0827-Add-support-for-Proxy-Protocol.patch
@@ -5,7 +5,7 @@ Subject: [PATCH] Add support for Proxy Protocol
diff --git a/build.gradle.kts b/build.gradle.kts
-index 23782232e4d334502721b8fd1d69f5e916624f14..2d5bf482a59e8b8b8b2a8579ce1c499d800dd734 100644
+index f49355493f2637b0b508ba5a685fd88caf239655..a0c5592530d2a59bfde87d1e9eb3752e7d4694da 100644
--- a/build.gradle.kts
+++ b/build.gradle.kts
@@ -21,6 +21,7 @@ dependencies {
diff --git a/patches/server/0863-Add-NamespacedKey-biome-methods.patch b/patches/server/0863-Add-NamespacedKey-biome-methods.patch
index c342bdded1..e03f769d70 100644
--- a/patches/server/0863-Add-NamespacedKey-biome-methods.patch
+++ b/patches/server/0863-Add-NamespacedKey-biome-methods.patch
@@ -6,7 +6,7 @@ Subject: [PATCH] Add NamespacedKey biome methods
Co-authored-by: Thonk <30448663+ExcessiveAmountsOfZombies@users.noreply.github.com>
diff --git a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
-index 8f185a0b1a9037c1458b3ce41347e2c733e4d4de..8092db9de43ca4824374e1a76c85f71929521f6d 100644
+index e8e26cca7fc8090a3b22925ae37e2362a44ced80..83cef5ec27c31f133a23cd27349f722799c786ea 100644
--- a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
+++ b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
@@ -609,6 +609,19 @@ public final class CraftMagicNumbers implements UnsafeValues {
diff --git a/work/BuildData b/work/BuildData
index 2881c6b6dd..faff587dcb 160000
--- a/work/BuildData
+++ b/work/BuildData
@@ -1 +1 @@
-Subproject commit 2881c6b6dd146126596342d4025d37a9a84a0b03
+Subproject commit faff587dcbe915bc565bf01f2d54c6af86039414
diff --git a/work/Bukkit b/work/Bukkit
index 54e8ec7b47..f1dd65ed73 160000
--- a/work/Bukkit
+++ b/work/Bukkit
@@ -1 +1 @@
-Subproject commit 54e8ec7b47ec9a77e05d44d8898a0f247c8db046
+Subproject commit f1dd65ed73b7cca00527ff81d02ce4d27c456a37
diff --git a/work/CraftBukkit b/work/CraftBukkit
index 6962456f98..9c5d600d13 160000
--- a/work/CraftBukkit
+++ b/work/CraftBukkit
@@ -1 +1 @@
-Subproject commit 6962456f98f6e5075c8bf6dff772f3c2464ae60e
+Subproject commit 9c5d600d1395e9783a8369dc4227be2b05010107
diff --git a/work/Spigot b/work/Spigot
index 7e2af8b2d6..bed8c61f55 160000
--- a/work/Spigot
+++ b/work/Spigot
@@ -1 +1 @@
-Subproject commit 7e2af8b2d6af54e66edd030abbf12359a8574e05
+Subproject commit bed8c61f55c6af77ae202c57842de8899bc8a59b