From cb6f029de9c216420683027566b26c7ee8034444 Mon Sep 17 00:00:00 2001 From: Nassim Jahnke Date: Thu, 28 Jul 2022 00:10:27 +0200 Subject: [PATCH] More compile fixed --- patches/server/0008-Adventure.patch | 25 +++++++++++-------- patches/server/0012-Timings-v2.patch | 6 ++--- .../0084-Configurable-Player-Collision.patch | 8 +++--- .../0123-Enforce-Sync-Player-Saves.patch | 4 +-- ...le-async-calls-to-restart-the-server.patch | 4 +-- .../0148-ProfileWhitelistVerifyEvent.patch | 6 ++--- .../0215-InventoryCloseEvent-Reason-API.patch | 6 ++--- ...39-Use-ConcurrentHashMap-in-JsonList.patch | 4 +-- ...oggleEvent-when-whitelist-is-toggled.patch | 4 +-- .../0306-Entity-getEntitySpawnReason.patch | 4 +-- ...309-Implement-PlayerPostRespawnEvent.patch | 8 +++--- patches/server/0330-Fix-MC-158900.patch | 4 +-- ...ptimize-Collision-to-not-load-chunks.patch | 4 +-- .../0385-Improved-Watchdog-Support.patch | 4 +-- ...g-Broken-behavior-of-PlayerJoinEvent.patch | 10 ++++---- ...Load-Chunks-for-Login-Asynchronously.patch | 14 +++++------ ...-incremental-chunk-and-player-saving.patch | 6 ++--- patches/server/0467-Fix-SPIGOT-5989.patch | 10 ++++---- .../server/0522-Add-API-for-quit-reason.patch | 8 +++--- .../0524-Expose-world-spawn-angle.patch | 4 +-- .../0567-Fix-villager-boat-exploit.patch | 4 +-- patches/server/0568-Add-sendOpLevel-API.patch | 6 ++--- ...ed-item-when-player-has-disconnected.patch | 4 +-- ...wn-acting-as-a-bed-respawn-from-the-.patch | 8 +++--- ...d-RespawnFlags-to-PlayerRespawnEvent.patch | 8 +++--- .../0656-Add-PlayerKickEvent-causes.patch | 8 +++--- ...k-event-leave-message-not-being-sent.patch | 8 +++--- .../server/0692-Add-PlayerSetSpawnEvent.patch | 4 +-- ...single-and-multi-AABB-VoxelShapes-an.patch | 4 +-- patches/server/0823-Validate-usernames.patch | 4 +-- ...6-Replace-player-chunk-loader-system.patch | 10 ++++---- ...858-Force-close-world-loading-screen.patch | 4 +-- ...ix-swamp-hut-cat-generation-deadlock.patch | 4 +-- ...tead-of-display-name-in-PlayerList-g.patch | 4 +-- 34 files changed, 113 insertions(+), 110 deletions(-) diff --git a/patches/server/0008-Adventure.patch b/patches/server/0008-Adventure.patch index e120a4a40..a46e4a8b3 100644 --- a/patches/server/0008-Adventure.patch +++ b/patches/server/0008-Adventure.patch @@ -1606,7 +1606,7 @@ index 3a587073dbe5e8a599d342c5f758d842b7b6cddb..a426adfba3fccf1815177e0b8065684c @Override diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java -index ba6f4e9f74a524201390bd0e9106a6cf6afe0375..8a015bc9009fbd4877231777b1c6cdc4ae0124be 100644 +index ba6f4e9f74a524201390bd0e9106a6cf6afe0375..946b2b7341a10c25fae71d76f7b181b555fe38b6 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java @@ -8,6 +8,7 @@ import com.mojang.logging.LogUtils; @@ -1626,7 +1626,7 @@ index ba6f4e9f74a524201390bd0e9106a6cf6afe0375..8a015bc9009fbd4877231777b1c6cdc4 playerconnection.teleport(player.getX(), player.getY(), player.getZ(), player.getYRot(), player.getXRot()); this.players.add(player); -@@ -278,16 +279,18 @@ public abstract class PlayerList { +@@ -278,19 +279,18 @@ public abstract class PlayerList { // Ensure that player inventory is populated with its viewer player.containerMenu.transferTo(player.containerMenu, bukkitPlayer); @@ -1642,13 +1642,16 @@ index ba6f4e9f74a524201390bd0e9106a6cf6afe0375..8a015bc9009fbd4877231777b1c6cdc4 + final net.kyori.adventure.text.Component jm = playerJoinEvent.joinMessage(); - if (joinMessage != null && joinMessage.length() > 0) { +- for (Component line : org.bukkit.craftbukkit.util.CraftChatMessage.fromString(joinMessage)) { +- this.server.getPlayerList().broadcastSystemMessage(line, false); +- } + if (jm != null && !jm.equals(net.kyori.adventure.text.Component.empty())) { // Paper - Adventure + joinMessage = PaperAdventure.asVanilla(jm); // Paper - Adventure + this.server.getPlayerList().broadcastSystemMessage(joinMessage, false); // Paper - Adventure - for (Component line : org.bukkit.craftbukkit.util.CraftChatMessage.fromString(joinMessage)) { - this.server.getPlayerList().broadcastSystemMessage(line, false); - } -@@ -487,7 +490,7 @@ public abstract class PlayerList { + } + // CraftBukkit end + +@@ -487,7 +487,7 @@ public abstract class PlayerList { } @@ -1657,7 +1660,7 @@ index ba6f4e9f74a524201390bd0e9106a6cf6afe0375..8a015bc9009fbd4877231777b1c6cdc4 ServerLevel worldserver = entityplayer.getLevel(); entityplayer.awardStat(Stats.LEAVE_GAME); -@@ -498,7 +501,7 @@ public abstract class PlayerList { +@@ -498,7 +498,7 @@ public abstract class PlayerList { entityplayer.closeContainer(); } @@ -1666,7 +1669,7 @@ index ba6f4e9f74a524201390bd0e9106a6cf6afe0375..8a015bc9009fbd4877231777b1c6cdc4 this.cserver.getPluginManager().callEvent(playerQuitEvent); entityplayer.getBukkitEntity().disconnect(playerQuitEvent.getQuitMessage()); -@@ -551,7 +554,7 @@ public abstract class PlayerList { +@@ -551,7 +551,7 @@ public abstract class PlayerList { this.cserver.getScoreboardManager().removePlayer(entityplayer.getBukkitEntity()); // CraftBukkit end @@ -1675,7 +1678,7 @@ index ba6f4e9f74a524201390bd0e9106a6cf6afe0375..8a015bc9009fbd4877231777b1c6cdc4 } // CraftBukkit start - Whole method, SocketAddress to LoginListener, added hostname to signature, return EntityPlayer -@@ -597,10 +600,10 @@ public abstract class PlayerList { +@@ -597,10 +597,10 @@ public abstract class PlayerList { } // return chatmessage; @@ -1688,7 +1691,7 @@ index ba6f4e9f74a524201390bd0e9106a6cf6afe0375..8a015bc9009fbd4877231777b1c6cdc4 } else if (this.getIpBans().isBanned(socketaddress) && !this.getIpBans().get(socketaddress).hasExpired()) { IpBanListEntry ipbanentry = this.ipBans.get(socketaddress); -@@ -610,17 +613,17 @@ public abstract class PlayerList { +@@ -610,17 +610,17 @@ public abstract class PlayerList { } // return chatmessage; @@ -1709,7 +1712,7 @@ index ba6f4e9f74a524201390bd0e9106a6cf6afe0375..8a015bc9009fbd4877231777b1c6cdc4 return null; } return entity; -@@ -1128,7 +1131,7 @@ public abstract class PlayerList { +@@ -1128,7 +1128,7 @@ public abstract class PlayerList { public void removeAll() { // CraftBukkit start - disconnect safely for (ServerPlayer player : this.players) { diff --git a/patches/server/0012-Timings-v2.patch b/patches/server/0012-Timings-v2.patch index 17a8c3bd9..958cbe6c7 100644 --- a/patches/server/0012-Timings-v2.patch +++ b/patches/server/0012-Timings-v2.patch @@ -1262,7 +1262,7 @@ index 95c3273d2379509cf6cd51a718f18b8697908932..1d4d60fa861b5e819c59f06168a09668 this.entityManager.saveAll(); } else { diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 11e4dc3d8fbe48b5ec9d771a851f0ac69694e394..fda4d570ef04e91c4e6c29c52221c04937dc4fbc 100644 +index 59932a4f83461280ab3c097add951e5a138eb53d..4bdb7b50315c68a3f3c929745bf090f5c7a51c52 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java @@ -339,7 +339,6 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic @@ -1309,7 +1309,7 @@ index 11e4dc3d8fbe48b5ec9d771a851f0ac69694e394..fda4d570ef04e91c4e6c29c52221c049 } // 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 8a015bc9009fbd4877231777b1c6cdc4ae0124be..bffd4efcbe50609b134b2bf498dc393e7ef70850 100644 +index 946b2b7341a10c25fae71d76f7b181b555fe38b6..e3e9758827e741a9140c650dafa411144f26e672 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java @@ -1,5 +1,6 @@ @@ -1319,7 +1319,7 @@ index 8a015bc9009fbd4877231777b1c6cdc4ae0124be..bffd4efcbe50609b134b2bf498dc393e import com.google.common.collect.Lists; import com.google.common.collect.Maps; import com.google.common.collect.Sets; -@@ -1021,10 +1022,11 @@ public abstract class PlayerList { +@@ -1018,10 +1019,11 @@ public abstract class PlayerList { } public void saveAll() { diff --git a/patches/server/0084-Configurable-Player-Collision.patch b/patches/server/0084-Configurable-Player-Collision.patch index 7f59a68e2..6a8a20af7 100644 --- a/patches/server/0084-Configurable-Player-Collision.patch +++ b/patches/server/0084-Configurable-Player-Collision.patch @@ -43,7 +43,7 @@ index 00424041950529973eaf33f4d312dbd1038ae675..0dffb6e8d6f4edfb4dfaa6b24e81d723 this.server.getPluginManager().callEvent(new ServerLoadEvent(ServerLoadEvent.LoadType.STARTUP)); this.connection.acceptConnections(); diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java -index 28c136fe37afeda1b43523a17a46a115f1dbf3f3..029e537c129dd19039ac30065f3319558d30ba64 100644 +index b2a47e33a0503c79d10f8979391f7dfa4b619b28..b4f29bed0332489ccae54cfb7a7f90e4df89743f 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java @@ -94,6 +94,7 @@ import net.minecraft.world.level.storage.PlayerDataStorage; @@ -62,7 +62,7 @@ index 28c136fe37afeda1b43523a17a46a115f1dbf3f3..029e537c129dd19039ac30065f331955 public PlayerList(MinecraftServer server, RegistryAccess.Frozen registryManager, PlayerDataStorage saveHandler, int maxPlayers) { this.cserver = server.server = new CraftServer((DedicatedServer) server, this); -@@ -393,6 +395,13 @@ public abstract class PlayerList { +@@ -390,6 +392,13 @@ public abstract class PlayerList { player.initInventoryMenu(); // CraftBukkit - Moved from above, added world @@ -76,7 +76,7 @@ index 28c136fe37afeda1b43523a17a46a115f1dbf3f3..029e537c129dd19039ac30065f331955 PlayerList.LOGGER.info("{}[{}] logged in with entity id {} at ([{}]{}, {}, {})", player.getName().getString(), s1, player.getId(), worldserver1.serverLevelData.getLevelName(), player.getX(), player.getY(), player.getZ()); } -@@ -512,6 +521,16 @@ public abstract class PlayerList { +@@ -509,6 +518,16 @@ public abstract class PlayerList { entityplayer.doTick(); // SPIGOT-924 // CraftBukkit end @@ -93,7 +93,7 @@ index 28c136fe37afeda1b43523a17a46a115f1dbf3f3..029e537c129dd19039ac30065f331955 this.save(entityplayer); if (entityplayer.isPassenger()) { Entity entity = entityplayer.getRootVehicle(); -@@ -1140,6 +1159,13 @@ public abstract class PlayerList { +@@ -1137,6 +1156,13 @@ public abstract class PlayerList { } // CraftBukkit end diff --git a/patches/server/0123-Enforce-Sync-Player-Saves.patch b/patches/server/0123-Enforce-Sync-Player-Saves.patch index f4bb2c348..a514731ac 100644 --- a/patches/server/0123-Enforce-Sync-Player-Saves.patch +++ b/patches/server/0123-Enforce-Sync-Player-Saves.patch @@ -7,10 +7,10 @@ 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 029e537c129dd19039ac30065f3319558d30ba64..c0541a83881a3329577897e6c4f3009db17aca4a 100644 +index b4f29bed0332489ccae54cfb7a7f90e4df89743f..23687ae4a06be741a82cec1178d891aed4640084 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -1044,11 +1044,13 @@ public abstract class PlayerList { +@@ -1041,11 +1041,13 @@ public abstract class PlayerList { } public void saveAll() { diff --git a/patches/server/0130-Properly-handle-async-calls-to-restart-the-server.patch b/patches/server/0130-Properly-handle-async-calls-to-restart-the-server.patch index dfe13c040..b07682fbd 100644 --- a/patches/server/0130-Properly-handle-async-calls-to-restart-the-server.patch +++ b/patches/server/0130-Properly-handle-async-calls-to-restart-the-server.patch @@ -64,10 +64,10 @@ index f3f528cc7f07da69c45e4290de098c0443c7a952..41928abfffbf6102e92cb45532e691b3 if (flag) { try { diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java -index c0541a83881a3329577897e6c4f3009db17aca4a..4d029c6beb0637f87d1d0a265e00b2d5be677b6c 100644 +index 23687ae4a06be741a82cec1178d891aed4640084..03a19b3869eea9a59f4003a81ab488603347cd4a 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -1155,8 +1155,15 @@ public abstract class PlayerList { +@@ -1152,8 +1152,15 @@ public abstract class PlayerList { } public void removeAll() { diff --git a/patches/server/0148-ProfileWhitelistVerifyEvent.patch b/patches/server/0148-ProfileWhitelistVerifyEvent.patch index 7ffeae25c..fbd026ca4 100644 --- a/patches/server/0148-ProfileWhitelistVerifyEvent.patch +++ b/patches/server/0148-ProfileWhitelistVerifyEvent.patch @@ -5,10 +5,10 @@ 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 2e583b600e7a7ef94639a27ce719effcf0b9e141..2b633053c56098c4046abe17c23ee2cb76e84887 100644 +index 258eee0f5310224b089895745ff11e482fc36dca..29f761432be28b5089caab9338b3bff41f4f8f07 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -623,9 +623,9 @@ public abstract class PlayerList { +@@ -620,9 +620,9 @@ public abstract class PlayerList { // return chatmessage; event.disallow(PlayerLoginEvent.Result.KICK_BANNED, PaperAdventure.asAdventure(ichatmutablecomponent)); // Paper - Adventure @@ -21,7 +21,7 @@ index 2e583b600e7a7ef94639a27ce719effcf0b9e141..2b633053c56098c4046abe17c23ee2cb } else if (this.getIpBans().isBanned(socketaddress) && !this.getIpBans().get(socketaddress).hasExpired()) { IpBanListEntry ipbanentry = this.ipBans.get(socketaddress); -@@ -1007,7 +1007,23 @@ public abstract class PlayerList { +@@ -1004,7 +1004,23 @@ public abstract class PlayerList { } public boolean isWhiteListed(GameProfile profile) { diff --git a/patches/server/0215-InventoryCloseEvent-Reason-API.patch b/patches/server/0215-InventoryCloseEvent-Reason-API.patch index 72c1a4931..7836ddeb4 100644 --- a/patches/server/0215-InventoryCloseEvent-Reason-API.patch +++ b/patches/server/0215-InventoryCloseEvent-Reason-API.patch @@ -75,7 +75,7 @@ index a9497e21c87e785631788968bc4922f6261169f9..522c8791edd87feb6cb32ef8e621ae35 this.doCloseContainer(); } diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 78662c29e9771ddead43dc243fb5f7d802d6d40d..0e323c2acd447f0cd41d8afbc80f7fa20f03ca72 100644 +index 4e8dbad3ce78e90f71990de3c21164989280280f..0cbca2deb19f523210b0f67884872662c5baab9b 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java @@ -216,6 +216,7 @@ import org.bukkit.event.inventory.ClickType; @@ -104,10 +104,10 @@ index 78662c29e9771ddead43dc243fb5f7d802d6d40d..0e323c2acd447f0cd41d8afbc80f7fa2 this.player.doCloseContainer(); } diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java -index 2b633053c56098c4046abe17c23ee2cb76e84887..d88ba2e702e7e5d32388057bb8f77689b641ffde 100644 +index 29f761432be28b5089caab9338b3bff41f4f8f07..2ad88d72a9d14c7e73a824544a1ebcb6bb74a127 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -510,7 +510,7 @@ public abstract class PlayerList { +@@ -507,7 +507,7 @@ public abstract class PlayerList { // CraftBukkit start - Quitting must be before we do final save of data, in case plugins need to modify it // See SPIGOT-5799, SPIGOT-6145 if (entityplayer.containerMenu != entityplayer.inventoryMenu) { diff --git a/patches/server/0239-Use-ConcurrentHashMap-in-JsonList.patch b/patches/server/0239-Use-ConcurrentHashMap-in-JsonList.patch index 2e75ad3f1..15c2ad2fd 100644 --- a/patches/server/0239-Use-ConcurrentHashMap-in-JsonList.patch +++ b/patches/server/0239-Use-ConcurrentHashMap-in-JsonList.patch @@ -23,10 +23,10 @@ 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 d88ba2e702e7e5d32388057bb8f77689b641ffde..f181ee0db6c25eee07d2750ebe35b97b586c8c35 100644 +index 2ad88d72a9d14c7e73a824544a1ebcb6bb74a127..734a7b101e5ac9ac4ceb0ba3cb74b94bf2c18683 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -626,7 +626,7 @@ public abstract class PlayerList { +@@ -623,7 +623,7 @@ public abstract class PlayerList { } else if (!this.isWhiteListed(gameprofile, event)) { // Paper //ichatmutablecomponent = Component.translatable("multiplayer.disconnect.not_whitelisted"); // Paper //event.disallow(PlayerLoginEvent.Result.KICK_WHITELIST, net.kyori.adventure.text.serializer.legacy.LegacyComponentSerializer.legacySection().deserialize(org.spigotmc.SpigotConfig.whitelistMessage)); // Spigot // Paper - Adventure - moved to isWhitelisted diff --git a/patches/server/0305-Call-WhitelistToggleEvent-when-whitelist-is-toggled.patch b/patches/server/0305-Call-WhitelistToggleEvent-when-whitelist-is-toggled.patch index f475fb82c..530d74227 100644 --- a/patches/server/0305-Call-WhitelistToggleEvent-when-whitelist-is-toggled.patch +++ b/patches/server/0305-Call-WhitelistToggleEvent-when-whitelist-is-toggled.patch @@ -5,10 +5,10 @@ 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 c3d797f0f57dfb065ba4ea594fbae734b1066318..bbce7c04a9ec77c82f76f86263766d33ceea1ede 100644 +index f6f086d1e5f08e5beae142685cfb682b8e5683f1..cf344d87a31d03d87be1df38b772b5301f53e7e7 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -1131,6 +1131,7 @@ public abstract class PlayerList { +@@ -1128,6 +1128,7 @@ public abstract class PlayerList { } public void setUsingWhiteList(boolean whitelistEnabled) { diff --git a/patches/server/0306-Entity-getEntitySpawnReason.patch b/patches/server/0306-Entity-getEntitySpawnReason.patch index a18b6fd66..7fcb95db6 100644 --- a/patches/server/0306-Entity-getEntitySpawnReason.patch +++ b/patches/server/0306-Entity-getEntitySpawnReason.patch @@ -22,10 +22,10 @@ index 293657617c32acfe70b0ab98939135e5ac6dae28..6ba45e1322b0d04433b2aac23413a9cd // Paper start if (DEBUG_ENTITIES) { diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java -index bbce7c04a9ec77c82f76f86263766d33ceea1ede..7fc546e38c68a173208d62a8d0944c915b6df44a 100644 +index cf344d87a31d03d87be1df38b772b5301f53e7e7..9ef845190b47263da8e89c4269d613f6cbf74535 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -350,7 +350,7 @@ public abstract class PlayerList { +@@ -347,7 +347,7 @@ public abstract class PlayerList { // CraftBukkit start ServerLevel finalWorldServer = worldserver1; Entity entity = EntityType.loadEntityRecursive(nbttagcompound1.getCompound("Entity"), finalWorldServer, (entity1) -> { diff --git a/patches/server/0309-Implement-PlayerPostRespawnEvent.patch b/patches/server/0309-Implement-PlayerPostRespawnEvent.patch index a86d0197c..515beb067 100644 --- a/patches/server/0309-Implement-PlayerPostRespawnEvent.patch +++ b/patches/server/0309-Implement-PlayerPostRespawnEvent.patch @@ -5,10 +5,10 @@ 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 7fc546e38c68a173208d62a8d0944c915b6df44a..3d16541cc8e2d9db49fc95a0b640bdbbda8d56e2 100644 +index 9ef845190b47263da8e89c4269d613f6cbf74535..8c7286176b96bcd6640a78255e0effc22ce06457 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -730,9 +730,14 @@ public abstract class PlayerList { +@@ -727,9 +727,14 @@ public abstract class PlayerList { boolean flag2 = false; @@ -24,7 +24,7 @@ index 7fc546e38c68a173208d62a8d0944c915b6df44a..3d16541cc8e2d9db49fc95a0b640bdbb ServerLevel worldserver1 = this.server.getLevel(entityplayer.getRespawnDimension()); if (worldserver1 != null) { Optional optional; -@@ -784,6 +789,7 @@ public abstract class PlayerList { +@@ -781,6 +786,7 @@ public abstract class PlayerList { location = respawnEvent.getRespawnLocation(); if (!flag) entityplayer.reset(); // SPIGOT-4785 @@ -32,7 +32,7 @@ index 7fc546e38c68a173208d62a8d0944c915b6df44a..3d16541cc8e2d9db49fc95a0b640bdbb } else { location.setWorld(worldserver.getWorld()); } -@@ -841,6 +847,13 @@ public abstract class PlayerList { +@@ -838,6 +844,13 @@ public abstract class PlayerList { if (entityplayer.connection.isDisconnected()) { this.save(entityplayer); } diff --git a/patches/server/0330-Fix-MC-158900.patch b/patches/server/0330-Fix-MC-158900.patch index 21fda3256..85e032c5c 100644 --- a/patches/server/0330-Fix-MC-158900.patch +++ b/patches/server/0330-Fix-MC-158900.patch @@ -7,10 +7,10 @@ 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 3d16541cc8e2d9db49fc95a0b640bdbbda8d56e2..be1bdcc99b3f2cc1103bce4ecdc5077bec6a1e85 100644 +index 8c7286176b96bcd6640a78255e0effc22ce06457..6f14cf3546cb0db210e39a918799c3df7998eb1d 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -614,8 +614,10 @@ public abstract class PlayerList { +@@ -611,8 +611,10 @@ public abstract class PlayerList { Player player = entity.getBukkitEntity(); PlayerLoginEvent event = new PlayerLoginEvent(player, hostname, ((java.net.InetSocketAddress) socketaddress).getAddress(), ((java.net.InetSocketAddress) loginlistener.connection.getRawAddress()).getAddress()); diff --git a/patches/server/0382-Optimize-Collision-to-not-load-chunks.patch b/patches/server/0382-Optimize-Collision-to-not-load-chunks.patch index 7682d105c..eb42523c1 100644 --- a/patches/server/0382-Optimize-Collision-to-not-load-chunks.patch +++ b/patches/server/0382-Optimize-Collision-to-not-load-chunks.patch @@ -14,10 +14,10 @@ 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 be1bdcc99b3f2cc1103bce4ecdc5077bec6a1e85..f1bbfb0acbe79304b2e1c10221bc31b162e63959 100644 +index 6f14cf3546cb0db210e39a918799c3df7998eb1d..0d9ccaafd69e00ab094c1d291a195214880aeb91 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -799,6 +799,7 @@ public abstract class PlayerList { +@@ -796,6 +796,7 @@ public abstract class PlayerList { entityplayer1.forceSetPositionRotation(location.getX(), location.getY(), location.getZ(), location.getYaw(), location.getPitch()); // CraftBukkit end diff --git a/patches/server/0385-Improved-Watchdog-Support.patch b/patches/server/0385-Improved-Watchdog-Support.patch index 480c89b90..6d44480b4 100644 --- a/patches/server/0385-Improved-Watchdog-Support.patch +++ b/patches/server/0385-Improved-Watchdog-Support.patch @@ -281,10 +281,10 @@ index dab266e62f837e0efe57c0c4ae33b84c553c969c..48fc5d6ca854de036013586be634b3e0 list.stream().map((playerchunk) -> { CompletableFuture completablefuture; diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java -index ca89bb5bf4de85ca22b004c91f2c7501bb133c55..73d22c0f5f2998050de8a231677639c60f535229 100644 +index d67362983816db2b264d30b59423b05843cded16..f5f536549d7daf14ed5f678a55969c540a5dc48d 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -520,7 +520,7 @@ public abstract class PlayerList { +@@ -517,7 +517,7 @@ public abstract class PlayerList { this.cserver.getPluginManager().callEvent(playerQuitEvent); entityplayer.getBukkitEntity().disconnect(playerQuitEvent.getQuitMessage()); diff --git a/patches/server/0395-Fix-Longstanding-Broken-behavior-of-PlayerJoinEvent.patch b/patches/server/0395-Fix-Longstanding-Broken-behavior-of-PlayerJoinEvent.patch index 0ac56f4db..0cb0f66de 100644 --- a/patches/server/0395-Fix-Longstanding-Broken-behavior-of-PlayerJoinEvent.patch +++ b/patches/server/0395-Fix-Longstanding-Broken-behavior-of-PlayerJoinEvent.patch @@ -52,7 +52,7 @@ index db8400c7ca9aad9aeee192427661c76778bf9e47..3a40d6fe9edbd997dc9a6b8ac009c3f6 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 73d22c0f5f2998050de8a231677639c60f535229..b33a7cf936fec6c1c4d39f6c156d3e6fefa3e795 100644 +index f5f536549d7daf14ed5f678a55969c540a5dc48d..1f32ba033eedcb69b02c29da8594be9edf958f43 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java @@ -281,6 +281,12 @@ public abstract class PlayerList { @@ -68,7 +68,7 @@ index 73d22c0f5f2998050de8a231677639c60f535229..b33a7cf936fec6c1c4d39f6c156d3e6f // CraftBukkit start CraftPlayer bukkitPlayer = player.getBukkitEntity(); -@@ -322,6 +328,8 @@ public abstract class PlayerList { +@@ -319,6 +325,8 @@ public abstract class PlayerList { player.connection.send(new ClientboundPlayerInfoPacket(ClientboundPlayerInfoPacket.Action.ADD_PLAYER, new ServerPlayer[]{entityplayer1})); } player.sentListPacket = true; @@ -77,7 +77,7 @@ index 73d22c0f5f2998050de8a231677639c60f535229..b33a7cf936fec6c1c4d39f6c156d3e6f // CraftBukkit end player.connection.send(new ClientboundSetEntityDataPacket(player.getId(), player.getEntityData(), true)); // CraftBukkit - BungeeCord#2321, send complete data to self on spawn -@@ -347,6 +355,11 @@ public abstract class PlayerList { +@@ -344,6 +352,11 @@ public abstract class PlayerList { playerconnection.send(new ClientboundUpdateMobEffectPacket(player.getId(), mobeffect)); } @@ -89,7 +89,7 @@ index 73d22c0f5f2998050de8a231677639c60f535229..b33a7cf936fec6c1c4d39f6c156d3e6f if (nbttagcompound != null && nbttagcompound.contains("RootVehicle", 10)) { CompoundTag nbttagcompound1 = nbttagcompound.getCompound("RootVehicle"); // CraftBukkit start -@@ -395,6 +408,10 @@ public abstract class PlayerList { +@@ -392,6 +405,10 @@ public abstract class PlayerList { } } @@ -100,7 +100,7 @@ index 73d22c0f5f2998050de8a231677639c60f535229..b33a7cf936fec6c1c4d39f6c156d3e6f player.initInventoryMenu(); // CraftBukkit - Moved from above, added world // Paper start - Add to collideRule team if needed -@@ -404,6 +421,7 @@ public abstract class PlayerList { +@@ -401,6 +418,7 @@ public abstract class PlayerList { scoreboard.addPlayerToTeam(player.getScoreboardName(), collideRuleTeam); } // Paper end diff --git a/patches/server/0396-Load-Chunks-for-Login-Asynchronously.patch b/patches/server/0396-Load-Chunks-for-Login-Asynchronously.patch index 0b7a6787f..aa09a82fc 100644 --- a/patches/server/0396-Load-Chunks-for-Login-Asynchronously.patch +++ b/patches/server/0396-Load-Chunks-for-Login-Asynchronously.patch @@ -37,7 +37,7 @@ index be677d437d17b74c6188ce1bd5fc6fdc228fd92f..78fbb4c3e52e900956ae0811aaf934c8 public static final TicketType UNKNOWN = TicketType.create("unknown", Comparator.comparingLong(ChunkPos::toLong), 1); public static final TicketType PLUGIN = TicketType.create("plugin", (a, b) -> 0); // CraftBukkit diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 97dc7785b50873ee132825bced24cdf2d8217a60..bb870abae77d8fbf107bc9596637d4fac204c501 100644 +index e1e35bd6fb827149b23da4d19876a9a6989dde7e..4408c30532119277abb1027cd5a08e4cb9ebe587 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java @@ -251,6 +251,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic @@ -96,7 +96,7 @@ index c501e41ed7dd41a51cb87d4cf7ac62d694601156..31a506e78264f354394afc37fb7ebb3d try { ServerPlayer entityplayer1 = this.server.getPlayerList().getPlayerForLogin(this.gameProfile, s); // CraftBukkit - add player reference diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java -index b33a7cf936fec6c1c4d39f6c156d3e6fefa3e795..c9f0aa145b3f05b42b134654a841e88d6c39c3d1 100644 +index 1f32ba033eedcb69b02c29da8594be9edf958f43..4e662c672a554528dca7cdd31ae39957288943e3 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java @@ -139,6 +139,7 @@ public abstract class PlayerList { @@ -198,7 +198,7 @@ index b33a7cf936fec6c1c4d39f6c156d3e6fefa3e795..c9f0aa145b3f05b42b134654a841e88d MutableComponent ichatmutablecomponent; if (player.getGameProfile().getName().equalsIgnoreCase(s)) { -@@ -508,6 +564,7 @@ public abstract class PlayerList { +@@ -505,6 +561,7 @@ public abstract class PlayerList { protected void save(ServerPlayer player) { if (!player.getBukkitEntity().isPersistent()) return; // CraftBukkit @@ -206,7 +206,7 @@ index b33a7cf936fec6c1c4d39f6c156d3e6fefa3e795..c9f0aa145b3f05b42b134654a841e88d this.playerIo.save(player); ServerStatsCounter serverstatisticmanager = (ServerStatsCounter) player.getStats(); // CraftBukkit -@@ -535,7 +592,7 @@ public abstract class PlayerList { +@@ -532,7 +589,7 @@ public abstract class PlayerList { } PlayerQuitEvent playerQuitEvent = new PlayerQuitEvent(entityplayer.getBukkitEntity(), net.kyori.adventure.text.Component.translatable("multiplayer.player.left", net.kyori.adventure.text.format.NamedTextColor.YELLOW, io.papermc.paper.configuration.GlobalConfiguration.get().messages.useDisplayNameInQuitMessage ? entityplayer.getBukkitEntity().displayName() : net.kyori.adventure.text.Component.text(entityplayer.getScoreboardName()))); @@ -215,7 +215,7 @@ index b33a7cf936fec6c1c4d39f6c156d3e6fefa3e795..c9f0aa145b3f05b42b134654a841e88d entityplayer.getBukkitEntity().disconnect(playerQuitEvent.getQuitMessage()); if (server.isSameThread()) entityplayer.doTick(); // SPIGOT-924 // Paper - don't tick during emergency shutdowns (Watchdog) -@@ -580,6 +637,13 @@ public abstract class PlayerList { +@@ -577,6 +634,13 @@ public abstract class PlayerList { // this.advancements.remove(uuid); // CraftBukkit end } @@ -229,7 +229,7 @@ index b33a7cf936fec6c1c4d39f6c156d3e6fefa3e795..c9f0aa145b3f05b42b134654a841e88d // CraftBukkit start // this.broadcastAll(new PacketPlayOutPlayerInfo(PacketPlayOutPlayerInfo.EnumPlayerInfoAction.REMOVE_PLAYER, new EntityPlayer[]{entityplayer})); -@@ -597,7 +661,7 @@ public abstract class PlayerList { +@@ -594,7 +658,7 @@ public abstract class PlayerList { this.cserver.getScoreboardManager().removePlayer(entityplayer.getBukkitEntity()); // CraftBukkit end @@ -238,7 +238,7 @@ index b33a7cf936fec6c1c4d39f6c156d3e6fefa3e795..c9f0aa145b3f05b42b134654a841e88d } // CraftBukkit start - Whole method, SocketAddress to LoginListener, added hostname to signature, return EntityPlayer -@@ -616,6 +680,13 @@ public abstract class PlayerList { +@@ -613,6 +677,13 @@ public abstract class PlayerList { list.add(entityplayer); } } diff --git a/patches/server/0448-incremental-chunk-and-player-saving.patch b/patches/server/0448-incremental-chunk-and-player-saving.patch index 32ea81ed4..87e9993b6 100644 --- a/patches/server/0448-incremental-chunk-and-player-saving.patch +++ b/patches/server/0448-incremental-chunk-and-player-saving.patch @@ -310,10 +310,10 @@ index b0dffb7c7c8fece2528ac218acef428731145b92..8faa5ccd643158c59d55a6bf8e0e07a4 private static final int NEUTRAL_MOB_DEATH_NOTIFICATION_RADII_Y = 10; public ServerGamePacketListenerImpl connection; diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java -index c9f0aa145b3f05b42b134654a841e88d6c39c3d1..74f7a49930b6fb1313c96a0d3f8802d1758e039c 100644 +index 4e662c672a554528dca7cdd31ae39957288943e3..0696528f804b1b1b6e80d0bb3611725be6c8318c 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -565,6 +565,7 @@ public abstract class PlayerList { +@@ -562,6 +562,7 @@ public abstract class PlayerList { protected void save(ServerPlayer player) { if (!player.getBukkitEntity().isPersistent()) return; // CraftBukkit if (!player.didPlayerJoinEvent) return; // Paper - If we never fired PJE, we disconnected during login. Data has not changed, and additionally, our saved vehicle is not loaded! If we save now, we will lose our vehicle (CraftBukkit bug) @@ -321,7 +321,7 @@ index c9f0aa145b3f05b42b134654a841e88d6c39c3d1..74f7a49930b6fb1313c96a0d3f8802d1 this.playerIo.save(player); ServerStatsCounter serverstatisticmanager = (ServerStatsCounter) player.getStats(); // CraftBukkit -@@ -1167,10 +1168,22 @@ public abstract class PlayerList { +@@ -1164,10 +1165,22 @@ public abstract class PlayerList { } public void saveAll() { diff --git a/patches/server/0467-Fix-SPIGOT-5989.patch b/patches/server/0467-Fix-SPIGOT-5989.patch index a8ff80715..63815ae54 100644 --- a/patches/server/0467-Fix-SPIGOT-5989.patch +++ b/patches/server/0467-Fix-SPIGOT-5989.patch @@ -10,10 +10,10 @@ 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 9d54f0cffd201d3ee7f2ba39740e08be4823c691..ec0ceaac85b5868849b6399cdf8eb2b4447508e3 100644 +index e6bc6c1d9dae3e20d3cb937f06f935e22df55200..0b39ddc1bbf4cc20cd3867e57a983678a5cf0568 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -839,6 +839,7 @@ public abstract class PlayerList { +@@ -836,6 +836,7 @@ public abstract class PlayerList { // Paper start boolean isBedSpawn = false; boolean isRespawn = false; @@ -21,7 +21,7 @@ index 9d54f0cffd201d3ee7f2ba39740e08be4823c691..ec0ceaac85b5868849b6399cdf8eb2b4 // Paper end // CraftBukkit start - fire PlayerRespawnEvent -@@ -849,7 +850,7 @@ public abstract class PlayerList { +@@ -846,7 +847,7 @@ public abstract class PlayerList { Optional optional; if (blockposition != null) { @@ -30,7 +30,7 @@ index 9d54f0cffd201d3ee7f2ba39740e08be4823c691..ec0ceaac85b5868849b6399cdf8eb2b4 } else { optional = Optional.empty(); } -@@ -893,7 +894,12 @@ public abstract class PlayerList { +@@ -890,7 +891,12 @@ public abstract class PlayerList { } // Spigot End @@ -44,7 +44,7 @@ index 9d54f0cffd201d3ee7f2ba39740e08be4823c691..ec0ceaac85b5868849b6399cdf8eb2b4 if (!flag) entityplayer.reset(); // SPIGOT-4785 isRespawn = true; // Paper } else { -@@ -931,8 +937,12 @@ public abstract class PlayerList { +@@ -928,8 +934,12 @@ public abstract class PlayerList { } // entityplayer1.initInventoryMenu(); entityplayer1.setHealth(entityplayer1.getHealth()); diff --git a/patches/server/0522-Add-API-for-quit-reason.patch b/patches/server/0522-Add-API-for-quit-reason.patch index d8bbec4b7..0ae2db6b9 100644 --- a/patches/server/0522-Add-API-for-quit-reason.patch +++ b/patches/server/0522-Add-API-for-quit-reason.patch @@ -5,7 +5,7 @@ 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 eb18253d4ae0618884c9061f8dda689119e10ef0..cc1aa02fdf214b63aa105f3b0b12723dc359d287 100644 +index 65c2263f8872fba4f68779e0e90ea5f96aefdfbd..523e5a01c55d3a2e192d86e70ac751e3eb622aea 100644 --- a/src/main/java/net/minecraft/network/Connection.java +++ b/src/main/java/net/minecraft/network/Connection.java @@ -147,12 +147,15 @@ public class Connection extends SimpleChannelInboundHandler> { @@ -37,7 +37,7 @@ index 514d2d69980f843b5bc9339e63c48ba0e1176df5..8c6f55efb555c9ca7253ccc1cd9ba615 public ServerPlayer(MinecraftServer server, ServerLevel world, GameProfile profile, @Nullable ProfilePublicKey publicKey) { super(world, world.getSharedSpawnPos(), world.getSharedSpawnAngle(), profile, publicKey); diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 09edf5f6bbff8ae4af093d03e9a9f06337e87caa..31295e991b4269bc36293a70ba10738b9668244e 100644 +index b91b9d2d26ef44ae59645699b82fba7a90e7b25f..81e0dc794ba43a498cb49ed47e03db3f9dc5377e 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java @@ -518,6 +518,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic @@ -49,10 +49,10 @@ index 09edf5f6bbff8ae4af093d03e9a9f06337e87caa..31295e991b4269bc36293a70ba10738b this.connection.disconnect(ichatbasecomponent); })); diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java -index 32f8a030abb81aa29cab9432b72f9b522f1f6aa6..596750b47b8e780c0387b634a48282fa9383dc01 100644 +index aadf37f5005d78db9b87f42b1c2646d614116c97..70d6a3d4901cb39294bef47f42d0d49aea34867a 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -604,7 +604,7 @@ public abstract class PlayerList { +@@ -601,7 +601,7 @@ public abstract class PlayerList { entityplayer.closeContainer(org.bukkit.event.inventory.InventoryCloseEvent.Reason.DISCONNECT); // Paper } diff --git a/patches/server/0524-Expose-world-spawn-angle.patch b/patches/server/0524-Expose-world-spawn-angle.patch index 2d90e9601..16a268eb9 100644 --- a/patches/server/0524-Expose-world-spawn-angle.patch +++ b/patches/server/0524-Expose-world-spawn-angle.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Expose world spawn angle diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java -index 596750b47b8e780c0387b634a48282fa9383dc01..e18c38132536e9d671376f7bf1a75941063a5136 100644 +index 70d6a3d4901cb39294bef47f42d0d49aea34867a..8ca55b57b94bd264951d0b7725bd384ff7764ba6 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -882,7 +882,7 @@ public abstract class PlayerList { +@@ -879,7 +879,7 @@ public abstract class PlayerList { if (location == null) { worldserver1 = this.server.getLevel(Level.OVERWORLD); blockposition = entityplayer1.getSpawnPoint(worldserver1); diff --git a/patches/server/0567-Fix-villager-boat-exploit.patch b/patches/server/0567-Fix-villager-boat-exploit.patch index 07d1f498f..d021bcae9 100644 --- a/patches/server/0567-Fix-villager-boat-exploit.patch +++ b/patches/server/0567-Fix-villager-boat-exploit.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Fix villager boat exploit diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java -index e18c38132536e9d671376f7bf1a75941063a5136..8d30690cc603cbdfc2befeb6e1f6abde301bb1d7 100644 +index 8ca55b57b94bd264951d0b7725bd384ff7764ba6..2287f62e9a228822e7da43ddd42946335078ec01 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -629,6 +629,14 @@ public abstract class PlayerList { +@@ -626,6 +626,14 @@ public abstract class PlayerList { PlayerList.LOGGER.debug("Removing player mount"); entityplayer.stopRiding(); entity.getPassengersAndSelf().forEach((entity1) -> { diff --git a/patches/server/0568-Add-sendOpLevel-API.patch b/patches/server/0568-Add-sendOpLevel-API.patch index 2c6a83700..0068c9271 100644 --- a/patches/server/0568-Add-sendOpLevel-API.patch +++ b/patches/server/0568-Add-sendOpLevel-API.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Add sendOpLevel API diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java -index 8d30690cc603cbdfc2befeb6e1f6abde301bb1d7..78629b9e09d8326780f6f4e92340db7d92a5092b 100644 +index 2287f62e9a228822e7da43ddd42946335078ec01..65469cfe4dfb87a05a9060fbd8e0aa2fc4bbe066 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -1127,6 +1127,11 @@ public abstract class PlayerList { +@@ -1124,6 +1124,11 @@ public abstract class PlayerList { } private void sendPlayerPermissionLevel(ServerPlayer player, int permissionLevel) { @@ -20,7 +20,7 @@ index 8d30690cc603cbdfc2befeb6e1f6abde301bb1d7..78629b9e09d8326780f6f4e92340db7d if (player.connection != null) { byte b0; -@@ -1141,8 +1146,10 @@ public abstract class PlayerList { +@@ -1138,8 +1143,10 @@ public abstract class PlayerList { player.connection.send(new ClientboundEntityEventPacket(player, b0)); } diff --git a/patches/server/0609-Drop-carried-item-when-player-has-disconnected.patch b/patches/server/0609-Drop-carried-item-when-player-has-disconnected.patch index af1ad1a90..d261713d9 100644 --- a/patches/server/0609-Drop-carried-item-when-player-has-disconnected.patch +++ b/patches/server/0609-Drop-carried-item-when-player-has-disconnected.patch @@ -7,10 +7,10 @@ Fixes disappearance of held items, when a player gets disconnected and PlayerDro Closes #5036 diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java -index dc8d3c658c3ce9f85084f06a2c71d4dc24ab6279..c44c57df38d42dee60ac07cee9797e31692af10d 100644 +index 68b24700db1c1ff2ecc5e07208eede035546bfb1..538d7bcebf55af189d31dc64fe12ef5d5adb4cd3 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -622,6 +622,14 @@ public abstract class PlayerList { +@@ -619,6 +619,14 @@ public abstract class PlayerList { } // Paper end diff --git a/patches/server/0629-Fix-anchor-respawn-acting-as-a-bed-respawn-from-the-.patch b/patches/server/0629-Fix-anchor-respawn-acting-as-a-bed-respawn-from-the-.patch index d435b588d..680331942 100644 --- a/patches/server/0629-Fix-anchor-respawn-acting-as-a-bed-respawn-from-the-.patch +++ b/patches/server/0629-Fix-anchor-respawn-acting-as-a-bed-respawn-from-the-.patch @@ -6,10 +6,10 @@ Subject: [PATCH] Fix anchor respawn acting as a bed respawn from the end diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java -index c44c57df38d42dee60ac07cee9797e31692af10d..5b3e99c7d7af09a035278b90806853505b54f1fa 100644 +index 538d7bcebf55af189d31dc64fe12ef5d5adb4cd3..788a6dae744fd95d11d4f97a2fb0a7f53eed5884 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -855,6 +855,7 @@ public abstract class PlayerList { +@@ -852,6 +852,7 @@ public abstract class PlayerList { // Paper start boolean isBedSpawn = false; @@ -17,7 +17,7 @@ index c44c57df38d42dee60ac07cee9797e31692af10d..5b3e99c7d7af09a035278b9080685350 boolean isRespawn = false; boolean isLocAltered = false; // Paper - Fix SPIGOT-5989 // Paper end -@@ -875,6 +876,7 @@ public abstract class PlayerList { +@@ -872,6 +873,7 @@ public abstract class PlayerList { if (optional.isPresent()) { BlockState iblockdata = worldserver1.getBlockState(blockposition); boolean flag3 = iblockdata.is(Blocks.RESPAWN_ANCHOR); @@ -25,7 +25,7 @@ index c44c57df38d42dee60ac07cee9797e31692af10d..5b3e99c7d7af09a035278b9080685350 Vec3 vec3d = (Vec3) optional.get(); float f1; -@@ -903,7 +905,7 @@ public abstract class PlayerList { +@@ -900,7 +902,7 @@ public abstract class PlayerList { } Player respawnPlayer = entityplayer1.getBukkitEntity(); diff --git a/patches/server/0631-add-RespawnFlags-to-PlayerRespawnEvent.patch b/patches/server/0631-add-RespawnFlags-to-PlayerRespawnEvent.patch index ed8deb279..90c7c7ea3 100644 --- a/patches/server/0631-add-RespawnFlags-to-PlayerRespawnEvent.patch +++ b/patches/server/0631-add-RespawnFlags-to-PlayerRespawnEvent.patch @@ -5,7 +5,7 @@ Subject: [PATCH] add RespawnFlags to PlayerRespawnEvent diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 8b52453f67347625e68ff0c439fb65820dbcf959..749269cf1af41717d50eec75ab0f9a8e51370273 100644 +index 539e98cad4a62c6c838ce6cec1947197878da01b..2278cc53e29f288e157ccb13e1332e63c6fdb939 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java @@ -2877,7 +2877,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic @@ -18,10 +18,10 @@ index 8b52453f67347625e68ff0c439fb65820dbcf959..749269cf1af41717d50eec75ab0f9a8e } else { if (this.player.getHealth() > 0.0F) { diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java -index 5b3e99c7d7af09a035278b90806853505b54f1fa..3e8934a141bc8c650549afaef7b4f8b02371f9ab 100644 +index 788a6dae744fd95d11d4f97a2fb0a7f53eed5884..45844d2afd5e5203a85d1419ee0a0d66722e4aed 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -814,6 +814,12 @@ public abstract class PlayerList { +@@ -811,6 +811,12 @@ public abstract class PlayerList { } public ServerPlayer respawn(ServerPlayer entityplayer, ServerLevel worldserver, boolean flag, Location location, boolean avoidSuffocation) { @@ -34,7 +34,7 @@ index 5b3e99c7d7af09a035278b90806853505b54f1fa..3e8934a141bc8c650549afaef7b4f8b0 entityplayer.stopRiding(); // CraftBukkit this.players.remove(entityplayer); this.playersByName.remove(entityplayer.getScoreboardName().toLowerCase(java.util.Locale.ROOT)); // Spigot -@@ -905,7 +911,7 @@ public abstract class PlayerList { +@@ -902,7 +908,7 @@ public abstract class PlayerList { } Player respawnPlayer = entityplayer1.getBukkitEntity(); diff --git a/patches/server/0656-Add-PlayerKickEvent-causes.patch b/patches/server/0656-Add-PlayerKickEvent-causes.patch index 6dba12229..addb16698 100644 --- a/patches/server/0656-Add-PlayerKickEvent-causes.patch +++ b/patches/server/0656-Add-PlayerKickEvent-causes.patch @@ -57,7 +57,7 @@ index 65637a33ba171a4b598f70cd943d24b0ee44a69f..57a9146bf2dee7a60aab16716e25348f } diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index cc1225f7c1e4d47f509c55609066fba084331a4d..a768e09c5ce6718435b50f1502c5ace773fff470 100644 +index f181c9bbdd399e06ed5d43b3165d9b702e2267d5..7810804dfeeb8e78b2af10f7e2ae8aec6dcaaabb 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java @@ -372,7 +372,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic @@ -309,10 +309,10 @@ index cc1225f7c1e4d47f509c55609066fba084331a4d..a768e09c5ce6718435b50f1502c5ace7 } diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java -index 3e8934a141bc8c650549afaef7b4f8b02371f9ab..9dece3470d617be02248f41847ebf77ed083653a 100644 +index 45844d2afd5e5203a85d1419ee0a0d66722e4aed..69af47c070806ae410a2f4c80c121f48689f56bc 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -723,7 +723,7 @@ public abstract class PlayerList { +@@ -720,7 +720,7 @@ public abstract class PlayerList { while (iterator.hasNext()) { entityplayer = (ServerPlayer) iterator.next(); this.save(entityplayer); // CraftBukkit - Force the player's inventory to be saved @@ -321,7 +321,7 @@ index 3e8934a141bc8c650549afaef7b4f8b02371f9ab..9dece3470d617be02248f41847ebf77e } // Instead of kicking then returning, we need to store the kick reason -@@ -1354,8 +1354,8 @@ public abstract class PlayerList { +@@ -1351,8 +1351,8 @@ public abstract class PlayerList { // Paper end // CraftBukkit start - disconnect safely for (ServerPlayer player : this.players) { diff --git a/patches/server/0678-Fixes-kick-event-leave-message-not-being-sent.patch b/patches/server/0678-Fixes-kick-event-leave-message-not-being-sent.patch index 501d605db..93c8b0c73 100644 --- a/patches/server/0678-Fixes-kick-event-leave-message-not-being-sent.patch +++ b/patches/server/0678-Fixes-kick-event-leave-message-not-being-sent.patch @@ -17,7 +17,7 @@ index 6e53214042ab515d9c66fb24f6aa1c07d6c3539d..7670c02dca163d360e64a1491f2efe69 public PlayerNaturallySpawnCreaturesEvent playerNaturallySpawnedEvent; // Paper diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 4d3874b5f44d0162e245a73b5543c9f2cc75c9ce..e1993c9f08b73e4366f60369e7f147c9c8bda958 100644 +index 781c3abc7693ef1e310c963d154f312b06d9c392..bc20661f3b70f1e769d6be5f2a8bbb81cd7b2dca 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java @@ -523,7 +523,6 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic @@ -59,10 +59,10 @@ index 4d3874b5f44d0162e245a73b5543c9f2cc75c9ce..e1993c9f08b73e4366f60369e7f147c9 this.server.getPlayerList().broadcastSystemMessage(PaperAdventure.asVanilla(quitMessage), false); // Paper end diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java -index 9dece3470d617be02248f41847ebf77ed083653a..1a48a03e70b282847dba1da796e5b8211debb603 100644 +index 69af47c070806ae410a2f4c80c121f48689f56bc..387158d5aad22e0da186e1087364d8a990aadd23 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -595,6 +595,11 @@ public abstract class PlayerList { +@@ -592,6 +592,11 @@ public abstract class PlayerList { } public net.kyori.adventure.text.Component remove(ServerPlayer entityplayer) { // Paper - return Component @@ -74,7 +74,7 @@ index 9dece3470d617be02248f41847ebf77ed083653a..1a48a03e70b282847dba1da796e5b821 ServerLevel worldserver = entityplayer.getLevel(); entityplayer.awardStat(Stats.LEAVE_GAME); -@@ -605,7 +610,7 @@ public abstract class PlayerList { +@@ -602,7 +607,7 @@ public abstract class PlayerList { entityplayer.closeContainer(org.bukkit.event.inventory.InventoryCloseEvent.Reason.DISCONNECT); // Paper } diff --git a/patches/server/0692-Add-PlayerSetSpawnEvent.patch b/patches/server/0692-Add-PlayerSetSpawnEvent.patch index ae2b3bf6c..084f20891 100644 --- a/patches/server/0692-Add-PlayerSetSpawnEvent.patch +++ b/patches/server/0692-Add-PlayerSetSpawnEvent.patch @@ -89,10 +89,10 @@ index f523311e822af9cbef571338fd8fef177b9fc73d..ec713ffb7c4cba53dc983ebde5596e47 public void trackChunk(ChunkPos chunkPos, Packet chunkDataPacket) { diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java -index 1a48a03e70b282847dba1da796e5b8211debb603..dda357b4f52030435c012f10b11f1ccb3f6688be 100644 +index 387158d5aad22e0da186e1087364d8a990aadd23..5dcb961275abd3eeefb60e68276f765539b366df 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -899,13 +899,13 @@ public abstract class PlayerList { +@@ -896,13 +896,13 @@ public abstract class PlayerList { f1 = (float) Mth.wrapDegrees(Mth.atan2(vec3d1.z, vec3d1.x) * 57.2957763671875D - 90.0D); } diff --git a/patches/server/0802-Highly-optimise-single-and-multi-AABB-VoxelShapes-an.patch b/patches/server/0802-Highly-optimise-single-and-multi-AABB-VoxelShapes-an.patch index 616fcebec..727777f3a 100644 --- a/patches/server/0802-Highly-optimise-single-and-multi-AABB-VoxelShapes-an.patch +++ b/patches/server/0802-Highly-optimise-single-and-multi-AABB-VoxelShapes-an.patch @@ -1202,10 +1202,10 @@ index e243e67ff389014b2b1a80fa20e67996fae48f8d..c3484d612d0273bc066b3ac274b33c21 } } diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java -index 1548df4057b34fe6bad2c51fb5a77ce118b36566..20d1360a42a3adb1342b5dc8595b57b82ce573a8 100644 +index 6aac9f91ef95f7b0a3319360dbc8360d2c93eb8c..132ce6a997540c3f67f12be068883bd990e7bd63 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -940,7 +940,7 @@ public abstract class PlayerList { +@@ -937,7 +937,7 @@ public abstract class PlayerList { // CraftBukkit end worldserver1.getChunkSource().addRegionTicket(net.minecraft.server.level.TicketType.POST_TELEPORT, new net.minecraft.world.level.ChunkPos(location.getBlockX() >> 4, location.getBlockZ() >> 4), 1, entityplayer.getId()); // Paper diff --git a/patches/server/0823-Validate-usernames.patch b/patches/server/0823-Validate-usernames.patch index 01a41eaff..99c6bacac 100644 --- a/patches/server/0823-Validate-usernames.patch +++ b/patches/server/0823-Validate-usernames.patch @@ -56,10 +56,10 @@ index 303981c9b873eee07052fbe607690d12074cd1d1..aabd8916470290045832e0fc1895d099 GameProfile gameprofile = this.server.getSingleplayerProfile(); diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java -index 20d1360a42a3adb1342b5dc8595b57b82ce573a8..c5f4e30e434dc1467b889bdc41de3773fab3307a 100644 +index 132ce6a997540c3f67f12be068883bd990e7bd63..dd514cc59b28fdc49dbb4c9641f11e8835b8fb1a 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -711,7 +711,7 @@ public abstract class PlayerList { +@@ -708,7 +708,7 @@ public abstract class PlayerList { for (int i = 0; i < this.players.size(); ++i) { entityplayer = (ServerPlayer) this.players.get(i); diff --git a/patches/server/0856-Replace-player-chunk-loader-system.patch b/patches/server/0856-Replace-player-chunk-loader-system.patch index 90216355b..7935b6b56 100644 --- a/patches/server/0856-Replace-player-chunk-loader-system.patch +++ b/patches/server/0856-Replace-player-chunk-loader-system.patch @@ -1218,7 +1218,7 @@ index 0000000000000000000000000000000000000000..b53402903eb6845df361daf6b05a6686 + } +} diff --git a/src/main/java/net/minecraft/network/Connection.java b/src/main/java/net/minecraft/network/Connection.java -index 56a93ea07f4e90b084f9a8da4cd9f53afde4c0d5..9d2b5070a1da6232e85a321b8d804eba1a26a98b 100644 +index c561a2f28fa1e9a327982c4587c4552cd85a7336..868d4913f63b3f4752f7f1cdcd81e118e482c474 100644 --- a/src/main/java/net/minecraft/network/Connection.java +++ b/src/main/java/net/minecraft/network/Connection.java @@ -100,6 +100,28 @@ public class Connection extends SimpleChannelInboundHandler> { @@ -1900,7 +1900,7 @@ index c3484d612d0273bc066b3ac274b33c21ae9e0936..2dae3fe22bad90ba10a21999816b80e2 + public final int getViewDistance() { throw new UnsupportedOperationException("Use PlayerChunkLoader"); } // Paper - placeholder } diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java -index c5f4e30e434dc1467b889bdc41de3773fab3307a..ce7216061492350b89d386f62fc6ffdf85027b3d 100644 +index dd514cc59b28fdc49dbb4c9641f11e8835b8fb1a..04d77a1b001e80b2e2e3c6f33ee32f3abd1848fb 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java @@ -274,7 +274,7 @@ public abstract class PlayerList { @@ -1912,7 +1912,7 @@ index c5f4e30e434dc1467b889bdc41de3773fab3307a..ce7216061492350b89d386f62fc6ffdf player.getBukkitEntity().sendSupportedChannels(); // CraftBukkit playerconnection.send(new ClientboundCustomPayloadPacket(ClientboundCustomPayloadPacket.BRAND, (new FriendlyByteBuf(Unpooled.buffer())).writeUtf(this.getServer().getServerModName()))); playerconnection.send(new ClientboundChangeDifficultyPacket(worlddata.getDifficulty(), worlddata.isDifficultyLocked())); -@@ -946,8 +946,8 @@ public abstract class PlayerList { +@@ -943,8 +943,8 @@ public abstract class PlayerList { // CraftBukkit start LevelData worlddata = worldserver1.getLevelData(); entityplayer1.connection.send(new ClientboundRespawnPacket(worldserver1.dimensionTypeId(), worldserver1.dimension(), BiomeManager.obfuscateSeed(worldserver1.getSeed()), entityplayer1.gameMode.getGameModeForPlayer(), entityplayer1.gameMode.getPreviousGameModeForPlayer(), worldserver1.isDebug(), worldserver1.isFlat(), flag, entityplayer1.getLastDeathLocation())); @@ -1923,7 +1923,7 @@ index c5f4e30e434dc1467b889bdc41de3773fab3307a..ce7216061492350b89d386f62fc6ffdf entityplayer1.spawnIn(worldserver1); entityplayer1.unsetRemoved(); entityplayer1.connection.teleport(new Location(worldserver1.getWorld(), entityplayer1.getX(), entityplayer1.getY(), entityplayer1.getZ(), entityplayer1.getYRot(), entityplayer1.getXRot())); -@@ -1505,7 +1505,7 @@ public abstract class PlayerList { +@@ -1502,7 +1502,7 @@ public abstract class PlayerList { public void setViewDistance(int viewDistance) { this.viewDistance = viewDistance; @@ -1932,7 +1932,7 @@ index c5f4e30e434dc1467b889bdc41de3773fab3307a..ce7216061492350b89d386f62fc6ffdf Iterator iterator = this.server.getAllLevels().iterator(); while (iterator.hasNext()) { -@@ -1520,7 +1520,7 @@ public abstract class PlayerList { +@@ -1517,7 +1517,7 @@ public abstract class PlayerList { public void setSimulationDistance(int simulationDistance) { this.simulationDistance = simulationDistance; diff --git a/patches/server/0858-Force-close-world-loading-screen.patch b/patches/server/0858-Force-close-world-loading-screen.patch index b78d4f549..523a36619 100644 --- a/patches/server/0858-Force-close-world-loading-screen.patch +++ b/patches/server/0858-Force-close-world-loading-screen.patch @@ -10,10 +10,10 @@ so we do not need that. The client only needs the chunk it is currently in to be loaded to close the loading screen, so we just send an empty one. diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java -index ce7216061492350b89d386f62fc6ffdf85027b3d..685f3375a825c1ce88fb7d066153d69dd6090ac3 100644 +index 04d77a1b001e80b2e2e3c6f33ee32f3abd1848fb..812c62d798d21584e12a3e83354c081c073bf8bf 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -426,6 +426,16 @@ public abstract class PlayerList { +@@ -423,6 +423,16 @@ public abstract class PlayerList { // Paper start - move vehicle into method so it can be called above - short circuit around that code onPlayerJoinFinish(player, worldserver1, s1); diff --git a/patches/server/0864-Fix-swamp-hut-cat-generation-deadlock.patch b/patches/server/0864-Fix-swamp-hut-cat-generation-deadlock.patch index 88f0c6ad9..ae8f7dbdb 100644 --- a/patches/server/0864-Fix-swamp-hut-cat-generation-deadlock.patch +++ b/patches/server/0864-Fix-swamp-hut-cat-generation-deadlock.patch @@ -23,7 +23,7 @@ index 5ad968a2f1add27da0d6a858e683d5d771128092..e44352857272a2a4027c67bd25a28a94 this.setPersistenceRequired(); } diff --git a/src/main/java/net/minecraft/world/level/StructureManager.java b/src/main/java/net/minecraft/world/level/StructureManager.java -index e7445c1ff0d1e3e989fcd8d3630dd5269a64598d..16740418e22560687c0326084c004f19681f8da6 100644 +index e7445c1ff0d1e3e989fcd8d3630dd5269a64598d..64ca546a905d69a795bbdafb4f9860b31cd863d1 100644 --- a/src/main/java/net/minecraft/world/level/StructureManager.java +++ b/src/main/java/net/minecraft/world/level/StructureManager.java @@ -43,7 +43,12 @@ public class StructureManager { @@ -32,7 +32,7 @@ index e7445c1ff0d1e3e989fcd8d3630dd5269a64598d..16740418e22560687c0326084c004f19 public List startsForStructure(ChunkPos pos, Predicate predicate) { - Map map = this.level.getChunk(pos.x, pos.z, ChunkStatus.STRUCTURE_REFERENCES).getAllReferences(); + // Paper start -+ return this.startsForStructure(chunkPos, predicate, null); ++ return this.startsForStructure(pos, predicate, null); + } + public List startsForStructure(ChunkPos pos, Predicate predicate, @Nullable ServerLevelAccessor levelAccessor) { + Map map = (levelAccessor == null ? this.level : levelAccessor).getChunk(pos.x, pos.z, ChunkStatus.STRUCTURE_REFERENCES).getAllReferences(); diff --git a/patches/server/0882-Use-username-instead-of-display-name-in-PlayerList-g.patch b/patches/server/0882-Use-username-instead-of-display-name-in-PlayerList-g.patch index e04d9e2d8..8db22afe3 100644 --- a/patches/server/0882-Use-username-instead-of-display-name-in-PlayerList-g.patch +++ b/patches/server/0882-Use-username-instead-of-display-name-in-PlayerList-g.patch @@ -6,10 +6,10 @@ Subject: [PATCH] Use username instead of display name in diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java -index 685f3375a825c1ce88fb7d066153d69dd6090ac3..0f064faa7d03960f9babfb99785e8c88eeb814a9 100644 +index 812c62d798d21584e12a3e83354c081c073bf8bf..71955f5c5d8e9973da97863d09fbfc8f52830a82 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -1469,7 +1469,7 @@ public abstract class PlayerList { +@@ -1466,7 +1466,7 @@ public abstract class PlayerList { // CraftBukkit start public ServerStatsCounter getPlayerStats(ServerPlayer entityhuman) { ServerStatsCounter serverstatisticmanager = entityhuman.getStats();