diff --git a/patches/api/0005-Adventure.patch b/patches/api/0005-Adventure.patch index 65d064bf09..89fbdabbc5 100644 --- a/patches/api/0005-Adventure.patch +++ b/patches/api/0005-Adventure.patch @@ -1003,11 +1003,11 @@ index 32c92621c2c15eec14c50965f5ecda00c46e6c80..e076d447da62445764a9776ee2554c07 + // Paper end } diff --git a/src/main/java/org/bukkit/Nameable.java b/src/main/java/org/bukkit/Nameable.java -index fee814e01a653d2b53c56e8b566383ca44aa5346..4904a7ec9fcbbc5cb41e07267426b45c60ec655e 100644 +index b79daa857fc686f00ac06b8851e0ab68d83ae949..45d996878ba8d314a47078589b6da59dc84d589e 100644 --- a/src/main/java/org/bukkit/Nameable.java +++ b/src/main/java/org/bukkit/Nameable.java -@@ -4,6 +4,30 @@ import org.jetbrains.annotations.Nullable; - +@@ -7,6 +7,30 @@ import org.jetbrains.annotations.Nullable; + */ public interface Nameable { + // Paper start @@ -1037,7 +1037,7 @@ index fee814e01a653d2b53c56e8b566383ca44aa5346..4904a7ec9fcbbc5cb41e07267426b45c /** * Gets the custom name on a mob or block. If there is no name this method * will return null. -@@ -11,8 +35,10 @@ public interface Nameable { +@@ -14,8 +38,10 @@ public interface Nameable { * This value has no effect on players, they will always use their real * name. * @@ -1048,7 +1048,7 @@ index fee814e01a653d2b53c56e8b566383ca44aa5346..4904a7ec9fcbbc5cb41e07267426b45c @Nullable public String getCustomName(); -@@ -25,7 +51,9 @@ public interface Nameable { +@@ -28,7 +54,9 @@ public interface Nameable { * This value has no effect on players, they will always use their real * name. * @@ -1458,7 +1458,7 @@ index efb97712cc9dc7c1e12a59f5b94e4f2ad7c6b7d8..3024468af4c073324e536c1cb26beffb return warning == null || warning.value(); } diff --git a/src/main/java/org/bukkit/World.java b/src/main/java/org/bukkit/World.java -index 72851fa36a985b780d5ad24497aec1ce226830ae..2e26ed8492669de22cf9b652edc1e83d8eaa6e2a 100644 +index e75cd4484aa2d2b4f0896a6fe66d4a090047085c..1a71d628d9f593157d92f0c9fda9d3214c138352 100644 --- a/src/main/java/org/bukkit/World.java +++ b/src/main/java/org/bukkit/World.java @@ -43,7 +43,7 @@ import org.jetbrains.annotations.Nullable; @@ -1470,7 +1470,7 @@ index 72851fa36a985b780d5ad24497aec1ce226830ae..2e26ed8492669de22cf9b652edc1e83d /** * Gets the {@link Block} at the given coordinates -@@ -649,6 +649,14 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient +@@ -604,6 +604,14 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient @NotNull public List getPlayers(); @@ -1996,10 +1996,10 @@ index f3afe67f0832cb828d25be3654518ff73a80b0e1..598abaa82c634178043a29f6caa6ac52 + // Paper end } diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java -index 1d702d2bfd61fc44f351a90e03e4b2593e470630..743559d4cc248331578e0c2d2a026e7a270cb713 100644 +index 363567304c9698ffe21eaf0da9aef694c8050eb0..8708ca080bda0f4ec43964db3a4e56cf73c6559a 100644 --- a/src/main/java/org/bukkit/entity/Player.java +++ b/src/main/java/org/bukkit/entity/Player.java -@@ -40,7 +40,28 @@ import org.jetbrains.annotations.Nullable; +@@ -41,7 +41,28 @@ import org.jetbrains.annotations.Nullable; /** * Represents a player, connected or not */ @@ -2029,7 +2029,7 @@ index 1d702d2bfd61fc44f351a90e03e4b2593e470630..743559d4cc248331578e0c2d2a026e7a /** * {@inheritDoc} -@@ -57,7 +78,9 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -58,7 +79,9 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM * places defined by plugins. * * @return the friendly name @@ -2039,7 +2039,7 @@ index 1d702d2bfd61fc44f351a90e03e4b2593e470630..743559d4cc248331578e0c2d2a026e7a @NotNull public String getDisplayName(); -@@ -69,15 +92,50 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -70,15 +93,50 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM * places defined by plugins. * * @param name The new display name. @@ -2090,7 +2090,7 @@ index 1d702d2bfd61fc44f351a90e03e4b2593e470630..743559d4cc248331578e0c2d2a026e7a public String getPlayerListName(); /** -@@ -86,14 +144,18 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -87,14 +145,18 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM * If the value is null, the name will be identical to {@link #getName()}. * * @param name new player list name @@ -2109,7 +2109,7 @@ index 1d702d2bfd61fc44f351a90e03e4b2593e470630..743559d4cc248331578e0c2d2a026e7a @Nullable public String getPlayerListHeader(); -@@ -101,7 +163,9 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -102,7 +164,9 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM * Gets the currently displayed player list footer for this player. * * @return player list header or null @@ -2119,7 +2119,7 @@ index 1d702d2bfd61fc44f351a90e03e4b2593e470630..743559d4cc248331578e0c2d2a026e7a @Nullable public String getPlayerListFooter(); -@@ -109,14 +173,18 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -110,14 +174,18 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM * Sets the currently displayed player list header for this player. * * @param header player list header, null for empty @@ -2138,7 +2138,7 @@ index 1d702d2bfd61fc44f351a90e03e4b2593e470630..743559d4cc248331578e0c2d2a026e7a public void setPlayerListFooter(@Nullable String footer); /** -@@ -125,7 +193,9 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -126,7 +194,9 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM * * @param header player list header, null for empty * @param footer player list footer, null for empty @@ -2148,7 +2148,7 @@ index 1d702d2bfd61fc44f351a90e03e4b2593e470630..743559d4cc248331578e0c2d2a026e7a public void setPlayerListHeaderFooter(@Nullable String header, @Nullable String footer); /** -@@ -163,9 +233,25 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -164,9 +234,25 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM * Kicks player with custom kick message. * * @param message kick message @@ -2174,7 +2174,7 @@ index 1d702d2bfd61fc44f351a90e03e4b2593e470630..743559d4cc248331578e0c2d2a026e7a /** * Says a message (or runs a command). * -@@ -607,6 +693,90 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -608,6 +694,90 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM */ public void sendEquipmentChange(@NotNull LivingEntity entity, @NotNull Map items); @@ -2265,7 +2265,7 @@ index 1d702d2bfd61fc44f351a90e03e4b2593e470630..743559d4cc248331578e0c2d2a026e7a /** * Send a sign change. This fakes a sign change packet for a user at * a certain location. This will not actually change the world in any way. -@@ -621,7 +791,9 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -622,7 +792,9 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM * @param lines the new text on the sign or null to clear it * @throws IllegalArgumentException if location is null * @throws IllegalArgumentException if lines is non-null and has a length less than 4 @@ -2275,7 +2275,7 @@ index 1d702d2bfd61fc44f351a90e03e4b2593e470630..743559d4cc248331578e0c2d2a026e7a public void sendSignChange(@NotNull Location loc, @Nullable String[] lines) throws IllegalArgumentException; /** -@@ -640,7 +812,9 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -641,7 +813,9 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM * @throws IllegalArgumentException if location is null * @throws IllegalArgumentException if dyeColor is null * @throws IllegalArgumentException if lines is non-null and has a length less than 4 @@ -2285,7 +2285,7 @@ index 1d702d2bfd61fc44f351a90e03e4b2593e470630..743559d4cc248331578e0c2d2a026e7a public void sendSignChange(@NotNull Location loc, @Nullable String[] lines, @NotNull DyeColor dyeColor) throws IllegalArgumentException; /** -@@ -660,7 +834,9 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -661,7 +835,9 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM * @throws IllegalArgumentException if location is null * @throws IllegalArgumentException if dyeColor is null * @throws IllegalArgumentException if lines is non-null and has a length less than 4 @@ -2295,7 +2295,7 @@ index 1d702d2bfd61fc44f351a90e03e4b2593e470630..743559d4cc248331578e0c2d2a026e7a public void sendSignChange(@NotNull Location loc, @Nullable String[] lines, @NotNull DyeColor dyeColor, boolean hasGlowingText) throws IllegalArgumentException; /** -@@ -1133,6 +1309,7 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -1155,6 +1331,7 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM * pack correctly. * * @@ -2303,7 +2303,7 @@ index 1d702d2bfd61fc44f351a90e03e4b2593e470630..743559d4cc248331578e0c2d2a026e7a * @param url The URL from which the client will download the resource * pack. The string must contain only US-ASCII characters and should * be encoded as per RFC 1738. -@@ -1189,8 +1366,10 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -1211,8 +1388,10 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM * @throws IllegalArgumentException Thrown if the hash is not 20 bytes * long. */ @@ -2314,7 +2314,7 @@ index 1d702d2bfd61fc44f351a90e03e4b2593e470630..743559d4cc248331578e0c2d2a026e7a /** * Request that the player's client download and switch resource packs. *

-@@ -1226,6 +1405,54 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -1248,6 +1427,54 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM * @param hash The sha1 hash sum of the resource pack file which is used * to apply a cached version of the pack directly without downloading * if it is available. Hast to be 20 bytes long! @@ -2369,7 +2369,7 @@ index 1d702d2bfd61fc44f351a90e03e4b2593e470630..743559d4cc248331578e0c2d2a026e7a * @param force If true, the client will be disconnected from the server * when it declines to use the resource pack. * @throws IllegalArgumentException Thrown if the URL is null. -@@ -1280,8 +1507,57 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -1302,8 +1529,57 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM * @throws IllegalArgumentException Thrown if the hash is not 20 bytes * long. */ @@ -2427,7 +2427,7 @@ index 1d702d2bfd61fc44f351a90e03e4b2593e470630..743559d4cc248331578e0c2d2a026e7a /** * Gets the Scoreboard displayed to this player * -@@ -1397,7 +1673,7 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -1419,7 +1695,7 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM * * @param title Title text * @param subtitle Subtitle text @@ -2436,7 +2436,7 @@ index 1d702d2bfd61fc44f351a90e03e4b2593e470630..743559d4cc248331578e0c2d2a026e7a */ @Deprecated public void sendTitle(@Nullable String title, @Nullable String subtitle); -@@ -1416,7 +1692,9 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -1438,7 +1714,9 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM * @param fadeIn time in ticks for titles to fade in. Defaults to 10. * @param stay time in ticks for titles to stay. Defaults to 70. * @param fadeOut time in ticks for titles to fade out. Defaults to 20. @@ -2446,7 +2446,7 @@ index 1d702d2bfd61fc44f351a90e03e4b2593e470630..743559d4cc248331578e0c2d2a026e7a public void sendTitle(@Nullable String title, @Nullable String subtitle, int fadeIn, int stay, int fadeOut); /** -@@ -1643,6 +1921,14 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -1665,6 +1943,14 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM */ public int getClientViewDistance(); @@ -2461,7 +2461,7 @@ index 1d702d2bfd61fc44f351a90e03e4b2593e470630..743559d4cc248331578e0c2d2a026e7a /** * Gets the player's estimated ping in milliseconds. * -@@ -1668,8 +1954,10 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -1690,8 +1976,10 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM * they wish. * * @return the player's locale @@ -2472,7 +2472,7 @@ index 1d702d2bfd61fc44f351a90e03e4b2593e470630..743559d4cc248331578e0c2d2a026e7a public String getLocale(); /** -@@ -1711,6 +1999,14 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -1733,6 +2021,14 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM */ public boolean isAllowingServerListings(); @@ -2487,7 +2487,7 @@ index 1d702d2bfd61fc44f351a90e03e4b2593e470630..743559d4cc248331578e0c2d2a026e7a // Spigot start public class Spigot extends Entity.Spigot { -@@ -1765,11 +2061,13 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -1787,11 +2083,13 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM throw new UnsupportedOperationException("Not supported yet."); } @@ -2501,7 +2501,7 @@ index 1d702d2bfd61fc44f351a90e03e4b2593e470630..743559d4cc248331578e0c2d2a026e7a @Override public void sendMessage(@NotNull net.md_5.bungee.api.chat.BaseComponent... components) { throw new UnsupportedOperationException("Not supported yet."); -@@ -1780,7 +2078,9 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -1802,7 +2100,9 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM * * @param position the screen position * @param component the components to send @@ -2511,7 +2511,7 @@ index 1d702d2bfd61fc44f351a90e03e4b2593e470630..743559d4cc248331578e0c2d2a026e7a public void sendMessage(@NotNull net.md_5.bungee.api.ChatMessageType position, @NotNull net.md_5.bungee.api.chat.BaseComponent component) { throw new UnsupportedOperationException("Not supported yet."); } -@@ -1790,7 +2090,9 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -1812,7 +2112,9 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM * * @param position the screen position * @param components the components to send @@ -2521,7 +2521,7 @@ index 1d702d2bfd61fc44f351a90e03e4b2593e470630..743559d4cc248331578e0c2d2a026e7a public void sendMessage(@NotNull net.md_5.bungee.api.ChatMessageType position, @NotNull net.md_5.bungee.api.chat.BaseComponent... components) { throw new UnsupportedOperationException("Not supported yet."); } -@@ -1801,7 +2103,9 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -1823,7 +2125,9 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM * @param position the screen position * @param sender the sender of the message * @param component the components to send @@ -2531,7 +2531,7 @@ index 1d702d2bfd61fc44f351a90e03e4b2593e470630..743559d4cc248331578e0c2d2a026e7a public void sendMessage(@NotNull net.md_5.bungee.api.ChatMessageType position, @Nullable java.util.UUID sender, @NotNull net.md_5.bungee.api.chat.BaseComponent component) { throw new UnsupportedOperationException("Not supported yet."); } -@@ -1812,7 +2116,9 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -1834,7 +2138,9 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM * @param position the screen position * @param sender the sender of the message * @param components the components to send @@ -2542,7 +2542,7 @@ index 1d702d2bfd61fc44f351a90e03e4b2593e470630..743559d4cc248331578e0c2d2a026e7a throw new UnsupportedOperationException("Not supported yet."); } diff --git a/src/main/java/org/bukkit/entity/TextDisplay.java b/src/main/java/org/bukkit/entity/TextDisplay.java -index a0ee539a46bcdf49ea750318374d393e9ef3ce68..fc4fe1ca764050dbdb0bb697cf4c147bd60f5a81 100644 +index d6d7ada3d3ff9a033ce3f780b104ef3e176f9083..f101ffde9e7b3f6c3ab6f1cffb8d6f4e720634b2 100644 --- a/src/main/java/org/bukkit/entity/TextDisplay.java +++ b/src/main/java/org/bukkit/entity/TextDisplay.java @@ -13,17 +13,37 @@ public interface TextDisplay extends Display { @@ -3774,10 +3774,10 @@ index 5adbe0514129abf3cfbc4b29a213f522359fe2e1..72ebc29db42d08d1d0361dba462fc8a5 /** diff --git a/src/main/java/org/bukkit/inventory/InventoryView.java b/src/main/java/org/bukkit/inventory/InventoryView.java -index 5fc95b83dbcd8e533afe6539f97829ce7a52224f..dbf316b63bf3d0c0695ceca84985d67f0f95c906 100644 +index e12996492c1558fed9fab30de9f8018e0ed7fac3..002acfbdce1db10f7ba1b6a013e678f504ac6e69 100644 --- a/src/main/java/org/bukkit/inventory/InventoryView.java +++ b/src/main/java/org/bukkit/inventory/InventoryView.java -@@ -447,11 +447,25 @@ public abstract class InventoryView { +@@ -447,12 +447,26 @@ public abstract class InventoryView { return getPlayer().setWindowProperty(prop, value); } @@ -3802,7 +3802,8 @@ index 5fc95b83dbcd8e533afe6539f97829ce7a52224f..dbf316b63bf3d0c0695ceca84985d67f + @Deprecated // Paper + @NotNull public abstract String getTitle(); - } + + /** diff --git a/src/main/java/org/bukkit/inventory/ItemFactory.java b/src/main/java/org/bukkit/inventory/ItemFactory.java index f89d71b77d1200314df6ca23614d5ca6fb15ceb3..af4a7ce37eb10bab06eadb6583c7894b3ec55ae6 100644 --- a/src/main/java/org/bukkit/inventory/ItemFactory.java diff --git a/patches/api/0008-Paper-Plugins.patch b/patches/api/0008-Paper-Plugins.patch index 6ab24df8f2..bb02fa6bc2 100644 --- a/patches/api/0008-Paper-Plugins.patch +++ b/patches/api/0008-Paper-Plugins.patch @@ -1862,10 +1862,10 @@ index a80251eff75430863b37db1c131e22593f3fcd5e..310c4041963a3f1e0a26e39a6da12a9b + // Paper end } diff --git a/src/main/java/org/bukkit/plugin/java/JavaPlugin.java b/src/main/java/org/bukkit/plugin/java/JavaPlugin.java -index 669a70faa95d0d6525a731d73499ed6fb0b48320..85619f03461a095b5cdb441da8994b1ea02de5f0 100644 +index ee100b7ad89ce1eccef0c3bc55885cd78aadd1ec..f594913e6b94f77b26a4a758c447a42d8a25b6ff 100644 --- a/src/main/java/org/bukkit/plugin/java/JavaPlugin.java +++ b/src/main/java/org/bukkit/plugin/java/JavaPlugin.java -@@ -38,6 +38,7 @@ public abstract class JavaPlugin extends PluginBase { +@@ -40,6 +40,7 @@ public abstract class JavaPlugin extends PluginBase { private Server server = null; private File file = null; private PluginDescriptionFile description = null; @@ -1873,7 +1873,7 @@ index 669a70faa95d0d6525a731d73499ed6fb0b48320..85619f03461a095b5cdb441da8994b1e private File dataFolder = null; private ClassLoader classLoader = null; private boolean naggable = true; -@@ -46,13 +47,16 @@ public abstract class JavaPlugin extends PluginBase { +@@ -48,13 +49,16 @@ public abstract class JavaPlugin extends PluginBase { private PluginLogger logger = null; public JavaPlugin() { @@ -1894,7 +1894,7 @@ index 669a70faa95d0d6525a731d73499ed6fb0b48320..85619f03461a095b5cdb441da8994b1e protected JavaPlugin(@NotNull final JavaPluginLoader loader, @NotNull final PluginDescriptionFile description, @NotNull final File dataFolder, @NotNull final File file) { final ClassLoader classLoader = this.getClass().getClassLoader(); if (classLoader instanceof PluginClassLoader) { -@@ -77,9 +81,12 @@ public abstract class JavaPlugin extends PluginBase { +@@ -79,9 +83,12 @@ public abstract class JavaPlugin extends PluginBase { * Gets the associated PluginLoader responsible for this plugin * * @return PluginLoader that controls this plugin @@ -1907,7 +1907,7 @@ index 669a70faa95d0d6525a731d73499ed6fb0b48320..85619f03461a095b5cdb441da8994b1e public final PluginLoader getPluginLoader() { return loader; } -@@ -120,13 +127,20 @@ public abstract class JavaPlugin extends PluginBase { +@@ -122,13 +129,20 @@ public abstract class JavaPlugin extends PluginBase { * Returns the plugin.yaml file containing the details for this plugin * * @return Contents of the plugin.yaml file @@ -1928,7 +1928,7 @@ index 669a70faa95d0d6525a731d73499ed6fb0b48320..85619f03461a095b5cdb441da8994b1e @NotNull @Override public FileConfiguration getConfig() { -@@ -256,7 +270,8 @@ public abstract class JavaPlugin extends PluginBase { +@@ -258,7 +272,8 @@ public abstract class JavaPlugin extends PluginBase { * * @param enabled true if enabled, otherwise false */ @@ -1938,7 +1938,7 @@ index 669a70faa95d0d6525a731d73499ed6fb0b48320..85619f03461a095b5cdb441da8994b1e if (isEnabled != enabled) { isEnabled = enabled; -@@ -268,9 +283,18 @@ public abstract class JavaPlugin extends PluginBase { +@@ -270,9 +285,18 @@ public abstract class JavaPlugin extends PluginBase { } } @@ -1960,7 +1960,7 @@ index 669a70faa95d0d6525a731d73499ed6fb0b48320..85619f03461a095b5cdb441da8994b1e this.server = server; this.file = file; this.description = description; -@@ -278,6 +302,7 @@ public abstract class JavaPlugin extends PluginBase { +@@ -280,6 +304,7 @@ public abstract class JavaPlugin extends PluginBase { this.classLoader = classLoader; this.configFile = new File(dataFolder, "config.yml"); this.logger = new PluginLogger(this); @@ -1968,7 +1968,7 @@ index 669a70faa95d0d6525a731d73499ed6fb0b48320..85619f03461a095b5cdb441da8994b1e } /** -@@ -394,10 +419,10 @@ public abstract class JavaPlugin extends PluginBase { +@@ -396,10 +421,10 @@ public abstract class JavaPlugin extends PluginBase { throw new IllegalArgumentException(clazz + " does not extend " + JavaPlugin.class); } final ClassLoader cl = clazz.getClassLoader(); @@ -1982,7 +1982,7 @@ index 669a70faa95d0d6525a731d73499ed6fb0b48320..85619f03461a095b5cdb441da8994b1e if (plugin == null) { throw new IllegalStateException("Cannot get plugin for " + clazz + " from a static initializer"); } -@@ -420,10 +445,10 @@ public abstract class JavaPlugin extends PluginBase { +@@ -422,10 +447,10 @@ public abstract class JavaPlugin extends PluginBase { public static JavaPlugin getProvidingPlugin(@NotNull Class clazz) { Preconditions.checkArgument(clazz != null, "Null class cannot have a plugin"); final ClassLoader cl = clazz.getClassLoader(); diff --git a/patches/api/0010-Timings-v2.patch b/patches/api/0010-Timings-v2.patch index 9ab2d9170e..668d38988c 100644 --- a/patches/api/0010-Timings-v2.patch +++ b/patches/api/0010-Timings-v2.patch @@ -3455,10 +3455,10 @@ index 516d7fc7812aac343782861d0d567f54aa578c2a..00000000000000000000000000000000 - // Spigot end -} diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java -index 743559d4cc248331578e0c2d2a026e7a270cb713..74608db3d7631cd1b434a2543fc278fbc097d090 100644 +index 8708ca080bda0f4ec43964db3a4e56cf73c6559a..28f27988d22c0f38b520273920a9965d64107569 100644 --- a/src/main/java/org/bukkit/entity/Player.java +++ b/src/main/java/org/bukkit/entity/Player.java -@@ -2121,7 +2121,14 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -2143,7 +2143,14 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM @Deprecated // Paper public void sendMessage(@NotNull net.md_5.bungee.api.ChatMessageType position, @Nullable java.util.UUID sender, @NotNull net.md_5.bungee.api.chat.BaseComponent... components) { throw new UnsupportedOperationException("Not supported yet."); diff --git a/patches/api/0012-Player-affects-spawning-API.patch b/patches/api/0012-Player-affects-spawning-API.patch index c9b35cad89..80b9acdbc9 100644 --- a/patches/api/0012-Player-affects-spawning-API.patch +++ b/patches/api/0012-Player-affects-spawning-API.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Player affects spawning API diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java -index 74608db3d7631cd1b434a2543fc278fbc097d090..475d0c44e91dd4afbebaa1089fa3d26b0efaddb9 100644 +index 28f27988d22c0f38b520273920a9965d64107569..6d68274302fc36dd7d32cf6fb2889f86baebab89 100644 --- a/src/main/java/org/bukkit/entity/Player.java +++ b/src/main/java/org/bukkit/entity/Player.java -@@ -1960,6 +1960,22 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -1982,6 +1982,22 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM @Deprecated // Paper public String getLocale(); diff --git a/patches/api/0017-Add-view-distance-API.patch b/patches/api/0017-Add-view-distance-API.patch index bf865e91b9..f65d617a04 100644 --- a/patches/api/0017-Add-view-distance-API.patch +++ b/patches/api/0017-Add-view-distance-API.patch @@ -8,10 +8,10 @@ Add per player no-tick, tick, and send view distances. Also add send/no-tick view distance to World. diff --git a/src/main/java/org/bukkit/World.java b/src/main/java/org/bukkit/World.java -index 2e26ed8492669de22cf9b652edc1e83d8eaa6e2a..1675aceb9f4ce21782ef85fab988173642498c6b 100644 +index 1a71d628d9f593157d92f0c9fda9d3214c138352..cc4e72335d8c66c8081ce64149ce3ac377e03323 100644 --- a/src/main/java/org/bukkit/World.java +++ b/src/main/java/org/bukkit/World.java -@@ -2709,6 +2709,62 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient +@@ -2661,6 +2661,62 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient int getSimulationDistance(); // Spigot end @@ -75,10 +75,10 @@ index 2e26ed8492669de22cf9b652edc1e83d8eaa6e2a..1675aceb9f4ce21782ef85fab9881736 public class Spigot { diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java -index 475d0c44e91dd4afbebaa1089fa3d26b0efaddb9..f9875ea45251f51ff4ffef9f1a0d75ba652e4d1f 100644 +index 6d68274302fc36dd7d32cf6fb2889f86baebab89..70f2cb3126a06079b31b7ea36501ce5253a805fe 100644 --- a/src/main/java/org/bukkit/entity/Player.java +++ b/src/main/java/org/bukkit/entity/Player.java -@@ -1974,6 +1974,78 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -1996,6 +1996,78 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM * @param affects Whether the player can affect mob spawning */ public void setAffectsSpawning(boolean affects); diff --git a/patches/api/0021-Graduate-bungeecord-chat-API-from-spigot-subclasses.patch b/patches/api/0021-Graduate-bungeecord-chat-API-from-spigot-subclasses.patch index 08bbbb0ccb..464a06835a 100644 --- a/patches/api/0021-Graduate-bungeecord-chat-API-from-spigot-subclasses.patch +++ b/patches/api/0021-Graduate-bungeecord-chat-API-from-spigot-subclasses.patch @@ -76,10 +76,10 @@ index 866559ab7cd3f351266fb41dce26a210a7702ff8..74e5f26c32e6e0c84c604b9704bfe672 * Gets the name of the update folder. The update folder is used to safely * update plugins at the right moment on a plugin load. diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java -index f9875ea45251f51ff4ffef9f1a0d75ba652e4d1f..97d80bd49a3e76c265e45795d13d813125c521f9 100644 +index 70f2cb3126a06079b31b7ea36501ce5253a805fe..b0df10469e98d439e534c26ecc8a5bae98c9b77c 100644 --- a/src/main/java/org/bukkit/entity/Player.java +++ b/src/main/java/org/bukkit/entity/Player.java -@@ -847,6 +847,42 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -848,6 +848,42 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM */ public void sendMap(@NotNull MapView map); diff --git a/patches/api/0025-Player-Tab-List-and-Title-APIs.patch b/patches/api/0025-Player-Tab-List-and-Title-APIs.patch index ecf0b157fd..19903d85ab 100644 --- a/patches/api/0025-Player-Tab-List-and-Title-APIs.patch +++ b/patches/api/0025-Player-Tab-List-and-Title-APIs.patch @@ -432,10 +432,10 @@ index 0000000000000000000000000000000000000000..9e90c3df567a65b48a0b9341f784eb90 + } +} diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java -index 97d80bd49a3e76c265e45795d13d813125c521f9..1dbc823ecf98a952d4c0addc4ada8fa31e1fa86b 100644 +index b0df10469e98d439e534c26ecc8a5bae98c9b77c..0f70b49877383351a5ba2033bc6537b7e0deed3b 100644 --- a/src/main/java/org/bukkit/entity/Player.java +++ b/src/main/java/org/bukkit/entity/Player.java -@@ -881,6 +881,131 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -882,6 +882,131 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM public default void sendMessage(net.md_5.bungee.api.ChatMessageType position, net.md_5.bungee.api.chat.BaseComponent... components) { spigot().sendMessage(position, components); } diff --git a/patches/api/0027-Complete-resource-pack-API.patch b/patches/api/0027-Complete-resource-pack-API.patch index 6599d2a152..d74e1c3064 100644 --- a/patches/api/0027-Complete-resource-pack-API.patch +++ b/patches/api/0027-Complete-resource-pack-API.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Complete resource pack API diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java -index 1dbc823ecf98a952d4c0addc4ada8fa31e1fa86b..e2a80794ae9bec17a9e00575fe71f13a9e4e1121 100644 +index 0f70b49877383351a5ba2033bc6537b7e0deed3b..f4db9cec173c5018f8896d157405150b67bca253 100644 --- a/src/main/java/org/bukkit/entity/Player.java +++ b/src/main/java/org/bukkit/entity/Player.java -@@ -1438,7 +1438,9 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -1460,7 +1460,9 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM * @throws IllegalArgumentException Thrown if the URL is null. * @throws IllegalArgumentException Thrown if the URL is too long. The * length restriction is an implementation specific arbitrary value. @@ -18,7 +18,7 @@ index 1dbc823ecf98a952d4c0addc4ada8fa31e1fa86b..e2a80794ae9bec17a9e00575fe71f13a public void setResourcePack(@NotNull String url); /** -@@ -2254,6 +2256,124 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -2276,6 +2278,124 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM default net.kyori.adventure.text.event.HoverEvent asHoverEvent(final @NotNull java.util.function.UnaryOperator op) { return net.kyori.adventure.text.event.HoverEvent.showEntity(op.apply(net.kyori.adventure.text.event.HoverEvent.ShowEntity.of(this.getType().getKey(), this.getUniqueId(), this.displayName()))); } diff --git a/patches/api/0046-Add-String-based-Action-Bar-API.patch b/patches/api/0046-Add-String-based-Action-Bar-API.patch index bf97c4136e..34ae48c21a 100644 --- a/patches/api/0046-Add-String-based-Action-Bar-API.patch +++ b/patches/api/0046-Add-String-based-Action-Bar-API.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Add String based Action Bar API diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java -index e2a80794ae9bec17a9e00575fe71f13a9e4e1121..11e45ffb88cab06ac988915f771e87100047eadf 100644 +index f4db9cec173c5018f8896d157405150b67bca253..3826a3f6c525ddb6308fc9ceab86764ab0087c33 100644 --- a/src/main/java/org/bukkit/entity/Player.java +++ b/src/main/java/org/bukkit/entity/Player.java -@@ -848,6 +848,39 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -849,6 +849,39 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM public void sendMap(@NotNull MapView map); // Paper start @@ -48,7 +48,7 @@ index e2a80794ae9bec17a9e00575fe71f13a9e4e1121..11e45ffb88cab06ac988915f771e8710 /** * Sends the component to the player * -@@ -875,9 +908,11 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -876,9 +909,11 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM /** * Sends an array of components as a single message to the specified screen position of this player * diff --git a/patches/api/0055-Fix-upstream-javadocs.patch b/patches/api/0055-Fix-upstream-javadocs.patch index 83365da07e..05cd6b5646 100644 --- a/patches/api/0055-Fix-upstream-javadocs.patch +++ b/patches/api/0055-Fix-upstream-javadocs.patch @@ -91,7 +91,7 @@ index 0cf808356a1a5c6fc4bcf97a694ed9beb80a776a..dc765dea47a9a1c1520fb16ddb24f814 * @return temperature at given coordinate */ diff --git a/src/main/java/org/bukkit/RegionAccessor.java b/src/main/java/org/bukkit/RegionAccessor.java -index a89fff5c164881be0286ec2240e94dd5883ecc40..0272ed71899a53b6f3761a3283391caa744d464d 100644 +index 43f5aab2fe70af5f570de1f21eca83905f1e2f57..05c29cbd2ae1ca0434a90f8389479bd608ca2ac1 100644 --- a/src/main/java/org/bukkit/RegionAccessor.java +++ b/src/main/java/org/bukkit/RegionAccessor.java @@ -158,7 +158,7 @@ public interface RegionAccessor { @@ -170,23 +170,10 @@ index 7d06f2a8f17cf42eeb05567e3f5c0c16074af9bc..9b5dcd897df91e6ba3c71c216e7a180b * @return an array containing all previous players */ diff --git a/src/main/java/org/bukkit/World.java b/src/main/java/org/bukkit/World.java -index 6f31709d3a8b2c6818c9c4c90c10230d53087995..d5a4b3fe7a791eed28508882e42e6490b4f96067 100644 +index 730894d0b1b891a59c7ad1d78ff1e2cd061ae913..4270367085a83c368f96c8eab669f1bdc0e74f4d 100644 --- a/src/main/java/org/bukkit/World.java +++ b/src/main/java/org/bukkit/World.java -@@ -1252,11 +1252,8 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient - - /** - * Spawn a {@link FallingBlock} entity at the given {@link Location} of -- * the specified {@link Material}. The material dictates what is falling. -+ * the specified {@link BlockData}. The block data dictates what is falling. - * When the FallingBlock hits the ground, it will place that block. -- *

-- * The Material must be a block type, check with {@link Material#isBlock() -- * material.isBlock()}. The Material may not be air. - * - * @param location The {@link Location} to spawn the FallingBlock - * @param data The block data -@@ -2623,7 +2620,7 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient +@@ -2575,7 +2575,7 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient /** * Find the closest nearby structure of a given {@link StructureType}. * Finding unexplored structures can, and will, block if the world is @@ -195,7 +182,7 @@ index 6f31709d3a8b2c6818c9c4c90c10230d53087995..d5a4b3fe7a791eed28508882e42e6490 * temporarily freezing while locating an unexplored structure. *

* The {@code radius} is not a rigid square radius. Each structure may alter -@@ -2657,7 +2654,7 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient +@@ -2609,7 +2609,7 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient /** * Find the closest nearby structure of a given {@link StructureType}. * Finding unexplored structures can, and will, block if the world is @@ -204,7 +191,7 @@ index 6f31709d3a8b2c6818c9c4c90c10230d53087995..d5a4b3fe7a791eed28508882e42e6490 * temporarily freezing while locating an unexplored structure. *

* The {@code radius} is not a rigid square radius. Each structure may alter -@@ -2690,7 +2687,7 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient +@@ -2642,7 +2642,7 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient /** * Find the closest nearby structure of a given {@link Structure}. Finding * unexplored structures can, and will, block if the world is looking in @@ -427,10 +414,10 @@ index ae9eaaa8e38e1d9dfc459926c7fc51ddb89de84a..b2ec535bb1b0ce0c114ddd7638b90218 @Override public int getConversionTime(); diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java -index 11e45ffb88cab06ac988915f771e87100047eadf..044f6c5c1b64ba97e25d075f4df2aa943dfd3557 100644 +index 3826a3f6c525ddb6308fc9ceab86764ab0087c33..f683159bd02d5c6ea7940f50deecf2f1a8105d5e 100644 --- a/src/main/java/org/bukkit/entity/Player.java +++ b/src/main/java/org/bukkit/entity/Player.java -@@ -311,15 +311,15 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -312,15 +312,15 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM /** * Saves the players current location, health, inventory, motion, and @@ -450,7 +437,7 @@ index 11e45ffb88cab06ac988915f771e87100047eadf..044f6c5c1b64ba97e25d075f4df2aa94 *

* Note: This will overwrite the players current inventory, health, * motion, etc, with the state from the saved dat file. -@@ -554,7 +554,7 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -555,7 +555,7 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM /** * Plays an effect to just this player. * @@ -459,7 +446,7 @@ index 11e45ffb88cab06ac988915f771e87100047eadf..044f6c5c1b64ba97e25d075f4df2aa94 * @param loc the location to play the effect at * @param effect the {@link Effect} * @param data a data bit needed for some effects -@@ -865,7 +865,7 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -866,7 +866,7 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM * * Use supplied alternative character to the section symbol to represent legacy color codes. * @@ -468,7 +455,7 @@ index 11e45ffb88cab06ac988915f771e87100047eadf..044f6c5c1b64ba97e25d075f4df2aa94 * @param message The message to send * @deprecated use {@link #sendActionBar(net.kyori.adventure.text.Component)} */ -@@ -1308,7 +1308,7 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -1330,7 +1330,7 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM /** * Allows this player to see a player that was previously hidden. If @@ -477,7 +464,7 @@ index 11e45ffb88cab06ac988915f771e87100047eadf..044f6c5c1b64ba97e25d075f4df2aa94 * remain hidden until the other plugin calls this method too. * * @param plugin Plugin that wants to show the player -@@ -1337,7 +1337,7 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -1359,7 +1359,7 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM /** * Allows this player to see an entity that was previously hidden. If @@ -1035,19 +1022,27 @@ index 62fbd7f6d8195bebcab7f704a0a485a1bbeca26c..5461f7fa75f5a065bb333b4a113640b5 * @return the currently held item * @see #getItemInMainHand() diff --git a/src/main/java/org/bukkit/inventory/ShapedRecipe.java b/src/main/java/org/bukkit/inventory/ShapedRecipe.java -index e57e600283702dd7fc60fa3baa1e1cc1b8574873..76b78f388dd3539917976e66831e51006692a2aa 100644 +index 8971ec20d36c4d1a8fb07ec4603221791a2b52b4..4c7f30877c608e327908a61e4bd68789191e2f3c 100644 --- a/src/main/java/org/bukkit/inventory/ShapedRecipe.java +++ b/src/main/java/org/bukkit/inventory/ShapedRecipe.java -@@ -38,8 +38,7 @@ public class ShapedRecipe implements Recipe, Keyed { +@@ -30,8 +30,6 @@ public class ShapedRecipe implements Recipe, Keyed { * @param result The item you want the recipe to create. * @see ShapedRecipe#shape(String...) * @see ShapedRecipe#setIngredient(char, Material) - * @see ShapedRecipe#setIngredient(char, Material, int) - * @see ShapedRecipe#setIngredient(char, MaterialData) -+ * @see ShapedRecipe#setIngredient(char, RecipeChoice) + * @see ShapedRecipe#setIngredient(char, RecipeChoice) + * @deprecated Recipes must have keys. Use {@link #ShapedRecipe(NamespacedKey, ItemStack)} + * instead. +@@ -52,8 +50,6 @@ public class ShapedRecipe implements Recipe, Keyed { + * @param result The item you want the recipe to create. + * @see ShapedRecipe#shape(String...) + * @see ShapedRecipe#setIngredient(char, Material) +- * @see ShapedRecipe#setIngredient(char, Material, int) +- * @see ShapedRecipe#setIngredient(char, MaterialData) + * @see ShapedRecipe#setIngredient(char, RecipeChoice) */ public ShapedRecipe(@NotNull NamespacedKey key, @NotNull ItemStack result) { - Preconditions.checkArgument(key != null, "key"); diff --git a/src/main/java/org/bukkit/inventory/ShapelessRecipe.java b/src/main/java/org/bukkit/inventory/ShapelessRecipe.java index df4c52f1f0be2409c7506b09167bd58b5602fa7a..74449a635aca84adcc1652e1e85f2d27dcaf6842 100644 --- a/src/main/java/org/bukkit/inventory/ShapelessRecipe.java diff --git a/patches/api/0070-Handle-plugin-prefixes-in-implementation-logging-con.patch b/patches/api/0070-Handle-plugin-prefixes-in-implementation-logging-con.patch index 68bcb69c9e..55b6e4b2f9 100644 --- a/patches/api/0070-Handle-plugin-prefixes-in-implementation-logging-con.patch +++ b/patches/api/0070-Handle-plugin-prefixes-in-implementation-logging-con.patch @@ -17,10 +17,10 @@ The implementation should handle plugin prefixes by displaying logger names when appropriate. diff --git a/src/main/java/org/bukkit/plugin/java/JavaPlugin.java b/src/main/java/org/bukkit/plugin/java/JavaPlugin.java -index c9cf9d361a1289aba383718733a2098b5eafb38f..71c8d2345eef6895edb8d210553ec3cddd9c76d0 100644 +index f594913e6b94f77b26a4a758c447a42d8a25b6ff..7cd9f98c042dc2bb80876af35c755f81bef34651 100644 --- a/src/main/java/org/bukkit/plugin/java/JavaPlugin.java +++ b/src/main/java/org/bukkit/plugin/java/JavaPlugin.java -@@ -44,7 +44,7 @@ public abstract class JavaPlugin extends PluginBase { +@@ -46,7 +46,7 @@ public abstract class JavaPlugin extends PluginBase { private boolean naggable = true; private FileConfiguration newConfig = null; private File configFile = null; @@ -29,7 +29,7 @@ index c9cf9d361a1289aba383718733a2098b5eafb38f..71c8d2345eef6895edb8d210553ec3cd public JavaPlugin() { // Paper start -@@ -301,8 +301,8 @@ public abstract class JavaPlugin extends PluginBase { +@@ -303,8 +303,8 @@ public abstract class JavaPlugin extends PluginBase { this.dataFolder = dataFolder; this.classLoader = classLoader; this.configFile = new File(dataFolder, "config.yml"); diff --git a/patches/api/0072-Add-workaround-for-plugins-modifying-the-parent-of-t.patch b/patches/api/0072-Add-workaround-for-plugins-modifying-the-parent-of-t.patch index 9c25108ff5..c10545a487 100644 --- a/patches/api/0072-Add-workaround-for-plugins-modifying-the-parent-of-t.patch +++ b/patches/api/0072-Add-workaround-for-plugins-modifying-the-parent-of-t.patch @@ -67,10 +67,10 @@ index 0000000000000000000000000000000000000000..087ee57fe5485bc760fadd45a176d4d9 + +} diff --git a/src/main/java/org/bukkit/plugin/java/JavaPlugin.java b/src/main/java/org/bukkit/plugin/java/JavaPlugin.java -index 71c8d2345eef6895edb8d210553ec3cddd9c76d0..2139377f7370a8352d36f2d10d2a726d528e1a47 100644 +index 7cd9f98c042dc2bb80876af35c755f81bef34651..5cd236965de12392d8c7aa81307c0ff1cc8673b1 100644 --- a/src/main/java/org/bukkit/plugin/java/JavaPlugin.java +++ b/src/main/java/org/bukkit/plugin/java/JavaPlugin.java -@@ -289,10 +289,10 @@ public abstract class JavaPlugin extends PluginBase { +@@ -291,10 +291,10 @@ public abstract class JavaPlugin extends PluginBase { .orElseThrow(); } public final void init(@NotNull PluginLoader loader, @NotNull Server server, @NotNull PluginDescriptionFile description, @NotNull File dataFolder, @NotNull File file, @NotNull ClassLoader classLoader) { @@ -83,7 +83,7 @@ index 71c8d2345eef6895edb8d210553ec3cddd9c76d0..2139377f7370a8352d36f2d10d2a726d // Paper end this.loader = DummyPluginLoaderImplHolder.INSTANCE; // Paper this.server = server; -@@ -302,7 +302,7 @@ public abstract class JavaPlugin extends PluginBase { +@@ -304,7 +304,7 @@ public abstract class JavaPlugin extends PluginBase { this.classLoader = classLoader; this.configFile = new File(dataFolder, "config.yml"); this.pluginMeta = configuration; // Paper diff --git a/patches/api/0076-Expose-client-protocol-version-and-virtual-host.patch b/patches/api/0076-Expose-client-protocol-version-and-virtual-host.patch index 509c5e749a..fa73f16c76 100644 --- a/patches/api/0076-Expose-client-protocol-version-and-virtual-host.patch +++ b/patches/api/0076-Expose-client-protocol-version-and-virtual-host.patch @@ -57,10 +57,10 @@ index 0000000000000000000000000000000000000000..7b2af1bd72dfbcf4e962a982940fc49b + +} diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java -index 044f6c5c1b64ba97e25d075f4df2aa943dfd3557..71b8600f05615a422c8b10505be8f09e30b32ac5 100644 +index f683159bd02d5c6ea7940f50deecf2f1a8105d5e..1d791f76151c1baa762d85cb82c6cfcd7b30d1ab 100644 --- a/src/main/java/org/bukkit/entity/Player.java +++ b/src/main/java/org/bukkit/entity/Player.java -@@ -40,7 +40,7 @@ import org.jetbrains.annotations.Nullable; +@@ -41,7 +41,7 @@ import org.jetbrains.annotations.Nullable; /** * Represents a player, connected or not */ diff --git a/patches/api/0077-Display-warning-on-deprecated-recipe-API.patch b/patches/api/0077-Display-warning-on-deprecated-recipe-API.patch index 3d2b357c11..bc3fa9520d 100644 --- a/patches/api/0077-Display-warning-on-deprecated-recipe-API.patch +++ b/patches/api/0077-Display-warning-on-deprecated-recipe-API.patch @@ -10,10 +10,10 @@ on the players login. Plugin authors need to define a key to keep it consistent between server restarts. diff --git a/src/main/java/org/bukkit/inventory/ShapedRecipe.java b/src/main/java/org/bukkit/inventory/ShapedRecipe.java -index e57e600283702dd7fc60fa3baa1e1cc1b8574873..7be830ea0a3b24c5cdfb8e6ab62cb2ee506a4026 100644 +index 4c7f30877c608e327908a61e4bd68789191e2f3c..be68263386a8faea7744f4de75d484e9358c87df 100644 --- a/src/main/java/org/bukkit/inventory/ShapedRecipe.java +++ b/src/main/java/org/bukkit/inventory/ShapedRecipe.java -@@ -26,6 +26,7 @@ public class ShapedRecipe implements Recipe, Keyed { +@@ -38,6 +38,7 @@ public class ShapedRecipe implements Recipe, Keyed { public ShapedRecipe(@NotNull ItemStack result) { Preconditions.checkArgument(result.getType() != Material.AIR, "Recipe must have non-AIR result."); this.key = NamespacedKey.randomKey(); @@ -22,7 +22,7 @@ index e57e600283702dd7fc60fa3baa1e1cc1b8574873..7be830ea0a3b24c5cdfb8e6ab62cb2ee } diff --git a/src/main/java/org/bukkit/inventory/ShapelessRecipe.java b/src/main/java/org/bukkit/inventory/ShapelessRecipe.java -index df4c52f1f0be2409c7506b09167bd58b5602fa7a..62675962d1b7882b953d2618aed1f363c046e97d 100644 +index 74449a635aca84adcc1652e1e85f2d27dcaf6842..05ef88225415cd30de36f4517b6fb40d826ce996 100644 --- a/src/main/java/org/bukkit/inventory/ShapelessRecipe.java +++ b/src/main/java/org/bukkit/inventory/ShapelessRecipe.java @@ -27,6 +27,7 @@ public class ShapelessRecipe implements Recipe, Keyed { diff --git a/patches/api/0080-Ability-to-apply-mending-to-XP-API.patch b/patches/api/0080-Ability-to-apply-mending-to-XP-API.patch index 4bd744853c..7c702078d0 100644 --- a/patches/api/0080-Ability-to-apply-mending-to-XP-API.patch +++ b/patches/api/0080-Ability-to-apply-mending-to-XP-API.patch @@ -10,10 +10,10 @@ of giving the player experience points. Both an API To standalone mend, and apply mending logic to .giveExp has been added. diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java -index 71b8600f05615a422c8b10505be8f09e30b32ac5..c111ab6d5a39ad9430d5bc6cb5c68e9c236504c9 100644 +index 1d791f76151c1baa762d85cb82c6cfcd7b30d1ab..89af3de0f439cfb5bde2a23147b2ba7da482f9c1 100644 --- a/src/main/java/org/bukkit/entity/Player.java +++ b/src/main/java/org/bukkit/entity/Player.java -@@ -1172,12 +1172,33 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -1173,6 +1173,15 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM */ public void resetPlayerWeather(); @@ -27,6 +27,9 @@ index 71b8600f05615a422c8b10505be8f09e30b32ac5..c111ab6d5a39ad9430d5bc6cb5c68e9c + giveExp(amount, false); + } /** + * Gets the player's cooldown between picking up experience orbs. + * +@@ -1198,8 +1207,20 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM * Gives the player the amount of experience specified. * * @param amount Exp amount to give diff --git a/patches/api/0091-Player.setPlayerProfile-API.patch b/patches/api/0091-Player.setPlayerProfile-API.patch index bbc770f80a..f305cd2757 100644 --- a/patches/api/0091-Player.setPlayerProfile-API.patch +++ b/patches/api/0091-Player.setPlayerProfile-API.patch @@ -43,10 +43,10 @@ index e6707eca1dd96a4fb6c019285c764684aa336ebf..008a960a63cf3efe87aab1e237c3b870 return server.createPlayerProfile(name); } diff --git a/src/main/java/org/bukkit/OfflinePlayer.java b/src/main/java/org/bukkit/OfflinePlayer.java -index c5eed3234a8c04bfa9d707685746fc2b40ec8bfc..3ba8ff1a41ac9fd96fd4dec5cbe0f714fef93022 100644 +index 5acb0d36a008cf5ad332c867e9303d35235b4028..b1ded556a1ce4e1d3c873ab9d7f799b6edcc5118 100644 --- a/src/main/java/org/bukkit/OfflinePlayer.java +++ b/src/main/java/org/bukkit/OfflinePlayer.java -@@ -50,7 +50,7 @@ public interface OfflinePlayer extends ServerOperator, AnimalTamer, Configuratio +@@ -55,7 +55,7 @@ public interface OfflinePlayer extends ServerOperator, AnimalTamer, Configuratio * @return the player's profile */ @NotNull @@ -93,10 +93,10 @@ index d769ad908c3454fa9088a42f32250bbdf8f9fa7e..2eaf31f1053787b39184dfa8ac6df87d /** diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java -index c111ab6d5a39ad9430d5bc6cb5c68e9c236504c9..6240b4059cd0847fdb0f1a630c6d7aa6cb43bfbf 100644 +index 89af3de0f439cfb5bde2a23147b2ba7da482f9c1..16f11367a92624d8dd45838d606f0031b1c86903 100644 --- a/src/main/java/org/bukkit/entity/Player.java +++ b/src/main/java/org/bukkit/entity/Player.java -@@ -2430,6 +2430,20 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -2452,6 +2452,20 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM * was {@link org.bukkit.event.player.PlayerResourcePackStatusEvent.Status#SUCCESSFULLY_LOADED} */ boolean hasResourcePack(); diff --git a/patches/api/0094-Add-openSign-method-to-HumanEntity.patch b/patches/api/0094-Add-openSign-method-to-HumanEntity.patch index b446ffd80c..caffd849d7 100644 --- a/patches/api/0094-Add-openSign-method-to-HumanEntity.patch +++ b/patches/api/0094-Add-openSign-method-to-HumanEntity.patch @@ -24,10 +24,10 @@ index abdca9fe5acc90f167219eb769ece66c35682bb1..9715a9d36187e2eecfeab1a05087d27c /** * Make the entity drop the item in their hand. diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java -index 6240b4059cd0847fdb0f1a630c6d7aa6cb43bfbf..fdc13706ac54ccba2eae2cc6240dbb67dcea3328 100644 +index 16f11367a92624d8dd45838d606f0031b1c86903..459c9f64a32ec0e5a83146ffff3e436393e60078 100644 --- a/src/main/java/org/bukkit/entity/Player.java +++ b/src/main/java/org/bukkit/entity/Player.java -@@ -2285,7 +2285,7 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -2307,7 +2307,7 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM /** * Open a Sign for editing by the Player. * diff --git a/patches/api/0095-Add-Ban-Methods-to-Player-Objects.patch b/patches/api/0095-Add-Ban-Methods-to-Player-Objects.patch index 51145b368f..95d50a7058 100644 --- a/patches/api/0095-Add-Ban-Methods-to-Player-Objects.patch +++ b/patches/api/0095-Add-Ban-Methods-to-Player-Objects.patch @@ -8,10 +8,10 @@ Allows a more logical API for banning players. player.banPlayer("Breaking the rules"); diff --git a/src/main/java/org/bukkit/OfflinePlayer.java b/src/main/java/org/bukkit/OfflinePlayer.java -index 3ba8ff1a41ac9fd96fd4dec5cbe0f714fef93022..b39ed4eb2e7d9e40805e201d77973877481db8fd 100644 +index b1ded556a1ce4e1d3c873ab9d7f799b6edcc5118..6ab8f05be11f8101202d56bfebc7ec23f868dddd 100644 --- a/src/main/java/org/bukkit/OfflinePlayer.java +++ b/src/main/java/org/bukkit/OfflinePlayer.java -@@ -58,6 +58,61 @@ public interface OfflinePlayer extends ServerOperator, AnimalTamer, Configuratio +@@ -63,6 +63,61 @@ public interface OfflinePlayer extends ServerOperator, AnimalTamer, Configuratio * @return true if banned, otherwise false */ public boolean isBanned(); @@ -74,10 +74,10 @@ index 3ba8ff1a41ac9fd96fd4dec5cbe0f714fef93022..b39ed4eb2e7d9e40805e201d77973877 /** * Checks if this player is whitelisted or not diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java -index fdc13706ac54ccba2eae2cc6240dbb67dcea3328..50e95f585ce516f9f9bc511d864f181fa3f7f5ac 100644 +index 459c9f64a32ec0e5a83146ffff3e436393e60078..fdbbe75cad2ecb6b4e404b775d64a49e176ce92c 100644 --- a/src/main/java/org/bukkit/entity/Player.java +++ b/src/main/java/org/bukkit/entity/Player.java -@@ -848,6 +848,162 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -849,6 +849,162 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM public void sendMap(@NotNull MapView map); // Paper start diff --git a/patches/api/0098-Additional-world.getNearbyEntities-API-s.patch b/patches/api/0098-Additional-world.getNearbyEntities-API-s.patch index eebbb3244b..22a0363f8b 100644 --- a/patches/api/0098-Additional-world.getNearbyEntities-API-s.patch +++ b/patches/api/0098-Additional-world.getNearbyEntities-API-s.patch @@ -6,7 +6,7 @@ Subject: [PATCH] Additional world.getNearbyEntities API's Provides more methods to get nearby entities, and filter by types and predicates diff --git a/src/main/java/org/bukkit/World.java b/src/main/java/org/bukkit/World.java -index d5a4b3fe7a791eed28508882e42e6490b4f96067..02ed403b0fcb1a45d931fa694362d4a7714d1248 100644 +index 4270367085a83c368f96c8eab669f1bdc0e74f4d..ee06fdba69313e5352e5d1dca381c8131112fc3a 100644 --- a/src/main/java/org/bukkit/World.java +++ b/src/main/java/org/bukkit/World.java @@ -1,6 +1,9 @@ @@ -19,7 +19,7 @@ index d5a4b3fe7a791eed28508882e42e6490b4f96067..02ed403b0fcb1a45d931fa694362d4a7 import java.util.Collection; import java.util.HashMap; import java.util.List; -@@ -668,6 +671,256 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient +@@ -623,6 +626,256 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient @NotNull public Collection getEntitiesByClasses(@NotNull Class... classes); diff --git a/patches/api/0100-Expand-World.spawnParticle-API-and-add-Builder.patch b/patches/api/0100-Expand-World.spawnParticle-API-and-add-Builder.patch index af9c478f4d..3d10997169 100644 --- a/patches/api/0100-Expand-World.spawnParticle-API-and-add-Builder.patch +++ b/patches/api/0100-Expand-World.spawnParticle-API-and-add-Builder.patch @@ -522,10 +522,10 @@ index 7336edb91e7095cce381318220496b51962afbe9..0125890a258ee58a43990285b341f8a6 * Options which can be applied to redstone dust particles - a particle * color and size. diff --git a/src/main/java/org/bukkit/World.java b/src/main/java/org/bukkit/World.java -index 02ed403b0fcb1a45d931fa694362d4a7714d1248..16204198a72ea24a291b0438dba36b4bd797df42 100644 +index ee06fdba69313e5352e5d1dca381c8131112fc3a..211d702f07e724d1c56f47048e05518d9f5bba5e 100644 --- a/src/main/java/org/bukkit/World.java +++ b/src/main/java/org/bukkit/World.java -@@ -2820,7 +2820,57 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient +@@ -2775,7 +2775,57 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient * @param data the data to use for the particle or null, * the type of this depends on {@link Particle#getDataType()} */ diff --git a/patches/api/0114-Expand-Explosions-API.patch b/patches/api/0114-Expand-Explosions-API.patch index 784827ad5a..8b32fd168e 100644 --- a/patches/api/0114-Expand-Explosions-API.patch +++ b/patches/api/0114-Expand-Explosions-API.patch @@ -106,10 +106,10 @@ index 6693e3d8dc2519facb12db981a6b6325faa095bf..5a6b33c6d9a68affdbd02c13fdb0854e * Returns a list of entities within a bounding box centered around a Location. * diff --git a/src/main/java/org/bukkit/World.java b/src/main/java/org/bukkit/World.java -index 16204198a72ea24a291b0438dba36b4bd797df42..9b9158266ab9701c462bed18a4dbc3be17b6efad 100644 +index 211d702f07e724d1c56f47048e05518d9f5bba5e..ca46efebe628ac558470e5b351a13821227f8c00 100644 --- a/src/main/java/org/bukkit/World.java +++ b/src/main/java/org/bukkit/World.java -@@ -1435,6 +1435,88 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient +@@ -1390,6 +1390,88 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient */ public boolean createExplosion(@NotNull Location loc, float power, boolean setFire); diff --git a/patches/api/0118-Add-World.getEntity-UUID-API.patch b/patches/api/0118-Add-World.getEntity-UUID-API.patch index 35a05407fd..b4ccc4acec 100644 --- a/patches/api/0118-Add-World.getEntity-UUID-API.patch +++ b/patches/api/0118-Add-World.getEntity-UUID-API.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Add World.getEntity(UUID) API diff --git a/src/main/java/org/bukkit/World.java b/src/main/java/org/bukkit/World.java -index 9b9158266ab9701c462bed18a4dbc3be17b6efad..29683e2ad918d8e9779578421abf7ef183bd45c0 100644 +index ca46efebe628ac558470e5b351a13821227f8c00..e0c9a5060d139a6b897d42518136f814e5174a9c 100644 --- a/src/main/java/org/bukkit/World.java +++ b/src/main/java/org/bukkit/World.java -@@ -955,6 +955,17 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient +@@ -910,6 +910,17 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient @NotNull public Collection getNearbyEntities(@NotNull Location location, double x, double y, double z); diff --git a/patches/api/0131-Add-TNTPrimeEvent.patch b/patches/api/0131-Add-TNTPrimeEvent.patch index 2bddc56f13..9282ea8794 100644 --- a/patches/api/0131-Add-TNTPrimeEvent.patch +++ b/patches/api/0131-Add-TNTPrimeEvent.patch @@ -6,10 +6,10 @@ Subject: [PATCH] Add TNTPrimeEvent diff --git a/src/main/java/com/destroystokyo/paper/event/block/TNTPrimeEvent.java b/src/main/java/com/destroystokyo/paper/event/block/TNTPrimeEvent.java new file mode 100644 -index 0000000000000000000000000000000000000000..73dabb82c7fbea3f0cccade0a2944b11a80ede06 +index 0000000000000000000000000000000000000000..9d7221583454dc922b20af6c233897c0b2ec47da --- /dev/null +++ b/src/main/java/com/destroystokyo/paper/event/block/TNTPrimeEvent.java -@@ -0,0 +1,114 @@ +@@ -0,0 +1,116 @@ +package com.destroystokyo.paper.event.block; + +import org.bukkit.block.Block; @@ -27,7 +27,9 @@ index 0000000000000000000000000000000000000000..73dabb82c7fbea3f0cccade0a2944b11 + * the TNT block as-is + * + * @author Mark Vainomaa ++ * @deprecated use {@link org.bukkit.event.block.TNTPrimeEvent} + */ ++@Deprecated(forRemoval = true) +public class TNTPrimeEvent extends BlockEvent implements Cancellable { + private static final HandlerList handlers = new HandlerList(); + private boolean cancelled; diff --git a/patches/api/0132-Provide-Chunk-Coordinates-as-a-Long-API.patch b/patches/api/0132-Provide-Chunk-Coordinates-as-a-Long-API.patch index a458c4c14c..2fe9b2cdc1 100644 --- a/patches/api/0132-Provide-Chunk-Coordinates-as-a-Long-API.patch +++ b/patches/api/0132-Provide-Chunk-Coordinates-as-a-Long-API.patch @@ -7,7 +7,7 @@ Allows you to easily access the chunks X/z as a long, and a method to look up by the long key too. diff --git a/src/main/java/org/bukkit/Chunk.java b/src/main/java/org/bukkit/Chunk.java -index 94db3cfa41ff80a53fcf456a394536a6a93c0c02..dc1a328e2202b755266b2564656f5bb60dd260cd 100644 +index efbfed855248cff8b4bdbfc181d3e82058df4749..766d643f0fe79660942fdad25e39e488e9379419 100644 --- a/src/main/java/org/bukkit/Chunk.java +++ b/src/main/java/org/bukkit/Chunk.java @@ -33,6 +33,32 @@ public interface Chunk extends PersistentDataHolder { @@ -44,10 +44,10 @@ index 94db3cfa41ff80a53fcf456a394536a6a93c0c02..dc1a328e2202b755266b2564656f5bb6 * Gets the world containing this chunk * diff --git a/src/main/java/org/bukkit/World.java b/src/main/java/org/bukkit/World.java -index 29683e2ad918d8e9779578421abf7ef183bd45c0..4b27d1b3086cd1504759b3b06bde665ea6d3a0ec 100644 +index e0c9a5060d139a6b897d42518136f814e5174a9c..710fb46ca92d9e4f3d9498603dd9e3f6a02269cc 100644 --- a/src/main/java/org/bukkit/World.java +++ b/src/main/java/org/bukkit/World.java -@@ -223,6 +223,22 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient +@@ -178,6 +178,22 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient @NotNull public Chunk getChunkAt(@NotNull Block block); diff --git a/patches/api/0135-Allow-Blocks-to-be-accessed-via-a-long-key.patch b/patches/api/0135-Allow-Blocks-to-be-accessed-via-a-long-key.patch index e0eadf4d4b..e18868b8ba 100644 --- a/patches/api/0135-Allow-Blocks-to-be-accessed-via-a-long-key.patch +++ b/patches/api/0135-Allow-Blocks-to-be-accessed-via-a-long-key.patch @@ -50,7 +50,7 @@ index 943c3364f6b931fe11f9a6099504590b2da34657..16a604b6315daff228c827fe02b1234c * @return A new location where X/Y/Z are the center of the block */ diff --git a/src/main/java/org/bukkit/World.java b/src/main/java/org/bukkit/World.java -index 7d6c923ea603a3193865e6a34b41617ac7016d19..00651d5486f1de886df7a4a01aaf272ceb0fa82a 100644 +index 710fb46ca92d9e4f3d9498603dd9e3f6a02269cc..ad862d3822594925d2a740b384f8c1b79c4d92fc 100644 --- a/src/main/java/org/bukkit/World.java +++ b/src/main/java/org/bukkit/World.java @@ -95,6 +95,40 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient @@ -92,10 +92,10 @@ index 7d6c923ea603a3193865e6a34b41617ac7016d19..00651d5486f1de886df7a4a01aaf272c + // Paper end + /** - * Gets the highest non-empty (impassable) coordinate at the given - * coordinates. + * Gets the highest non-empty (impassable) block at the given coordinates. + * diff --git a/src/main/java/org/bukkit/block/Block.java b/src/main/java/org/bukkit/block/Block.java -index 61ce341daec63392f040b70cd12662379b2f1ebd..0be73b2f45c9aab6e73bcb7a76136ec6e2428163 100644 +index 9f4d383ea3d6b26d16b8b77ca4c29d2d839ad6dd..78f6cc1a8a8de05aec6f551f8a5f425944f0ffa3 100644 --- a/src/main/java/org/bukkit/block/Block.java +++ b/src/main/java/org/bukkit/block/Block.java @@ -156,6 +156,82 @@ public interface Block extends Metadatable, Translatable { diff --git a/patches/api/0140-isChunkGenerated-API.patch b/patches/api/0140-isChunkGenerated-API.patch index 35161b9d4f..f041fe1564 100644 --- a/patches/api/0140-isChunkGenerated-API.patch +++ b/patches/api/0140-isChunkGenerated-API.patch @@ -34,10 +34,10 @@ index 16a604b6315daff228c827fe02b1234cca3e884d..20978b269a7757a561d6b872cc77898b /** * Sets the position of this Location and returns itself diff --git a/src/main/java/org/bukkit/World.java b/src/main/java/org/bukkit/World.java -index 0209dc06a6ddb7d30560efe5ba483238de33fd9c..fbfe1e0923eddefbb378c3e150f0bb08802fa812 100644 +index ad862d3822594925d2a740b384f8c1b79c4d92fc..9d3a3d67712037a4edb723dbf3c9f121680f2b7a 100644 --- a/src/main/java/org/bukkit/World.java +++ b/src/main/java/org/bukkit/World.java -@@ -271,6 +271,17 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient +@@ -226,6 +226,17 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient public default Chunk getChunkAt(long chunkKey) { return getChunkAt((int) chunkKey, (int) (chunkKey >> 32)); } diff --git a/patches/api/0142-Async-Chunks-API.patch b/patches/api/0142-Async-Chunks-API.patch index 497d511712..bb7c1c3879 100644 --- a/patches/api/0142-Async-Chunks-API.patch +++ b/patches/api/0142-Async-Chunks-API.patch @@ -8,10 +8,10 @@ Adds API's to load or generate chunks asynchronously. Also adds utility methods to Entity to teleport asynchronously. diff --git a/src/main/java/org/bukkit/World.java b/src/main/java/org/bukkit/World.java -index fbfe1e0923eddefbb378c3e150f0bb08802fa812..4031b2c3b7d6870f649e76f47a72e31a0f300c00 100644 +index 9d3a3d67712037a4edb723dbf3c9f121680f2b7a..75511f11d4c43dc997b6eb8947a2f225301ea29e 100644 --- a/src/main/java/org/bukkit/World.java +++ b/src/main/java/org/bukkit/World.java -@@ -980,6 +980,482 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient +@@ -935,6 +935,482 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient } return nearby; } diff --git a/patches/api/0144-Expose-attack-cooldown-methods-for-Player.patch b/patches/api/0144-Expose-attack-cooldown-methods-for-Player.patch index 0a1754ce39..9c321b401c 100644 --- a/patches/api/0144-Expose-attack-cooldown-methods-for-Player.patch +++ b/patches/api/0144-Expose-attack-cooldown-methods-for-Player.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Expose attack cooldown methods for Player diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java -index 50e95f585ce516f9f9bc511d864f181fa3f7f5ac..e0d2f9e6d785b7785fc59db8814c5278962a3f06 100644 +index fdbbe75cad2ecb6b4e404b775d64a49e176ce92c..23ded8a67663d887f636a2b04d7a7afb86ead22c 100644 --- a/src/main/java/org/bukkit/entity/Player.java +++ b/src/main/java/org/bukkit/entity/Player.java -@@ -2600,6 +2600,26 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -2622,6 +2622,26 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM * @param profile The new profile to use */ void setPlayerProfile(@NotNull com.destroystokyo.paper.profile.PlayerProfile profile); diff --git a/patches/api/0156-Add-sun-related-API.patch b/patches/api/0156-Add-sun-related-API.patch index 1870ff232d..b7f93bd01f 100644 --- a/patches/api/0156-Add-sun-related-API.patch +++ b/patches/api/0156-Add-sun-related-API.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Add sun related API diff --git a/src/main/java/org/bukkit/World.java b/src/main/java/org/bukkit/World.java -index 4031b2c3b7d6870f649e76f47a72e31a0f300c00..e91f6e4a9246a30ba7c0274ccbfc2fdf5a384c7a 100644 +index 75511f11d4c43dc997b6eb8947a2f225301ea29e..4587b866d3d3bcd0080f072245d46f719d61f767 100644 --- a/src/main/java/org/bukkit/World.java +++ b/src/main/java/org/bukkit/World.java -@@ -1807,6 +1807,16 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient +@@ -1762,6 +1762,16 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient */ public void setFullTime(long time); diff --git a/patches/api/0165-Add-APIs-to-replace-OfflinePlayer-getLastPlayed.patch b/patches/api/0165-Add-APIs-to-replace-OfflinePlayer-getLastPlayed.patch index 79029fc972..95255e34fe 100644 --- a/patches/api/0165-Add-APIs-to-replace-OfflinePlayer-getLastPlayed.patch +++ b/patches/api/0165-Add-APIs-to-replace-OfflinePlayer-getLastPlayed.patch @@ -16,10 +16,10 @@ intent to remove) and replace it with two new methods, clearly named and documented as to their purpose. diff --git a/src/main/java/org/bukkit/OfflinePlayer.java b/src/main/java/org/bukkit/OfflinePlayer.java -index b39ed4eb2e7d9e40805e201d77973877481db8fd..69b50eee42e8c52063033705bd23a5ef5231ed83 100644 +index 6ab8f05be11f8101202d56bfebc7ec23f868dddd..72175dcae49f75b494ab70958053ed994a8828f4 100644 --- a/src/main/java/org/bukkit/OfflinePlayer.java +++ b/src/main/java/org/bukkit/OfflinePlayer.java -@@ -160,7 +160,9 @@ public interface OfflinePlayer extends ServerOperator, AnimalTamer, Configuratio +@@ -165,7 +165,9 @@ public interface OfflinePlayer extends ServerOperator, AnimalTamer, Configuratio * UTC. * * @return Date of last log-in for this player, or 0 @@ -29,7 +29,7 @@ index b39ed4eb2e7d9e40805e201d77973877481db8fd..69b50eee42e8c52063033705bd23a5ef public long getLastPlayed(); /** -@@ -178,6 +180,30 @@ public interface OfflinePlayer extends ServerOperator, AnimalTamer, Configuratio +@@ -183,6 +185,30 @@ public interface OfflinePlayer extends ServerOperator, AnimalTamer, Configuratio */ @Nullable public Location getBedSpawnLocation(); diff --git a/patches/api/0166-Add-ItemStack-Recipe-API-helper-methods.patch b/patches/api/0166-Add-ItemStack-Recipe-API-helper-methods.patch index 82c9f462c3..fe9311b8f9 100644 --- a/patches/api/0166-Add-ItemStack-Recipe-API-helper-methods.patch +++ b/patches/api/0166-Add-ItemStack-Recipe-API-helper-methods.patch @@ -9,10 +9,10 @@ Redirects some of upstream's APIs to these new methods to avoid usage of magic values and the deprecated RecipeChoice#getItemStack diff --git a/src/main/java/org/bukkit/inventory/ShapedRecipe.java b/src/main/java/org/bukkit/inventory/ShapedRecipe.java -index beaccd383df0d1fa1b1c88953d72198c2237a6a6..7a73a8dc30c5c3acfe8c686a0328728c17bd8e66 100644 +index be68263386a8faea7744f4de75d484e9358c87df..c2d224b6472a65cd362e1ab55ce7e3d0b5a3befc 100644 --- a/src/main/java/org/bukkit/inventory/ShapedRecipe.java +++ b/src/main/java/org/bukkit/inventory/ShapedRecipe.java -@@ -145,6 +145,13 @@ public class ShapedRecipe implements Recipe, Keyed { +@@ -180,6 +180,13 @@ public class ShapedRecipe implements Recipe, Keyed { return this; } diff --git a/patches/api/0172-Fix-Spigot-annotation-mistakes.patch b/patches/api/0172-Fix-Spigot-annotation-mistakes.patch index c2b85a59f7..7203ac5963 100644 --- a/patches/api/0172-Fix-Spigot-annotation-mistakes.patch +++ b/patches/api/0172-Fix-Spigot-annotation-mistakes.patch @@ -243,10 +243,10 @@ index e455eb21abf121dc6ff10ff8a13dd06f67096a8f..bbc01e7c192ae6689c301670047ff114 return origin; } diff --git a/src/main/java/org/bukkit/World.java b/src/main/java/org/bukkit/World.java -index e91f6e4a9246a30ba7c0274ccbfc2fdf5a384c7a..e863d8affe3fdc95c4100eb08ecf6d02b24a9e0f 100644 +index 4587b866d3d3bcd0080f072245d46f719d61f767..d667ac100f1bf11f4a8f9e8c53887a86e890ac6f 100644 --- a/src/main/java/org/bukkit/World.java +++ b/src/main/java/org/bukkit/World.java -@@ -441,9 +441,8 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient +@@ -396,9 +396,8 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient * @param z Z-coordinate of the chunk * @return Whether the chunk was actually refreshed * @@ -257,7 +257,7 @@ index e91f6e4a9246a30ba7c0274ccbfc2fdf5a384c7a..e863d8affe3fdc95c4100eb08ecf6d02 public boolean refreshChunk(int x, int z); /** -@@ -2153,8 +2152,10 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient +@@ -2111,8 +2110,10 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient * @return The spawned {@link FallingBlock} instance * @throws IllegalArgumentException if {@link Location} or {@link * MaterialData} are null or {@link Material} of the {@link MaterialData} is not a block @@ -739,13 +739,13 @@ index 5461f7fa75f5a065bb333b4a113640b5fe1e3825..c4d657727e508cb941320730a9d3aa54 /** diff --git a/src/main/java/org/bukkit/inventory/ShapedRecipe.java b/src/main/java/org/bukkit/inventory/ShapedRecipe.java -index 7a73a8dc30c5c3acfe8c686a0328728c17bd8e66..60745c16264991ab9365e8f9704ff87cf1fadd43 100644 +index c2d224b6472a65cd362e1ab55ce7e3d0b5a3befc..833322283bdddc16524ddb56aaa481bf36881eeb 100644 --- a/src/main/java/org/bukkit/inventory/ShapedRecipe.java +++ b/src/main/java/org/bukkit/inventory/ShapedRecipe.java -@@ -96,8 +96,10 @@ public class ShapedRecipe implements Recipe, Keyed { - * @param key The character that represents the ingredient in the shape. +@@ -112,8 +112,10 @@ public class ShapedRecipe implements Recipe, Keyed { * @param ingredient The ingredient. * @return The changed recipe, so you can chain calls. + * @throws IllegalArgumentException if the {@code key} does not appear in the shape. + * @deprecated use {@link #setIngredient(char, RecipeChoice)} */ @NotNull @@ -753,7 +753,7 @@ index 7a73a8dc30c5c3acfe8c686a0328728c17bd8e66..60745c16264991ab9365e8f9704ff87c public ShapedRecipe setIngredient(char key, @NotNull MaterialData ingredient) { return setIngredient(key, ingredient.getItemType(), ingredient.getData()); } -@@ -156,7 +158,9 @@ public class ShapedRecipe implements Recipe, Keyed { +@@ -191,7 +193,9 @@ public class ShapedRecipe implements Recipe, Keyed { * Get a copy of the ingredients map. * * @return The mapping of character to ingredients. diff --git a/patches/api/0175-Add-Heightmap-API.patch b/patches/api/0175-Add-Heightmap-API.patch index 4c029e4fc2..56d9ce39cc 100644 --- a/patches/api/0175-Add-Heightmap-API.patch +++ b/patches/api/0175-Add-Heightmap-API.patch @@ -103,10 +103,10 @@ index 2b9a117804a8ca54b47e51e23359bd6e01087641..6bbf8468bc47e82b0aeb164e49cdb73d * Creates explosion at this location with given power * diff --git a/src/main/java/org/bukkit/World.java b/src/main/java/org/bukkit/World.java -index f57e59dd5db687fb4feb13e8283e4ff327c3e8c4..30d5ed45df901a4931a35cc62aec08818307ec99 100644 +index d667ac100f1bf11f4a8f9e8c53887a86e890ac6f..711fc41dbd029fa2d43f35165b62d09de89509b7 100644 --- a/src/main/java/org/bukkit/World.java +++ b/src/main/java/org/bukkit/World.java -@@ -167,6 +167,87 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient +@@ -148,6 +148,87 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient @NotNull public Block getHighestBlockAt(@NotNull Location location); @@ -192,5 +192,5 @@ index f57e59dd5db687fb4feb13e8283e4ff327c3e8c4..30d5ed45df901a4931a35cc62aec0881 + // Paper end + /** - * Gets the highest coordinate corresponding to the {@link HeightMap} at the + * Gets the highest block corresponding to the {@link HeightMap} at the * given coordinates. diff --git a/patches/api/0189-Add-Player-Client-Options-API.patch b/patches/api/0189-Add-Player-Client-Options-API.patch index 0824462892..dbf5dceb38 100644 --- a/patches/api/0189-Add-Player-Client-Options-API.patch +++ b/patches/api/0189-Add-Player-Client-Options-API.patch @@ -229,10 +229,10 @@ index 0000000000000000000000000000000000000000..cf67dc7d465223710adbf2b798109f52 + } +} diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java -index e0d2f9e6d785b7785fc59db8814c5278962a3f06..e258aba2abcd2bacf6fb5fd7e2a04740c054cbc4 100644 +index 23ded8a67663d887f636a2b04d7a7afb86ead22c..75c15bf4ad598fabc0b9598ab7a0bb57afa61111 100644 --- a/src/main/java/org/bukkit/entity/Player.java +++ b/src/main/java/org/bukkit/entity/Player.java -@@ -2620,6 +2620,12 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -2642,6 +2642,12 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM * Reset the cooldown counter to 0, effectively starting the cooldown period. */ void resetCooldown(); diff --git a/patches/api/0206-Brand-support.patch b/patches/api/0206-Brand-support.patch index e64c5e7d75..520dedd875 100644 --- a/patches/api/0206-Brand-support.patch +++ b/patches/api/0206-Brand-support.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Brand support diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java -index e258aba2abcd2bacf6fb5fd7e2a04740c054cbc4..b51107775775e308ae0aee87f0636eb33bf0f452 100644 +index 75c15bf4ad598fabc0b9598ab7a0bb57afa61111..c1b7e15c04027ce61621b74ae188f51c883bfc29 100644 --- a/src/main/java/org/bukkit/entity/Player.java +++ b/src/main/java/org/bukkit/entity/Player.java -@@ -2752,6 +2752,16 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -2774,6 +2774,16 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM // Paper end } diff --git a/patches/api/0209-Add-moon-phase-API.patch b/patches/api/0209-Add-moon-phase-API.patch index 1a307b0721..68b36e3b64 100644 --- a/patches/api/0209-Add-moon-phase-API.patch +++ b/patches/api/0209-Add-moon-phase-API.patch @@ -47,13 +47,13 @@ index 0000000000000000000000000000000000000000..df05153397b42930cd53d37b30824c7e + } +} diff --git a/src/main/java/org/bukkit/RegionAccessor.java b/src/main/java/org/bukkit/RegionAccessor.java -index e55f6e2baf35dbd91c433ab9e62713eaac85435b..2fa3de66107162ccaa158b369e2c4a926ecaff92 100644 +index 66bc6da2a482bb207ec50beb22fd62aeda90cc34..501dd5a26c27294420821b3d75f8938596afb1a8 100644 --- a/src/main/java/org/bukkit/RegionAccessor.java +++ b/src/main/java/org/bukkit/RegionAccessor.java -@@ -376,4 +376,12 @@ public interface RegionAccessor { +@@ -421,4 +421,12 @@ public interface RegionAccessor { + * {@link HeightMap} */ - @NotNull - public T spawn(@NotNull Location location, @NotNull Class clazz, boolean randomizeData, @Nullable Consumer function) throws IllegalArgumentException; + public int getHighestBlockYAt(@NotNull Location location, @NotNull HeightMap heightMap); + + // Paper start + /** diff --git a/patches/api/0218-Player-elytra-boost-API.patch b/patches/api/0218-Player-elytra-boost-API.patch index b673a57166..088b6b3010 100644 --- a/patches/api/0218-Player-elytra-boost-API.patch +++ b/patches/api/0218-Player-elytra-boost-API.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Player elytra boost API diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java -index b51107775775e308ae0aee87f0636eb33bf0f452..74d7ca681a3a1ff31ad2d7b440b918bc499c1ea8 100644 +index c1b7e15c04027ce61621b74ae188f51c883bfc29..da34d0151dd71ff93db9a1b76271a8fe398ace66 100644 --- a/src/main/java/org/bukkit/entity/Player.java +++ b/src/main/java/org/bukkit/entity/Player.java -@@ -2626,6 +2626,19 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -2648,6 +2648,19 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM */ @NotNull T getClientOption(@NotNull com.destroystokyo.paper.ClientOption option); diff --git a/patches/api/0245-Add-sendOpLevel-API.patch b/patches/api/0245-Add-sendOpLevel-API.patch index 7ed0216508..8adf5efb6d 100644 --- a/patches/api/0245-Add-sendOpLevel-API.patch +++ b/patches/api/0245-Add-sendOpLevel-API.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Add sendOpLevel API diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java -index 74d7ca681a3a1ff31ad2d7b440b918bc499c1ea8..87a0b438aa5af2193eab43ac18616b9340479ae7 100644 +index da34d0151dd71ff93db9a1b76271a8fe398ace66..842d26eb83836e1d11a5a6b0dbe5f1666bc3b7d7 100644 --- a/src/main/java/org/bukkit/entity/Player.java +++ b/src/main/java/org/bukkit/entity/Player.java -@@ -2639,6 +2639,17 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -2661,6 +2661,17 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM */ @Nullable Firework boostElytra(@NotNull ItemStack firework); diff --git a/patches/api/0249-Add-BlockPreDispenseEvent.patch b/patches/api/0248-Add-BlockPreDispenseEvent.patch similarity index 100% rename from patches/api/0249-Add-BlockPreDispenseEvent.patch rename to patches/api/0248-Add-BlockPreDispenseEvent.patch diff --git a/patches/api/0248-Return-chat-component-with-empty-text-instead-of-thr.patch b/patches/api/0248-Return-chat-component-with-empty-text-instead-of-thr.patch deleted file mode 100644 index 73b9ed0483..0000000000 --- a/patches/api/0248-Return-chat-component-with-empty-text-instead-of-thr.patch +++ /dev/null @@ -1,20 +0,0 @@ -From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 -From: CDFN -Date: Tue, 7 Jul 2020 17:53:23 +0200 -Subject: [PATCH] Return chat component with empty text instead of throwing - exception - - -diff --git a/src/main/java/org/bukkit/inventory/InventoryView.java b/src/main/java/org/bukkit/inventory/InventoryView.java -index dbf316b63bf3d0c0695ceca84985d67f0f95c906..daca40b63e95ea33178bcb54ad45911da591ca54 100644 ---- a/src/main/java/org/bukkit/inventory/InventoryView.java -+++ b/src/main/java/org/bukkit/inventory/InventoryView.java -@@ -451,7 +451,7 @@ public abstract class InventoryView { - /** - * Get the title of this inventory window. - * -- * @return The title. -+ * @return The title or empty string when title is {@code null}. - */ - @NotNull - public /*abstract*/ net.kyori.adventure.text.Component title() { diff --git a/patches/api/0250-Added-missing-vanilla-tags.patch b/patches/api/0249-Added-missing-vanilla-tags.patch similarity index 100% rename from patches/api/0250-Added-missing-vanilla-tags.patch rename to patches/api/0249-Added-missing-vanilla-tags.patch diff --git a/patches/api/0251-Added-PlayerChangeBeaconEffectEvent.patch b/patches/api/0250-Added-PlayerChangeBeaconEffectEvent.patch similarity index 100% rename from patches/api/0251-Added-PlayerChangeBeaconEffectEvent.patch rename to patches/api/0250-Added-PlayerChangeBeaconEffectEvent.patch diff --git a/patches/api/0252-Added-PlayerStonecutterRecipeSelectEvent.patch b/patches/api/0251-Added-PlayerStonecutterRecipeSelectEvent.patch similarity index 100% rename from patches/api/0252-Added-PlayerStonecutterRecipeSelectEvent.patch rename to patches/api/0251-Added-PlayerStonecutterRecipeSelectEvent.patch diff --git a/patches/api/0253-Add-dropLeash-variable-to-EntityUnleashEvent.patch b/patches/api/0252-Add-dropLeash-variable-to-EntityUnleashEvent.patch similarity index 100% rename from patches/api/0253-Add-dropLeash-variable-to-EntityUnleashEvent.patch rename to patches/api/0252-Add-dropLeash-variable-to-EntityUnleashEvent.patch diff --git a/patches/api/0254-add-DragonEggFormEvent.patch b/patches/api/0253-add-DragonEggFormEvent.patch similarity index 100% rename from patches/api/0254-add-DragonEggFormEvent.patch rename to patches/api/0253-add-DragonEggFormEvent.patch diff --git a/patches/api/0255-EntityMoveEvent.patch b/patches/api/0254-EntityMoveEvent.patch similarity index 100% rename from patches/api/0255-EntityMoveEvent.patch rename to patches/api/0254-EntityMoveEvent.patch diff --git a/patches/api/0256-Allow-adding-items-to-BlockDropItemEvent.patch b/patches/api/0255-Allow-adding-items-to-BlockDropItemEvent.patch similarity index 100% rename from patches/api/0256-Allow-adding-items-to-BlockDropItemEvent.patch rename to patches/api/0255-Allow-adding-items-to-BlockDropItemEvent.patch diff --git a/patches/api/0257-Add-getMainThreadExecutor-to-BukkitScheduler.patch b/patches/api/0256-Add-getMainThreadExecutor-to-BukkitScheduler.patch similarity index 100% rename from patches/api/0257-Add-getMainThreadExecutor-to-BukkitScheduler.patch rename to patches/api/0256-Add-getMainThreadExecutor-to-BukkitScheduler.patch diff --git a/patches/api/0258-living-entity-allow-attribute-registration.patch b/patches/api/0257-living-entity-allow-attribute-registration.patch similarity index 100% rename from patches/api/0258-living-entity-allow-attribute-registration.patch rename to patches/api/0257-living-entity-allow-attribute-registration.patch diff --git a/patches/api/0259-Add-missing-effects.patch b/patches/api/0258-Add-missing-effects.patch similarity index 100% rename from patches/api/0259-Add-missing-effects.patch rename to patches/api/0258-Add-missing-effects.patch diff --git a/patches/api/0260-Expose-Tracked-Players.patch b/patches/api/0259-Expose-Tracked-Players.patch similarity index 100% rename from patches/api/0260-Expose-Tracked-Players.patch rename to patches/api/0259-Expose-Tracked-Players.patch diff --git a/patches/api/0261-Cache-the-result-of-Material-isBlock.patch b/patches/api/0260-Cache-the-result-of-Material-isBlock.patch similarity index 100% rename from patches/api/0261-Cache-the-result-of-Material-isBlock.patch rename to patches/api/0260-Cache-the-result-of-Material-isBlock.patch diff --git a/patches/api/0262-Add-worldborder-events.patch b/patches/api/0261-Add-worldborder-events.patch similarity index 100% rename from patches/api/0262-Add-worldborder-events.patch rename to patches/api/0261-Add-worldborder-events.patch diff --git a/patches/api/0263-added-PlayerNameEntityEvent.patch b/patches/api/0262-added-PlayerNameEntityEvent.patch similarity index 100% rename from patches/api/0263-added-PlayerNameEntityEvent.patch rename to patches/api/0262-added-PlayerNameEntityEvent.patch diff --git a/patches/api/0264-Add-recipe-to-cook-events.patch b/patches/api/0263-Add-recipe-to-cook-events.patch similarity index 100% rename from patches/api/0264-Add-recipe-to-cook-events.patch rename to patches/api/0263-Add-recipe-to-cook-events.patch diff --git a/patches/api/0265-Add-Block-isValidTool.patch b/patches/api/0264-Add-Block-isValidTool.patch similarity index 90% rename from patches/api/0265-Add-Block-isValidTool.patch rename to patches/api/0264-Add-Block-isValidTool.patch index 84a641142e..182e364647 100644 --- a/patches/api/0265-Add-Block-isValidTool.patch +++ b/patches/api/0264-Add-Block-isValidTool.patch @@ -5,7 +5,7 @@ Subject: [PATCH] Add Block#isValidTool diff --git a/src/main/java/org/bukkit/block/Block.java b/src/main/java/org/bukkit/block/Block.java -index 4abd16a4e99ae0380b67c86b9744d71423053b5e..96a3466181a6829e1868b5f5249349e8fd2cdd09 100644 +index 6c0249863601e8f0fc06828574315a9f0af66e5b..93b9b57c95a0d24e885a205cd9d9e05a5631806a 100644 --- a/src/main/java/org/bukkit/block/Block.java +++ b/src/main/java/org/bukkit/block/Block.java @@ -230,6 +230,15 @@ public interface Block extends Metadatable, Translatable, net.kyori.adventure.tr diff --git a/patches/api/0266-Expand-world-key-API.patch b/patches/api/0265-Expand-world-key-API.patch similarity index 97% rename from patches/api/0266-Expand-world-key-API.patch rename to patches/api/0265-Expand-world-key-API.patch index 258c8f382b..af6bc6174c 100644 --- a/patches/api/0266-Expand-world-key-API.patch +++ b/patches/api/0265-Expand-world-key-API.patch @@ -28,7 +28,7 @@ index 7cef6511b9b986fd5b3c59072e099f7a4ebb5fc4..041c6a9a1adce389f3a7ca6e5bbb7cfe /** * Create a new virtual {@link WorldBorder}. diff --git a/src/main/java/org/bukkit/RegionAccessor.java b/src/main/java/org/bukkit/RegionAccessor.java -index 393470e6a567d74d692fad30a7cecdff4e522ea3..f30fff08bf04c4d274b2ce242a135a14924f1cb0 100644 +index 501dd5a26c27294420821b3d75f8938596afb1a8..71ef9b479888aa83455757560b60745572c7196d 100644 --- a/src/main/java/org/bukkit/RegionAccessor.java +++ b/src/main/java/org/bukkit/RegionAccessor.java @@ -19,7 +19,7 @@ import org.jetbrains.annotations.Nullable; @@ -40,7 +40,7 @@ index 393470e6a567d74d692fad30a7cecdff4e522ea3..f30fff08bf04c4d274b2ce242a135a14 /** * Gets the {@link Biome} at the given {@link Location}. -@@ -383,5 +383,14 @@ public interface RegionAccessor { +@@ -428,5 +428,14 @@ public interface RegionAccessor { */ @NotNull io.papermc.paper.world.MoonPhase getMoonPhase(); diff --git a/patches/api/0267-Item-Rarity-API.patch b/patches/api/0266-Item-Rarity-API.patch similarity index 100% rename from patches/api/0267-Item-Rarity-API.patch rename to patches/api/0266-Item-Rarity-API.patch diff --git a/patches/api/0268-Expose-protocol-version.patch b/patches/api/0267-Expose-protocol-version.patch similarity index 100% rename from patches/api/0268-Expose-protocol-version.patch rename to patches/api/0267-Expose-protocol-version.patch diff --git a/patches/api/0269-add-isDeeplySleeping-to-HumanEntity.patch b/patches/api/0268-add-isDeeplySleeping-to-HumanEntity.patch similarity index 100% rename from patches/api/0269-add-isDeeplySleeping-to-HumanEntity.patch rename to patches/api/0268-add-isDeeplySleeping-to-HumanEntity.patch diff --git a/patches/api/0270-add-consumeFuel-to-FurnaceBurnEvent.patch b/patches/api/0269-add-consumeFuel-to-FurnaceBurnEvent.patch similarity index 100% rename from patches/api/0270-add-consumeFuel-to-FurnaceBurnEvent.patch rename to patches/api/0269-add-consumeFuel-to-FurnaceBurnEvent.patch diff --git a/patches/api/0271-add-get-set-drop-chance-to-EntityEquipment.patch b/patches/api/0270-add-get-set-drop-chance-to-EntityEquipment.patch similarity index 100% rename from patches/api/0271-add-get-set-drop-chance-to-EntityEquipment.patch rename to patches/api/0270-add-get-set-drop-chance-to-EntityEquipment.patch diff --git a/patches/api/0272-Added-PlayerDeepSleepEvent.patch b/patches/api/0271-Added-PlayerDeepSleepEvent.patch similarity index 100% rename from patches/api/0272-Added-PlayerDeepSleepEvent.patch rename to patches/api/0271-Added-PlayerDeepSleepEvent.patch diff --git a/patches/api/0273-More-World-API.patch b/patches/api/0272-More-World-API.patch similarity index 95% rename from patches/api/0273-More-World-API.patch rename to patches/api/0272-More-World-API.patch index c8db8093cc..fecb5fe03f 100644 --- a/patches/api/0273-More-World-API.patch +++ b/patches/api/0272-More-World-API.patch @@ -5,10 +5,10 @@ Subject: [PATCH] More World API diff --git a/src/main/java/org/bukkit/World.java b/src/main/java/org/bukkit/World.java -index eb07c907e7dd62498cde6edc28a0a350578842c1..879b2c1a4019b24625e97715fc2f3c2137981424 100644 +index 711fc41dbd029fa2d43f35165b62d09de89509b7..ff1330d091a3bbab99f3ad813e1322c806f4ea32 100644 --- a/src/main/java/org/bukkit/World.java +++ b/src/main/java/org/bukkit/World.java -@@ -3742,6 +3742,114 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient +@@ -3697,6 +3697,114 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient @Nullable StructureSearchResult locateNearestStructure(@NotNull Location origin, @NotNull Structure structure, int radius, boolean findUnexplored); diff --git a/patches/api/0274-Added-PlayerBedFailEnterEvent.patch b/patches/api/0273-Added-PlayerBedFailEnterEvent.patch similarity index 100% rename from patches/api/0274-Added-PlayerBedFailEnterEvent.patch rename to patches/api/0273-Added-PlayerBedFailEnterEvent.patch diff --git a/patches/api/0275-Introduce-beacon-activation-deactivation-events.patch b/patches/api/0274-Introduce-beacon-activation-deactivation-events.patch similarity index 100% rename from patches/api/0275-Introduce-beacon-activation-deactivation-events.patch rename to patches/api/0274-Introduce-beacon-activation-deactivation-events.patch diff --git a/patches/api/0276-PlayerMoveEvent-Improvements.patch b/patches/api/0275-PlayerMoveEvent-Improvements.patch similarity index 100% rename from patches/api/0276-PlayerMoveEvent-Improvements.patch rename to patches/api/0275-PlayerMoveEvent-Improvements.patch diff --git a/patches/api/0277-add-RespawnFlags-to-PlayerRespawnEvent.patch b/patches/api/0276-add-RespawnFlags-to-PlayerRespawnEvent.patch similarity index 100% rename from patches/api/0277-add-RespawnFlags-to-PlayerRespawnEvent.patch rename to patches/api/0276-add-RespawnFlags-to-PlayerRespawnEvent.patch diff --git a/patches/api/0278-Add-more-WanderingTrader-API.patch b/patches/api/0277-Add-more-WanderingTrader-API.patch similarity index 100% rename from patches/api/0278-Add-more-WanderingTrader-API.patch rename to patches/api/0277-Add-more-WanderingTrader-API.patch diff --git a/patches/api/0279-Add-EntityBlockStorage-clearEntities.patch b/patches/api/0278-Add-EntityBlockStorage-clearEntities.patch similarity index 100% rename from patches/api/0279-Add-EntityBlockStorage-clearEntities.patch rename to patches/api/0278-Add-EntityBlockStorage-clearEntities.patch diff --git a/patches/api/0280-Add-Adventure-message-to-PlayerAdvancementDoneEvent.patch b/patches/api/0279-Add-Adventure-message-to-PlayerAdvancementDoneEvent.patch similarity index 100% rename from patches/api/0280-Add-Adventure-message-to-PlayerAdvancementDoneEvent.patch rename to patches/api/0279-Add-Adventure-message-to-PlayerAdvancementDoneEvent.patch diff --git a/patches/api/0281-Add-raw-address-to-AsyncPlayerPreLoginEvent.patch b/patches/api/0280-Add-raw-address-to-AsyncPlayerPreLoginEvent.patch similarity index 100% rename from patches/api/0281-Add-raw-address-to-AsyncPlayerPreLoginEvent.patch rename to patches/api/0280-Add-raw-address-to-AsyncPlayerPreLoginEvent.patch diff --git a/patches/api/0282-Inventory-close.patch b/patches/api/0281-Inventory-close.patch similarity index 100% rename from patches/api/0282-Inventory-close.patch rename to patches/api/0281-Inventory-close.patch diff --git a/patches/api/0283-Add-a-should-burn-in-sunlight-API-for-Phantoms-and-S.patch b/patches/api/0282-Add-a-should-burn-in-sunlight-API-for-Phantoms-and-S.patch similarity index 100% rename from patches/api/0283-Add-a-should-burn-in-sunlight-API-for-Phantoms-and-S.patch rename to patches/api/0282-Add-a-should-burn-in-sunlight-API-for-Phantoms-and-S.patch diff --git a/patches/api/0284-Add-basic-Datapack-API.patch b/patches/api/0283-Add-basic-Datapack-API.patch similarity index 100% rename from patches/api/0284-Add-basic-Datapack-API.patch rename to patches/api/0283-Add-basic-Datapack-API.patch diff --git a/patches/api/0285-additions-to-PlayerGameModeChangeEvent.patch b/patches/api/0284-additions-to-PlayerGameModeChangeEvent.patch similarity index 100% rename from patches/api/0285-additions-to-PlayerGameModeChangeEvent.patch rename to patches/api/0284-additions-to-PlayerGameModeChangeEvent.patch diff --git a/patches/api/0286-ItemStack-repair-check-API.patch b/patches/api/0285-ItemStack-repair-check-API.patch similarity index 100% rename from patches/api/0286-ItemStack-repair-check-API.patch rename to patches/api/0285-ItemStack-repair-check-API.patch diff --git a/patches/api/0287-More-Enchantment-API.patch b/patches/api/0286-More-Enchantment-API.patch similarity index 100% rename from patches/api/0287-More-Enchantment-API.patch rename to patches/api/0286-More-Enchantment-API.patch diff --git a/patches/api/0288-Add-Mob-lookAt-API.patch b/patches/api/0287-Add-Mob-lookAt-API.patch similarity index 100% rename from patches/api/0288-Add-Mob-lookAt-API.patch rename to patches/api/0287-Add-Mob-lookAt-API.patch diff --git a/patches/api/0289-ItemStack-editMeta.patch b/patches/api/0288-ItemStack-editMeta.patch similarity index 100% rename from patches/api/0289-ItemStack-editMeta.patch rename to patches/api/0288-ItemStack-editMeta.patch diff --git a/patches/api/0290-Add-EntityInsideBlockEvent.patch b/patches/api/0289-Add-EntityInsideBlockEvent.patch similarity index 100% rename from patches/api/0290-Add-EntityInsideBlockEvent.patch rename to patches/api/0289-Add-EntityInsideBlockEvent.patch diff --git a/patches/api/0291-Attributes-API-for-item-defaults.patch b/patches/api/0290-Attributes-API-for-item-defaults.patch similarity index 100% rename from patches/api/0291-Attributes-API-for-item-defaults.patch rename to patches/api/0290-Attributes-API-for-item-defaults.patch diff --git a/patches/api/0292-Add-cause-to-Weather-ThunderChangeEvents.patch b/patches/api/0291-Add-cause-to-Weather-ThunderChangeEvents.patch similarity index 100% rename from patches/api/0292-Add-cause-to-Weather-ThunderChangeEvents.patch rename to patches/api/0291-Add-cause-to-Weather-ThunderChangeEvents.patch diff --git a/patches/api/0293-More-Lidded-Block-API.patch b/patches/api/0292-More-Lidded-Block-API.patch similarity index 100% rename from patches/api/0293-More-Lidded-Block-API.patch rename to patches/api/0292-More-Lidded-Block-API.patch diff --git a/patches/api/0294-Add-PlayerKickEvent-causes.patch b/patches/api/0293-Add-PlayerKickEvent-causes.patch similarity index 96% rename from patches/api/0294-Add-PlayerKickEvent-causes.patch rename to patches/api/0293-Add-PlayerKickEvent-causes.patch index 672477fc51..b492050019 100644 --- a/patches/api/0294-Add-PlayerKickEvent-causes.patch +++ b/patches/api/0293-Add-PlayerKickEvent-causes.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Add PlayerKickEvent causes diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java -index 87a0b438aa5af2193eab43ac18616b9340479ae7..bf7cc49f81c00f8fda672f22c00e9adeac87733e 100644 +index 842d26eb83836e1d11a5a6b0dbe5f1666bc3b7d7..8a87c128bb562ad46df4d02d53c72cce3b10db43 100644 --- a/src/main/java/org/bukkit/entity/Player.java +++ b/src/main/java/org/bukkit/entity/Player.java -@@ -250,6 +250,14 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -251,6 +251,14 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM * @param message kick message */ void kick(final net.kyori.adventure.text.@Nullable Component message); diff --git a/patches/api/0295-Add-PufferFishStateChangeEvent.patch b/patches/api/0294-Add-PufferFishStateChangeEvent.patch similarity index 100% rename from patches/api/0295-Add-PufferFishStateChangeEvent.patch rename to patches/api/0294-Add-PufferFishStateChangeEvent.patch diff --git a/patches/api/0296-Add-BellRevealRaiderEvent.patch b/patches/api/0295-Add-BellRevealRaiderEvent.patch similarity index 100% rename from patches/api/0296-Add-BellRevealRaiderEvent.patch rename to patches/api/0295-Add-BellRevealRaiderEvent.patch diff --git a/patches/api/0297-Add-ElderGuardianAppearanceEvent.patch b/patches/api/0296-Add-ElderGuardianAppearanceEvent.patch similarity index 100% rename from patches/api/0297-Add-ElderGuardianAppearanceEvent.patch rename to patches/api/0296-Add-ElderGuardianAppearanceEvent.patch diff --git a/patches/api/0298-Add-more-line-of-sight-methods.patch b/patches/api/0297-Add-more-line-of-sight-methods.patch similarity index 92% rename from patches/api/0298-Add-more-line-of-sight-methods.patch rename to patches/api/0297-Add-more-line-of-sight-methods.patch index 66f4c9a514..f8182b74f7 100644 --- a/patches/api/0298-Add-more-line-of-sight-methods.patch +++ b/patches/api/0297-Add-more-line-of-sight-methods.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Add more line of sight methods diff --git a/src/main/java/org/bukkit/RegionAccessor.java b/src/main/java/org/bukkit/RegionAccessor.java -index f30fff08bf04c4d274b2ce242a135a14924f1cb0..3c38abfbe0391bf748702b1599d359a1180838af 100644 +index 71ef9b479888aa83455757560b60745572c7196d..cd83348de3f82b3fddcf2d4bb9187ec8173b0e40 100644 --- a/src/main/java/org/bukkit/RegionAccessor.java +++ b/src/main/java/org/bukkit/RegionAccessor.java -@@ -392,5 +392,13 @@ public interface RegionAccessor extends Keyed { // Paper +@@ -437,5 +437,13 @@ public interface RegionAccessor extends Keyed { // Paper @NotNull @Override NamespacedKey getKey(); diff --git a/patches/api/0299-Add-WaterBottleSplashEvent.patch b/patches/api/0298-Add-WaterBottleSplashEvent.patch similarity index 100% rename from patches/api/0299-Add-WaterBottleSplashEvent.patch rename to patches/api/0298-Add-WaterBottleSplashEvent.patch diff --git a/patches/api/0300-Add-more-LimitedRegion-API.patch b/patches/api/0299-Add-more-LimitedRegion-API.patch similarity index 100% rename from patches/api/0300-Add-more-LimitedRegion-API.patch rename to patches/api/0299-Add-more-LimitedRegion-API.patch diff --git a/patches/api/0301-Missing-Entity-Behavior-API.patch b/patches/api/0300-Missing-Entity-Behavior-API.patch similarity index 99% rename from patches/api/0301-Missing-Entity-Behavior-API.patch rename to patches/api/0300-Missing-Entity-Behavior-API.patch index 9d575bf700..e16a4990e6 100644 --- a/patches/api/0301-Missing-Entity-Behavior-API.patch +++ b/patches/api/0300-Missing-Entity-Behavior-API.patch @@ -1110,10 +1110,10 @@ index 3794db8867b53f3b3735ad82fdd8765a26df2bfb..efaa45f41bc1dc8df6665c55b4e5ade3 * Increases the anger level of this warden. * diff --git a/src/main/java/org/bukkit/entity/Wither.java b/src/main/java/org/bukkit/entity/Wither.java -index b86f0196e6eb8070830f63a94f732522c2a6c2f1..a1b42ae35dda2da90ba00a2d6666514f7c5b11dd 100644 +index 87a814f63c3f35be35bfa210c9248ad211c0dd8f..bc6161989876e615085ab54715f35451a2f942bb 100644 --- a/src/main/java/org/bukkit/entity/Wither.java +++ b/src/main/java/org/bukkit/entity/Wither.java -@@ -48,4 +48,35 @@ public interface Wither extends Monster, Boss, com.destroystokyo.paper.entity.Ra +@@ -64,4 +64,35 @@ public interface Wither extends Monster, Boss, com.destroystokyo.paper.entity.Ra LEFT, RIGHT } diff --git a/patches/api/0302-Adds-PlayerArmSwingEvent.patch b/patches/api/0301-Adds-PlayerArmSwingEvent.patch similarity index 100% rename from patches/api/0302-Adds-PlayerArmSwingEvent.patch rename to patches/api/0301-Adds-PlayerArmSwingEvent.patch diff --git a/patches/api/0303-Add-PlayerSignCommandPreprocessEvent.patch b/patches/api/0302-Add-PlayerSignCommandPreprocessEvent.patch similarity index 100% rename from patches/api/0303-Add-PlayerSignCommandPreprocessEvent.patch rename to patches/api/0302-Add-PlayerSignCommandPreprocessEvent.patch diff --git a/patches/api/0304-fix-empty-array-elements-in-command-arguments.patch b/patches/api/0303-fix-empty-array-elements-in-command-arguments.patch similarity index 100% rename from patches/api/0304-fix-empty-array-elements-in-command-arguments.patch rename to patches/api/0303-fix-empty-array-elements-in-command-arguments.patch diff --git a/patches/api/0305-Stinger-API.patch b/patches/api/0304-Stinger-API.patch similarity index 100% rename from patches/api/0305-Stinger-API.patch rename to patches/api/0304-Stinger-API.patch diff --git a/patches/api/0306-Rewrite-LogEvents-to-contain-the-source-jars-in-stac.patch b/patches/api/0305-Rewrite-LogEvents-to-contain-the-source-jars-in-stac.patch similarity index 93% rename from patches/api/0306-Rewrite-LogEvents-to-contain-the-source-jars-in-stac.patch rename to patches/api/0305-Rewrite-LogEvents-to-contain-the-source-jars-in-stac.patch index 639c8a6a2f..5ae9132b78 100644 --- a/patches/api/0306-Rewrite-LogEvents-to-contain-the-source-jars-in-stac.patch +++ b/patches/api/0305-Rewrite-LogEvents-to-contain-the-source-jars-in-stac.patch @@ -5,7 +5,7 @@ Subject: [PATCH] Rewrite LogEvents to contain the source jars in stack traces diff --git a/src/main/java/org/bukkit/plugin/java/PluginClassLoader.java b/src/main/java/org/bukkit/plugin/java/PluginClassLoader.java -index 576df38b745c0ef0ed927e960f3f8baaff784593..efcfef28b26622454a26b99cd52e0bafb69f6549 100644 +index a8ac1fb22a6fba50d69bf726b49c49ba190ab79a..b4732c8dd12134a094ef9afc1870077412ce0435 100644 --- a/src/main/java/org/bukkit/plugin/java/PluginClassLoader.java +++ b/src/main/java/org/bukkit/plugin/java/PluginClassLoader.java @@ -54,7 +54,7 @@ public final class PluginClassLoader extends URLClassLoader implements io.paperm diff --git a/patches/api/0307-Add-PlayerSetSpawnEvent.patch b/patches/api/0306-Add-PlayerSetSpawnEvent.patch similarity index 86% rename from patches/api/0307-Add-PlayerSetSpawnEvent.patch rename to patches/api/0306-Add-PlayerSetSpawnEvent.patch index 74772fd9d8..9229c768c6 100644 --- a/patches/api/0307-Add-PlayerSetSpawnEvent.patch +++ b/patches/api/0306-Add-PlayerSetSpawnEvent.patch @@ -185,3 +185,18 @@ index 0000000000000000000000000000000000000000..c615dbe6ca1289bb090b8e28e98b9ad7 + UNKNOWN, + } +} +diff --git a/src/main/java/org/bukkit/event/player/PlayerSpawnChangeEvent.java b/src/main/java/org/bukkit/event/player/PlayerSpawnChangeEvent.java +index c2884bc20f0040b15dc035f4761d021e7343960d..3ea03540ce2882bbb482d9bd69a015a7fc040bfd 100644 +--- a/src/main/java/org/bukkit/event/player/PlayerSpawnChangeEvent.java ++++ b/src/main/java/org/bukkit/event/player/PlayerSpawnChangeEvent.java +@@ -12,8 +12,10 @@ import org.jetbrains.annotations.Nullable; + /** + * This event is fired when the spawn point of the player is changed. + * @apiNote draft API ++ * @deprecated use {@link com.destroystokyo.paper.event.player.PlayerSetSpawnEvent} + */ + @ApiStatus.Experimental ++@Deprecated(forRemoval = true) // Paper + public class PlayerSpawnChangeEvent extends PlayerEvent implements Cancellable { + + private static final HandlerList handlers = new HandlerList(); diff --git a/patches/api/0308-Added-EntityDamageItemEvent.patch b/patches/api/0307-Added-EntityDamageItemEvent.patch similarity index 100% rename from patches/api/0308-Added-EntityDamageItemEvent.patch rename to patches/api/0307-Added-EntityDamageItemEvent.patch diff --git a/patches/api/0309-Make-EntityUnleashEvent-cancellable.patch b/patches/api/0308-Make-EntityUnleashEvent-cancellable.patch similarity index 100% rename from patches/api/0309-Make-EntityUnleashEvent-cancellable.patch rename to patches/api/0308-Make-EntityUnleashEvent-cancellable.patch diff --git a/patches/api/0310-Change-EnderEye-target-without-changing-other-things.patch b/patches/api/0309-Change-EnderEye-target-without-changing-other-things.patch similarity index 100% rename from patches/api/0310-Change-EnderEye-target-without-changing-other-things.patch rename to patches/api/0309-Change-EnderEye-target-without-changing-other-things.patch diff --git a/patches/api/0311-Add-BlockBreakBlockEvent.patch b/patches/api/0310-Add-BlockBreakBlockEvent.patch similarity index 100% rename from patches/api/0311-Add-BlockBreakBlockEvent.patch rename to patches/api/0310-Add-BlockBreakBlockEvent.patch diff --git a/patches/api/0312-Add-helpers-for-left-right-click-to-Action.patch b/patches/api/0311-Add-helpers-for-left-right-click-to-Action.patch similarity index 100% rename from patches/api/0312-Add-helpers-for-left-right-click-to-Action.patch rename to patches/api/0311-Add-helpers-for-left-right-click-to-Action.patch diff --git a/patches/api/0313-Option-to-prevent-NBT-copy-in-smithing-recipes.patch b/patches/api/0312-Option-to-prevent-NBT-copy-in-smithing-recipes.patch similarity index 100% rename from patches/api/0313-Option-to-prevent-NBT-copy-in-smithing-recipes.patch rename to patches/api/0312-Option-to-prevent-NBT-copy-in-smithing-recipes.patch diff --git a/patches/api/0314-More-CommandBlock-API.patch b/patches/api/0313-More-CommandBlock-API.patch similarity index 100% rename from patches/api/0314-More-CommandBlock-API.patch rename to patches/api/0313-More-CommandBlock-API.patch diff --git a/patches/api/0315-Add-missing-team-sidebar-display-slots.patch b/patches/api/0314-Add-missing-team-sidebar-display-slots.patch similarity index 100% rename from patches/api/0315-Add-missing-team-sidebar-display-slots.patch rename to patches/api/0314-Add-missing-team-sidebar-display-slots.patch diff --git a/patches/api/0316-add-back-EntityPortalExitEvent.patch b/patches/api/0315-add-back-EntityPortalExitEvent.patch similarity index 100% rename from patches/api/0316-add-back-EntityPortalExitEvent.patch rename to patches/api/0315-add-back-EntityPortalExitEvent.patch diff --git a/patches/api/0317-Add-methods-to-find-targets-for-lightning-strikes.patch b/patches/api/0316-Add-methods-to-find-targets-for-lightning-strikes.patch similarity index 92% rename from patches/api/0317-Add-methods-to-find-targets-for-lightning-strikes.patch rename to patches/api/0316-Add-methods-to-find-targets-for-lightning-strikes.patch index dbbe085c01..7341643e76 100644 --- a/patches/api/0317-Add-methods-to-find-targets-for-lightning-strikes.patch +++ b/patches/api/0316-Add-methods-to-find-targets-for-lightning-strikes.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Add methods to find targets for lightning strikes diff --git a/src/main/java/org/bukkit/World.java b/src/main/java/org/bukkit/World.java -index 04c9329bb0309a1d3b0a1bbc755af7190a6ad0d4..792817079f03d082141660ab2a51c9bf56144f60 100644 +index ff1330d091a3bbab99f3ad813e1322c806f4ea32..e088ffbf5c137754864e21d1f570793eb4e23f6a 100644 --- a/src/main/java/org/bukkit/World.java +++ b/src/main/java/org/bukkit/World.java -@@ -760,6 +760,37 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient +@@ -715,6 +715,37 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient @NotNull public LightningStrike strikeLightningEffect(@NotNull Location loc); diff --git a/patches/api/0318-Get-entity-default-attributes.patch b/patches/api/0317-Get-entity-default-attributes.patch similarity index 100% rename from patches/api/0318-Get-entity-default-attributes.patch rename to patches/api/0317-Get-entity-default-attributes.patch diff --git a/patches/api/0319-Left-handed-API.patch b/patches/api/0318-Left-handed-API.patch similarity index 100% rename from patches/api/0319-Left-handed-API.patch rename to patches/api/0318-Left-handed-API.patch diff --git a/patches/api/0320-Add-more-advancement-API.patch b/patches/api/0319-Add-more-advancement-API.patch similarity index 100% rename from patches/api/0320-Add-more-advancement-API.patch rename to patches/api/0319-Add-more-advancement-API.patch diff --git a/patches/api/0321-Add-ItemFactory-getSpawnEgg-API.patch b/patches/api/0320-Add-ItemFactory-getSpawnEgg-API.patch similarity index 90% rename from patches/api/0321-Add-ItemFactory-getSpawnEgg-API.patch rename to patches/api/0320-Add-ItemFactory-getSpawnEgg-API.patch index ec5399f216..bf76f634c7 100644 --- a/patches/api/0321-Add-ItemFactory-getSpawnEgg-API.patch +++ b/patches/api/0320-Add-ItemFactory-getSpawnEgg-API.patch @@ -5,7 +5,7 @@ Subject: [PATCH] Add ItemFactory#getSpawnEgg API diff --git a/src/main/java/org/bukkit/inventory/ItemFactory.java b/src/main/java/org/bukkit/inventory/ItemFactory.java -index fea728e9c4aaab792e6a6b4a71c1e9c34096d305..bed2278dbd35be9bdc82e7fcfaf077fdf040edd0 100644 +index 11e59068b8a8ef1128e3c75283d161c39e2a3a99..67d3105258fe4e8165a662dd65bc501b30fcff51 100644 --- a/src/main/java/org/bukkit/inventory/ItemFactory.java +++ b/src/main/java/org/bukkit/inventory/ItemFactory.java @@ -263,5 +263,14 @@ public interface ItemFactory { diff --git a/patches/api/0322-Add-critical-damage-API.patch b/patches/api/0321-Add-critical-damage-API.patch similarity index 100% rename from patches/api/0322-Add-critical-damage-API.patch rename to patches/api/0321-Add-critical-damage-API.patch diff --git a/patches/api/0323-Fix-issues-with-mob-conversion.patch b/patches/api/0322-Fix-issues-with-mob-conversion.patch similarity index 100% rename from patches/api/0323-Fix-issues-with-mob-conversion.patch rename to patches/api/0322-Fix-issues-with-mob-conversion.patch diff --git a/patches/api/0324-Add-isCollidable-methods-to-various-places.patch b/patches/api/0323-Add-isCollidable-methods-to-various-places.patch similarity index 97% rename from patches/api/0324-Add-isCollidable-methods-to-various-places.patch rename to patches/api/0323-Add-isCollidable-methods-to-various-places.patch index 9cc9912d6c..06bf0f76cf 100644 --- a/patches/api/0324-Add-isCollidable-methods-to-various-places.patch +++ b/patches/api/0323-Add-isCollidable-methods-to-various-places.patch @@ -45,7 +45,7 @@ index 29ccd90e2733b528ef0866f93053adf66dd9ddf3..2a23e93d9e308c5eba0a2b658f11f571 // Paper end } diff --git a/src/main/java/org/bukkit/block/Block.java b/src/main/java/org/bukkit/block/Block.java -index 96a3466181a6829e1868b5f5249349e8fd2cdd09..cda6e7d8e032b3edc919995141dc260b1ea82810 100644 +index 93b9b57c95a0d24e885a205cd9d9e05a5631806a..cb0dcbbfb77158c3b17bd7994a9bbcef8060941a 100644 --- a/src/main/java/org/bukkit/block/Block.java +++ b/src/main/java/org/bukkit/block/Block.java @@ -482,6 +482,13 @@ public interface Block extends Metadatable, Translatable, net.kyori.adventure.tr diff --git a/patches/api/0325-Goat-ram-API.patch b/patches/api/0324-Goat-ram-API.patch similarity index 100% rename from patches/api/0325-Goat-ram-API.patch rename to patches/api/0324-Goat-ram-API.patch diff --git a/patches/api/0326-Add-API-for-resetting-a-single-score.patch b/patches/api/0325-Add-API-for-resetting-a-single-score.patch similarity index 100% rename from patches/api/0326-Add-API-for-resetting-a-single-score.patch rename to patches/api/0325-Add-API-for-resetting-a-single-score.patch diff --git a/patches/api/0327-Add-Raw-Byte-Entity-Serialization.patch b/patches/api/0326-Add-Raw-Byte-Entity-Serialization.patch similarity index 100% rename from patches/api/0327-Add-Raw-Byte-Entity-Serialization.patch rename to patches/api/0326-Add-Raw-Byte-Entity-Serialization.patch diff --git a/patches/api/0328-Add-PlayerItemFrameChangeEvent.patch b/patches/api/0327-Add-PlayerItemFrameChangeEvent.patch similarity index 100% rename from patches/api/0328-Add-PlayerItemFrameChangeEvent.patch rename to patches/api/0327-Add-PlayerItemFrameChangeEvent.patch diff --git a/patches/api/0329-Add-player-health-update-API.patch b/patches/api/0328-Add-player-health-update-API.patch similarity index 91% rename from patches/api/0329-Add-player-health-update-API.patch rename to patches/api/0328-Add-player-health-update-API.patch index 67ce57c8b8..d8a83675be 100644 --- a/patches/api/0329-Add-player-health-update-API.patch +++ b/patches/api/0328-Add-player-health-update-API.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Add player health update API diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java -index bf7cc49f81c00f8fda672f22c00e9adeac87733e..371275d7844928fe4d5df0251972355169b8304f 100644 +index 8a87c128bb562ad46df4d02d53c72cce3b10db43..ba329be88c9da9c4d98eff4b3c6321e2ddab2dba 100644 --- a/src/main/java/org/bukkit/entity/Player.java +++ b/src/main/java/org/bukkit/entity/Player.java -@@ -2027,6 +2027,31 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -2049,6 +2049,31 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM */ public double getHealthScale(); diff --git a/patches/api/0330-Allow-delegation-to-vanilla-chunk-gen.patch b/patches/api/0329-Allow-delegation-to-vanilla-chunk-gen.patch similarity index 100% rename from patches/api/0330-Allow-delegation-to-vanilla-chunk-gen.patch rename to patches/api/0329-Allow-delegation-to-vanilla-chunk-gen.patch diff --git a/patches/api/0331-Add-more-Campfire-API.patch b/patches/api/0330-Add-more-Campfire-API.patch similarity index 100% rename from patches/api/0331-Add-more-Campfire-API.patch rename to patches/api/0330-Add-more-Campfire-API.patch diff --git a/patches/api/0332-Move-VehicleCollisionEvent-HandlerList-up.patch b/patches/api/0331-Move-VehicleCollisionEvent-HandlerList-up.patch similarity index 100% rename from patches/api/0332-Move-VehicleCollisionEvent-HandlerList-up.patch rename to patches/api/0331-Move-VehicleCollisionEvent-HandlerList-up.patch diff --git a/patches/api/0333-Improve-scoreboard-entries.patch b/patches/api/0332-Improve-scoreboard-entries.patch similarity index 100% rename from patches/api/0333-Improve-scoreboard-entries.patch rename to patches/api/0332-Improve-scoreboard-entries.patch diff --git a/patches/api/0334-Entity-powdered-snow-API.patch b/patches/api/0333-Entity-powdered-snow-API.patch similarity index 100% rename from patches/api/0334-Entity-powdered-snow-API.patch rename to patches/api/0333-Entity-powdered-snow-API.patch diff --git a/patches/api/0335-Add-API-for-item-entity-health.patch b/patches/api/0334-Add-API-for-item-entity-health.patch similarity index 100% rename from patches/api/0335-Add-API-for-item-entity-health.patch rename to patches/api/0334-Add-API-for-item-entity-health.patch diff --git a/patches/api/0336-Expose-isFuel-and-canSmelt-methods-to-FurnaceInvento.patch b/patches/api/0335-Expose-isFuel-and-canSmelt-methods-to-FurnaceInvento.patch similarity index 100% rename from patches/api/0336-Expose-isFuel-and-canSmelt-methods-to-FurnaceInvento.patch rename to patches/api/0335-Expose-isFuel-and-canSmelt-methods-to-FurnaceInvento.patch diff --git a/patches/api/0337-Bucketable-API.patch b/patches/api/0336-Bucketable-API.patch similarity index 100% rename from patches/api/0337-Bucketable-API.patch rename to patches/api/0336-Bucketable-API.patch diff --git a/patches/api/0338-System-prop-for-default-config-comment-parsing.patch b/patches/api/0337-System-prop-for-default-config-comment-parsing.patch similarity index 100% rename from patches/api/0338-System-prop-for-default-config-comment-parsing.patch rename to patches/api/0337-System-prop-for-default-config-comment-parsing.patch diff --git a/patches/api/0339-Expose-vanilla-BiomeProvider-from-WorldInfo.patch b/patches/api/0338-Expose-vanilla-BiomeProvider-from-WorldInfo.patch similarity index 100% rename from patches/api/0339-Expose-vanilla-BiomeProvider-from-WorldInfo.patch rename to patches/api/0338-Expose-vanilla-BiomeProvider-from-WorldInfo.patch diff --git a/patches/api/0340-Add-new-overload-to-PersistentDataContainer-has.patch b/patches/api/0339-Add-new-overload-to-PersistentDataContainer-has.patch similarity index 100% rename from patches/api/0340-Add-new-overload-to-PersistentDataContainer-has.patch rename to patches/api/0339-Add-new-overload-to-PersistentDataContainer-has.patch diff --git a/patches/api/0341-Multiple-Entries-with-Scoreboards.patch b/patches/api/0340-Multiple-Entries-with-Scoreboards.patch similarity index 100% rename from patches/api/0341-Multiple-Entries-with-Scoreboards.patch rename to patches/api/0340-Multiple-Entries-with-Scoreboards.patch diff --git a/patches/api/0342-Added-getHostname-to-AsyncPlayerPreLoginEvent.patch b/patches/api/0341-Added-getHostname-to-AsyncPlayerPreLoginEvent.patch similarity index 100% rename from patches/api/0342-Added-getHostname-to-AsyncPlayerPreLoginEvent.patch rename to patches/api/0341-Added-getHostname-to-AsyncPlayerPreLoginEvent.patch diff --git a/patches/api/0343-Warn-on-strange-EventHandler-return-types.patch b/patches/api/0342-Warn-on-strange-EventHandler-return-types.patch similarity index 100% rename from patches/api/0343-Warn-on-strange-EventHandler-return-types.patch rename to patches/api/0342-Warn-on-strange-EventHandler-return-types.patch diff --git a/patches/api/0344-Multi-Block-Change-API.patch b/patches/api/0343-Multi-Block-Change-API.patch similarity index 91% rename from patches/api/0344-Multi-Block-Change-API.patch rename to patches/api/0343-Multi-Block-Change-API.patch index 946ce7cdc6..1253897748 100644 --- a/patches/api/0344-Multi-Block-Change-API.patch +++ b/patches/api/0343-Multi-Block-Change-API.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Multi Block Change API diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java -index 371275d7844928fe4d5df0251972355169b8304f..2e1bd95fdce4571cb9d288e4dea495126834ee31 100644 +index ba329be88c9da9c4d98eff4b3c6321e2ddab2dba..8997a2f854bdcbf40e74a10376de6dfc1acef697 100644 --- a/src/main/java/org/bukkit/entity/Player.java +++ b/src/main/java/org/bukkit/entity/Player.java -@@ -647,6 +647,27 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -648,6 +648,27 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM */ public void sendBlockDamage(@NotNull Location loc, float progress); diff --git a/patches/api/0345-Fix-NotePlayEvent.patch b/patches/api/0344-Fix-NotePlayEvent.patch similarity index 100% rename from patches/api/0345-Fix-NotePlayEvent.patch rename to patches/api/0344-Fix-NotePlayEvent.patch diff --git a/patches/api/0346-Freeze-Tick-Lock-API.patch b/patches/api/0345-Freeze-Tick-Lock-API.patch similarity index 100% rename from patches/api/0346-Freeze-Tick-Lock-API.patch rename to patches/api/0345-Freeze-Tick-Lock-API.patch diff --git a/patches/api/0347-Dolphin-API.patch b/patches/api/0346-Dolphin-API.patch similarity index 100% rename from patches/api/0347-Dolphin-API.patch rename to patches/api/0346-Dolphin-API.patch diff --git a/patches/api/0348-More-PotionEffectType-API.patch b/patches/api/0347-More-PotionEffectType-API.patch similarity index 100% rename from patches/api/0348-More-PotionEffectType-API.patch rename to patches/api/0347-More-PotionEffectType-API.patch diff --git a/patches/api/0349-API-for-creating-command-sender-which-forwards-feedb.patch b/patches/api/0348-API-for-creating-command-sender-which-forwards-feedb.patch similarity index 100% rename from patches/api/0349-API-for-creating-command-sender-which-forwards-feedb.patch rename to patches/api/0348-API-for-creating-command-sender-which-forwards-feedb.patch diff --git a/patches/api/0350-Implement-regenerateChunk.patch b/patches/api/0349-Implement-regenerateChunk.patch similarity index 85% rename from patches/api/0350-Implement-regenerateChunk.patch rename to patches/api/0349-Implement-regenerateChunk.patch index f2d5bc08fb..5d54590e1a 100644 --- a/patches/api/0350-Implement-regenerateChunk.patch +++ b/patches/api/0349-Implement-regenerateChunk.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Implement regenerateChunk diff --git a/src/main/java/org/bukkit/World.java b/src/main/java/org/bukkit/World.java -index 792817079f03d082141660ab2a51c9bf56144f60..6716a1185e733f3ddf56b295f3153938f57d4229 100644 +index e088ffbf5c137754864e21d1f570793eb4e23f6a..2b45aa9b438d7856ec448c56832b2b2100961565 100644 --- a/src/main/java/org/bukkit/World.java +++ b/src/main/java/org/bukkit/World.java -@@ -509,8 +509,8 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient +@@ -464,8 +464,8 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient * @return Whether the chunk was actually regenerated * * @deprecated regenerating a single chunk is not likely to produce the same diff --git a/patches/api/0351-Add-GameEvent-tags.patch b/patches/api/0350-Add-GameEvent-tags.patch similarity index 100% rename from patches/api/0351-Add-GameEvent-tags.patch rename to patches/api/0350-Add-GameEvent-tags.patch diff --git a/patches/api/0352-Furnace-RecipesUsed-API.patch b/patches/api/0351-Furnace-RecipesUsed-API.patch similarity index 100% rename from patches/api/0352-Furnace-RecipesUsed-API.patch rename to patches/api/0351-Furnace-RecipesUsed-API.patch diff --git a/patches/api/0353-Configurable-sculk-sensor-listener-range.patch b/patches/api/0352-Configurable-sculk-sensor-listener-range.patch similarity index 100% rename from patches/api/0353-Configurable-sculk-sensor-listener-range.patch rename to patches/api/0352-Configurable-sculk-sensor-listener-range.patch diff --git a/patches/api/0354-Add-missing-block-data-mins-and-maxes.patch b/patches/api/0353-Add-missing-block-data-mins-and-maxes.patch similarity index 100% rename from patches/api/0354-Add-missing-block-data-mins-and-maxes.patch rename to patches/api/0353-Add-missing-block-data-mins-and-maxes.patch diff --git a/patches/api/0355-Custom-Potion-Mixes.patch b/patches/api/0354-Custom-Potion-Mixes.patch similarity index 100% rename from patches/api/0355-Custom-Potion-Mixes.patch rename to patches/api/0354-Custom-Potion-Mixes.patch diff --git a/patches/api/0356-Expose-furnace-minecart-push-values.patch b/patches/api/0355-Expose-furnace-minecart-push-values.patch similarity index 100% rename from patches/api/0356-Expose-furnace-minecart-push-values.patch rename to patches/api/0355-Expose-furnace-minecart-push-values.patch diff --git a/patches/api/0357-More-Projectile-API.patch b/patches/api/0356-More-Projectile-API.patch similarity index 98% rename from patches/api/0357-More-Projectile-API.patch rename to patches/api/0356-More-Projectile-API.patch index 74619e0a48..29bfd02f72 100644 --- a/patches/api/0357-More-Projectile-API.patch +++ b/patches/api/0356-More-Projectile-API.patch @@ -153,10 +153,10 @@ index 0d31aa0b22cf1e849572294e2cfe38b48c9210af..217d348ad0bbef720b25d3b507a55ca8 + // Paper end } diff --git a/src/main/java/org/bukkit/entity/FishHook.java b/src/main/java/org/bukkit/entity/FishHook.java -index d1b37530319f6d37ee37f62080289c1e45848bc8..e94c7e279356c510f60508b26277d4891a4258fa 100644 +index 94e1a30ea1bc26821065a6d89c1f5669bd1d08ae..6ed83d3e4d23e0dc0e1b156a1ee221aaba5c7210 100644 --- a/src/main/java/org/bukkit/entity/FishHook.java +++ b/src/main/java/org/bukkit/entity/FishHook.java -@@ -162,4 +162,20 @@ public interface FishHook extends Projectile { +@@ -322,4 +322,20 @@ public interface FishHook extends Projectile { */ BOBBING; } diff --git a/patches/api/0358-Add-getComputedBiome-API.patch b/patches/api/0357-Add-getComputedBiome-API.patch similarity index 96% rename from patches/api/0358-Add-getComputedBiome-API.patch rename to patches/api/0357-Add-getComputedBiome-API.patch index f065c8e543..5de8fdeb0d 100644 --- a/patches/api/0358-Add-getComputedBiome-API.patch +++ b/patches/api/0357-Add-getComputedBiome-API.patch @@ -51,7 +51,7 @@ index 3c38abfbe0391bf748702b1599d359a1180838af..96291baf8bd06ff5f7fb2fccdbb2a172 * Sets the {@link Biome} at the given {@link Location}. * diff --git a/src/main/java/org/bukkit/block/Block.java b/src/main/java/org/bukkit/block/Block.java -index cda6e7d8e032b3edc919995141dc260b1ea82810..13485933b8b897b5a9b35f337b43eab5c968f13a 100644 +index cb0dcbbfb77158c3b17bd7994a9bbcef8060941a..921864e748407291b7fa153381e7d9701e1c4608 100644 --- a/src/main/java/org/bukkit/block/Block.java +++ b/src/main/java/org/bukkit/block/Block.java @@ -371,10 +371,22 @@ public interface Block extends Metadatable, Translatable, net.kyori.adventure.tr diff --git a/patches/api/0359-Add-enchantWithLevels-API.patch b/patches/api/0358-Add-enchantWithLevels-API.patch similarity index 97% rename from patches/api/0359-Add-enchantWithLevels-API.patch rename to patches/api/0358-Add-enchantWithLevels-API.patch index 175b43f65f..fe08c8a617 100644 --- a/patches/api/0359-Add-enchantWithLevels-API.patch +++ b/patches/api/0358-Add-enchantWithLevels-API.patch @@ -5,7 +5,7 @@ Subject: [PATCH] Add enchantWithLevels API diff --git a/src/main/java/org/bukkit/inventory/ItemFactory.java b/src/main/java/org/bukkit/inventory/ItemFactory.java -index bed2278dbd35be9bdc82e7fcfaf077fdf040edd0..c066d877b5eec3578439c2de1ab9568381ccf7c5 100644 +index 67d3105258fe4e8165a662dd65bc501b30fcff51..5a2e091785043e66c5560e870e3729fa70b28bb4 100644 --- a/src/main/java/org/bukkit/inventory/ItemFactory.java +++ b/src/main/java/org/bukkit/inventory/ItemFactory.java @@ -161,6 +161,22 @@ public interface ItemFactory { diff --git a/patches/api/0360-Add-TameableDeathMessageEvent.patch b/patches/api/0359-Add-TameableDeathMessageEvent.patch similarity index 100% rename from patches/api/0360-Add-TameableDeathMessageEvent.patch rename to patches/api/0359-Add-TameableDeathMessageEvent.patch diff --git a/patches/api/0361-Allow-to-change-the-podium-of-the-EnderDragon.patch b/patches/api/0360-Allow-to-change-the-podium-of-the-EnderDragon.patch similarity index 100% rename from patches/api/0361-Allow-to-change-the-podium-of-the-EnderDragon.patch rename to patches/api/0360-Allow-to-change-the-podium-of-the-EnderDragon.patch diff --git a/patches/api/0362-Add-pre-unbreaking-amount-to-PlayerItemDamageEvent.patch b/patches/api/0361-Add-pre-unbreaking-amount-to-PlayerItemDamageEvent.patch similarity index 100% rename from patches/api/0362-Add-pre-unbreaking-amount-to-PlayerItemDamageEvent.patch rename to patches/api/0361-Add-pre-unbreaking-amount-to-PlayerItemDamageEvent.patch diff --git a/patches/api/0363-WorldCreator-keepSpawnLoaded.patch b/patches/api/0362-WorldCreator-keepSpawnLoaded.patch similarity index 100% rename from patches/api/0363-WorldCreator-keepSpawnLoaded.patch rename to patches/api/0362-WorldCreator-keepSpawnLoaded.patch diff --git a/patches/api/0364-Add-EntityDyeEvent-and-CollarColorable-interface.patch b/patches/api/0363-Add-EntityDyeEvent-and-CollarColorable-interface.patch similarity index 100% rename from patches/api/0364-Add-EntityDyeEvent-and-CollarColorable-interface.patch rename to patches/api/0363-Add-EntityDyeEvent-and-CollarColorable-interface.patch diff --git a/patches/api/0365-Add-PlayerStopUsingItemEvent.patch b/patches/api/0364-Add-PlayerStopUsingItemEvent.patch similarity index 100% rename from patches/api/0365-Add-PlayerStopUsingItemEvent.patch rename to patches/api/0364-Add-PlayerStopUsingItemEvent.patch diff --git a/patches/api/0366-FallingBlock-auto-expire-setting.patch b/patches/api/0365-FallingBlock-auto-expire-setting.patch similarity index 100% rename from patches/api/0366-FallingBlock-auto-expire-setting.patch rename to patches/api/0365-FallingBlock-auto-expire-setting.patch diff --git a/patches/api/0367-Keyed-Cat-Type.patch b/patches/api/0366-Keyed-Cat-Type.patch similarity index 100% rename from patches/api/0367-Keyed-Cat-Type.patch rename to patches/api/0366-Keyed-Cat-Type.patch diff --git a/patches/api/0368-Add-method-isTickingWorlds-to-Bukkit.patch b/patches/api/0367-Add-method-isTickingWorlds-to-Bukkit.patch similarity index 100% rename from patches/api/0368-Add-method-isTickingWorlds-to-Bukkit.patch rename to patches/api/0367-Add-method-isTickingWorlds-to-Bukkit.patch diff --git a/patches/api/0369-Add-WardenAngerChangeEvent.patch b/patches/api/0368-Add-WardenAngerChangeEvent.patch similarity index 100% rename from patches/api/0369-Add-WardenAngerChangeEvent.patch rename to patches/api/0368-Add-WardenAngerChangeEvent.patch diff --git a/patches/api/0370-Nameable-Banner-API.patch b/patches/api/0369-Nameable-Banner-API.patch similarity index 100% rename from patches/api/0370-Nameable-Banner-API.patch rename to patches/api/0369-Nameable-Banner-API.patch diff --git a/patches/api/0371-Add-Player-getFishHook.patch b/patches/api/0370-Add-Player-getFishHook.patch similarity index 100% rename from patches/api/0371-Add-Player-getFishHook.patch rename to patches/api/0370-Add-Player-getFishHook.patch diff --git a/patches/api/0372-More-Teleport-API.patch b/patches/api/0371-More-Teleport-API.patch similarity index 98% rename from patches/api/0372-More-Teleport-API.patch rename to patches/api/0371-More-Teleport-API.patch index c05ddff252..9a087f3fae 100644 --- a/patches/api/0372-More-Teleport-API.patch +++ b/patches/api/0371-More-Teleport-API.patch @@ -165,10 +165,10 @@ index ab0ceaba9ddcbe20a8b8a1fc3ed19cb3c64ecd3d..97f0bc6573c8ba09de77061b6312b91c * Teleports this entity to the given location. If this entity is riding a * vehicle, it will be dismounted prior to teleportation. diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java -index 2e1bd95fdce4571cb9d288e4dea495126834ee31..84b79db95c433a469e972e6dfec8e2c5ee8ce9ce 100644 +index 8997a2f854bdcbf40e74a10376de6dfc1acef697..49aa859225d82c38e974aa6ed62ba92e702bf849 100644 --- a/src/main/java/org/bukkit/entity/Player.java +++ b/src/main/java/org/bukkit/entity/Player.java -@@ -2840,6 +2840,49 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -2862,6 +2862,49 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM String getClientBrandName(); // Paper end diff --git a/patches/api/0373-Add-EntityPortalReadyEvent.patch b/patches/api/0372-Add-EntityPortalReadyEvent.patch similarity index 100% rename from patches/api/0373-Add-EntityPortalReadyEvent.patch rename to patches/api/0372-Add-EntityPortalReadyEvent.patch diff --git a/patches/api/0374-Custom-Chat-Completion-Suggestions-API.patch b/patches/api/0373-Custom-Chat-Completion-Suggestions-API.patch similarity index 89% rename from patches/api/0374-Custom-Chat-Completion-Suggestions-API.patch rename to patches/api/0373-Custom-Chat-Completion-Suggestions-API.patch index 17dcf46943..5475478b82 100644 --- a/patches/api/0374-Custom-Chat-Completion-Suggestions-API.patch +++ b/patches/api/0373-Custom-Chat-Completion-Suggestions-API.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Custom Chat Completion Suggestions API diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java -index 51e427992bc673b733971c34bb9f0df7c26ba653..4d7680050849b5159f8485877228af5ef71defe5 100644 +index 49aa859225d82c38e974aa6ed62ba92e702bf849..f3fd12368a5a49ba9415cd871757b38e9211963c 100644 --- a/src/main/java/org/bukkit/entity/Player.java +++ b/src/main/java/org/bukkit/entity/Player.java -@@ -2704,6 +2704,25 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -2726,6 +2726,25 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM * @throws IllegalArgumentException If the level is negative or greater than {@code 4} (i.e. not within {@code [0, 4]}). */ void sendOpLevel(byte level); diff --git a/patches/api/0375-Collision-API.patch b/patches/api/0374-Collision-API.patch similarity index 93% rename from patches/api/0375-Collision-API.patch rename to patches/api/0374-Collision-API.patch index a0f945bda8..24bcebc503 100644 --- a/patches/api/0375-Collision-API.patch +++ b/patches/api/0374-Collision-API.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Collision API diff --git a/src/main/java/org/bukkit/RegionAccessor.java b/src/main/java/org/bukkit/RegionAccessor.java -index 96291baf8bd06ff5f7fb2fccdbb2a172f01ba8db..9ff8d5e104ca35bc7145cd845d96b3825e279277 100644 +index 8f50eb9b902236f5e039f5d26f3ca9a044b01a75..0d9184abd7090a5123a990f76847ee9b8971f735 100644 --- a/src/main/java/org/bukkit/RegionAccessor.java +++ b/src/main/java/org/bukkit/RegionAccessor.java -@@ -424,5 +424,15 @@ public interface RegionAccessor extends Keyed { // Paper +@@ -469,5 +469,15 @@ public interface RegionAccessor extends Keyed { // Paper * @return whether a line of sight exists between {@code from} and {@code to} */ public boolean lineOfSightExists(@NotNull Location from, @NotNull Location to); diff --git a/patches/api/0376-Block-Ticking-API.patch b/patches/api/0375-Block-Ticking-API.patch similarity index 90% rename from patches/api/0376-Block-Ticking-API.patch rename to patches/api/0375-Block-Ticking-API.patch index 2c34dc2453..20b123e5f9 100644 --- a/patches/api/0376-Block-Ticking-API.patch +++ b/patches/api/0375-Block-Ticking-API.patch @@ -5,7 +5,7 @@ Subject: [PATCH] Block Ticking API diff --git a/src/main/java/org/bukkit/block/Block.java b/src/main/java/org/bukkit/block/Block.java -index 13485933b8b897b5a9b35f337b43eab5c968f13a..390a2a2611df35a9ea6f1eb996b47e2aa4597ff0 100644 +index 921864e748407291b7fa153381e7d9701e1c4608..1c3f54382d66549dc881d4577c7104be6673a274 100644 --- a/src/main/java/org/bukkit/block/Block.java +++ b/src/main/java/org/bukkit/block/Block.java @@ -589,6 +589,21 @@ public interface Block extends Metadatable, Translatable, net.kyori.adventure.tr @@ -31,7 +31,7 @@ index 13485933b8b897b5a9b35f337b43eab5c968f13a..390a2a2611df35a9ea6f1eb996b47e2a /** diff --git a/src/main/java/org/bukkit/block/data/BlockData.java b/src/main/java/org/bukkit/block/data/BlockData.java -index 0d5ef61e100d972a5cf308b23d5e8f2fdbad5718..e65b7d1cf7b0655a3f31949f94f2f4a12e662c94 100644 +index dd4f394860ef8cabbd4174fe3088eec97aec73a5..40ddf8909636ab3cdd78f4e66123358c6a3850f7 100644 --- a/src/main/java/org/bukkit/block/data/BlockData.java +++ b/src/main/java/org/bukkit/block/data/BlockData.java @@ -235,4 +235,14 @@ public interface BlockData extends Cloneable { diff --git a/patches/api/0377-Add-NamespacedKey-biome-methods.patch b/patches/api/0376-Add-NamespacedKey-biome-methods.patch similarity index 100% rename from patches/api/0377-Add-NamespacedKey-biome-methods.patch rename to patches/api/0376-Add-NamespacedKey-biome-methods.patch diff --git a/patches/api/0378-Also-load-resources-from-LibraryLoader.patch b/patches/api/0377-Also-load-resources-from-LibraryLoader.patch similarity index 95% rename from patches/api/0378-Also-load-resources-from-LibraryLoader.patch rename to patches/api/0377-Also-load-resources-from-LibraryLoader.patch index 6e88f5bd00..ee5785d8cb 100644 --- a/patches/api/0378-Also-load-resources-from-LibraryLoader.patch +++ b/patches/api/0377-Also-load-resources-from-LibraryLoader.patch @@ -5,7 +5,7 @@ Subject: [PATCH] Also load resources from LibraryLoader diff --git a/src/main/java/org/bukkit/plugin/java/PluginClassLoader.java b/src/main/java/org/bukkit/plugin/java/PluginClassLoader.java -index efcfef28b26622454a26b99cd52e0bafb69f6549..1758e8a89c85eea8c2161ddcb5b0e745151a1f5e 100644 +index b4732c8dd12134a094ef9afc1870077412ce0435..13da387d3b59bc67c0d73e3fbd3a4034b1281527 100644 --- a/src/main/java/org/bukkit/plugin/java/PluginClassLoader.java +++ b/src/main/java/org/bukkit/plugin/java/PluginClassLoader.java @@ -95,14 +95,35 @@ public final class PluginClassLoader extends URLClassLoader implements io.paperm diff --git a/patches/api/0379-Added-byte-array-serialization-deserialization-for-P.patch b/patches/api/0378-Added-byte-array-serialization-deserialization-for-P.patch similarity index 100% rename from patches/api/0379-Added-byte-array-serialization-deserialization-for-P.patch rename to patches/api/0378-Added-byte-array-serialization-deserialization-for-P.patch diff --git a/patches/api/0380-Add-a-consumer-parameter-to-ProjectileSource-launchP.patch b/patches/api/0379-Add-a-consumer-parameter-to-ProjectileSource-launchP.patch similarity index 100% rename from patches/api/0380-Add-a-consumer-parameter-to-ProjectileSource-launchP.patch rename to patches/api/0379-Add-a-consumer-parameter-to-ProjectileSource-launchP.patch diff --git a/patches/api/0381-Expose-codepoint-limit-in-YamlConfigOptions-and-incr.patch b/patches/api/0380-Expose-codepoint-limit-in-YamlConfigOptions-and-incr.patch similarity index 96% rename from patches/api/0381-Expose-codepoint-limit-in-YamlConfigOptions-and-incr.patch rename to patches/api/0380-Expose-codepoint-limit-in-YamlConfigOptions-and-incr.patch index 52d54bf98e..9b5ef25cf4 100644 --- a/patches/api/0381-Expose-codepoint-limit-in-YamlConfigOptions-and-incr.patch +++ b/patches/api/0380-Expose-codepoint-limit-in-YamlConfigOptions-and-incr.patch @@ -6,7 +6,7 @@ Subject: [PATCH] Expose codepoint limit in YamlConfigOptions, and increase diff --git a/src/main/java/org/bukkit/configuration/file/YamlConfiguration.java b/src/main/java/org/bukkit/configuration/file/YamlConfiguration.java -index 4b17c796b187b5d3a6459c4470c0c1b6ba3815ff..0bd07ce5c119c2ed77273bfcb8422ce35138dc89 100644 +index a090ef390dddd546ebf323aee4545cbe9950e098..488e4931006d12700782c76766876e3863308775 100644 --- a/src/main/java/org/bukkit/configuration/file/YamlConfiguration.java +++ b/src/main/java/org/bukkit/configuration/file/YamlConfiguration.java @@ -97,6 +97,7 @@ public class YamlConfiguration extends FileConfiguration { diff --git a/patches/api/0382-Add-getDrops-to-BlockState.patch b/patches/api/0381-Add-getDrops-to-BlockState.patch similarity index 100% rename from patches/api/0382-Add-getDrops-to-BlockState.patch rename to patches/api/0381-Add-getDrops-to-BlockState.patch diff --git a/patches/api/0383-Add-PlayerInventorySlotChangeEvent.patch b/patches/api/0382-Add-PlayerInventorySlotChangeEvent.patch similarity index 100% rename from patches/api/0383-Add-PlayerInventorySlotChangeEvent.patch rename to patches/api/0382-Add-PlayerInventorySlotChangeEvent.patch diff --git a/patches/api/0384-Elder-Guardian-appearance-API.patch b/patches/api/0383-Elder-Guardian-appearance-API.patch similarity index 87% rename from patches/api/0384-Elder-Guardian-appearance-API.patch rename to patches/api/0383-Elder-Guardian-appearance-API.patch index 255c6f02c2..770323eb80 100644 --- a/patches/api/0384-Elder-Guardian-appearance-API.patch +++ b/patches/api/0383-Elder-Guardian-appearance-API.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Elder Guardian appearance API diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java -index 4d7680050849b5159f8485877228af5ef71defe5..6da82c3037e6568e5f447f30fa881b2d455e99c5 100644 +index f3fd12368a5a49ba9415cd871757b38e9211963c..f313073f745629e75787020d5bb444125f01c714 100644 --- a/src/main/java/org/bukkit/entity/Player.java +++ b/src/main/java/org/bukkit/entity/Player.java -@@ -2902,6 +2902,24 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -2924,6 +2924,24 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM void lookAt(@NotNull org.bukkit.entity.Entity entity, @NotNull io.papermc.paper.entity.LookAnchor playerAnchor, @NotNull io.papermc.paper.entity.LookAnchor entityAnchor); // Paper end - Teleport API diff --git a/patches/api/0385-Allow-changing-bed-s-occupied-property.patch b/patches/api/0384-Allow-changing-bed-s-occupied-property.patch similarity index 100% rename from patches/api/0385-Allow-changing-bed-s-occupied-property.patch rename to patches/api/0384-Allow-changing-bed-s-occupied-property.patch diff --git a/patches/api/0386-Add-EquipmentSlot-convenience-methods.patch b/patches/api/0385-Add-EquipmentSlot-convenience-methods.patch similarity index 100% rename from patches/api/0386-Add-EquipmentSlot-convenience-methods.patch rename to patches/api/0385-Add-EquipmentSlot-convenience-methods.patch diff --git a/patches/api/0387-Add-LivingEntity-swingHand-EquipmentSlot-convenience.patch b/patches/api/0386-Add-LivingEntity-swingHand-EquipmentSlot-convenience.patch similarity index 100% rename from patches/api/0387-Add-LivingEntity-swingHand-EquipmentSlot-convenience.patch rename to patches/api/0386-Add-LivingEntity-swingHand-EquipmentSlot-convenience.patch diff --git a/patches/api/0388-Add-entity-knockback-API.patch b/patches/api/0387-Add-entity-knockback-API.patch similarity index 100% rename from patches/api/0388-Add-entity-knockback-API.patch rename to patches/api/0387-Add-entity-knockback-API.patch diff --git a/patches/api/0389-Added-EntityToggleSitEvent.patch b/patches/api/0388-Added-EntityToggleSitEvent.patch similarity index 100% rename from patches/api/0389-Added-EntityToggleSitEvent.patch rename to patches/api/0388-Added-EntityToggleSitEvent.patch diff --git a/patches/api/0390-Add-Moving-Piston-API.patch b/patches/api/0389-Add-Moving-Piston-API.patch similarity index 100% rename from patches/api/0390-Add-Moving-Piston-API.patch rename to patches/api/0389-Add-Moving-Piston-API.patch diff --git a/patches/api/0391-Add-PrePlayerAttackEntityEvent.patch b/patches/api/0390-Add-PrePlayerAttackEntityEvent.patch similarity index 100% rename from patches/api/0391-Add-PrePlayerAttackEntityEvent.patch rename to patches/api/0390-Add-PrePlayerAttackEntityEvent.patch diff --git a/patches/api/0392-Add-Player-Warden-Warning-API.patch b/patches/api/0391-Add-Player-Warden-Warning-API.patch similarity index 93% rename from patches/api/0392-Add-Player-Warden-Warning-API.patch rename to patches/api/0391-Add-Player-Warden-Warning-API.patch index b23df9685c..eb029a28cc 100644 --- a/patches/api/0392-Add-Player-Warden-Warning-API.patch +++ b/patches/api/0391-Add-Player-Warden-Warning-API.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Add Player Warden Warning API diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java -index 6da82c3037e6568e5f447f30fa881b2d455e99c5..a824262598e4a1ad6030e22a77628c43975c031d 100644 +index f313073f745629e75787020d5bb444125f01c714..d02cc0194d492beb4d3e1c88dff7f6b2ea73554f 100644 --- a/src/main/java/org/bukkit/entity/Player.java +++ b/src/main/java/org/bukkit/entity/Player.java -@@ -2918,6 +2918,59 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -2940,6 +2940,59 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM * @param silent whether sound should be silenced */ void showElderGuardian(boolean silent); diff --git a/patches/api/0393-More-vanilla-friendly-methods-to-update-trades.patch b/patches/api/0392-More-vanilla-friendly-methods-to-update-trades.patch similarity index 100% rename from patches/api/0393-More-vanilla-friendly-methods-to-update-trades.patch rename to patches/api/0392-More-vanilla-friendly-methods-to-update-trades.patch diff --git a/patches/api/0394-Add-paper-dumplisteners-command.patch b/patches/api/0393-Add-paper-dumplisteners-command.patch similarity index 98% rename from patches/api/0394-Add-paper-dumplisteners-command.patch rename to patches/api/0393-Add-paper-dumplisteners-command.patch index 1cb3b7ce26..8053dc2c4f 100644 --- a/patches/api/0394-Add-paper-dumplisteners-command.patch +++ b/patches/api/0393-Add-paper-dumplisteners-command.patch @@ -118,7 +118,7 @@ index ed78cca71f83b296d082d0af147ca8d622c7606a..2292bd460ce2be113beb4ba6b4eb1935 for (EventPriority o : EventPriority.values()) { handlerslots.put(o, new ArrayList()); diff --git a/src/main/java/org/bukkit/plugin/EventExecutor.java b/src/main/java/org/bukkit/plugin/EventExecutor.java -index e1860322ae0f3c35097d16767628744034941749..bdfa3b5f4ab5023d3e1b5c50bed885b6aa118a02 100644 +index 5fa52419f21d8e8b3d8f9aafd248b05774a28348..60e086be70529e0804280b24a2a3e7ae72d8d363 100644 --- a/src/main/java/org/bukkit/plugin/EventExecutor.java +++ b/src/main/java/org/bukkit/plugin/EventExecutor.java @@ -70,9 +70,18 @@ public interface EventExecutor { diff --git a/patches/api/0395-ItemStack-damage-API.patch b/patches/api/0394-ItemStack-damage-API.patch similarity index 100% rename from patches/api/0395-ItemStack-damage-API.patch rename to patches/api/0394-ItemStack-damage-API.patch diff --git a/patches/api/0396-Add-Tick-TemporalUnit.patch b/patches/api/0395-Add-Tick-TemporalUnit.patch similarity index 100% rename from patches/api/0396-Add-Tick-TemporalUnit.patch rename to patches/api/0395-Add-Tick-TemporalUnit.patch diff --git a/patches/api/0397-Friction-API.patch b/patches/api/0396-Friction-API.patch similarity index 100% rename from patches/api/0397-Friction-API.patch rename to patches/api/0396-Friction-API.patch diff --git a/patches/api/0398-Player-Entity-Tracking-Events.patch b/patches/api/0397-Player-Entity-Tracking-Events.patch similarity index 100% rename from patches/api/0398-Player-Entity-Tracking-Events.patch rename to patches/api/0397-Player-Entity-Tracking-Events.patch diff --git a/patches/api/0399-Add-missing-Fluid-type.patch b/patches/api/0398-Add-missing-Fluid-type.patch similarity index 100% rename from patches/api/0399-Add-missing-Fluid-type.patch rename to patches/api/0398-Add-missing-Fluid-type.patch diff --git a/patches/api/0400-Actually-mark-mc-experimental-API-as-such.patch b/patches/api/0399-Actually-mark-mc-experimental-API-as-such.patch similarity index 100% rename from patches/api/0400-Actually-mark-mc-experimental-API-as-such.patch rename to patches/api/0399-Actually-mark-mc-experimental-API-as-such.patch diff --git a/patches/api/0401-fix-Instruments.patch b/patches/api/0400-fix-Instruments.patch similarity index 96% rename from patches/api/0401-fix-Instruments.patch rename to patches/api/0400-fix-Instruments.patch index 416020233d..bee24d14c3 100644 --- a/patches/api/0401-fix-Instruments.patch +++ b/patches/api/0400-fix-Instruments.patch @@ -110,10 +110,10 @@ index 8f70d86a1d39351424335842c38625d42cfbdfb8..271fb4d41909654b87519edba1c1d4f4 public static Instrument getByType(final byte type) { return BY_DATA.get(type); diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java -index a824262598e4a1ad6030e22a77628c43975c031d..eecb88dae2f68322be9add1fda7b50e2b2939f09 100644 +index d02cc0194d492beb4d3e1c88dff7f6b2ea73554f..5234c31b640c21e87215671f0235f6450994fcef 100644 --- a/src/main/java/org/bukkit/entity/Player.java +++ b/src/main/java/org/bukkit/entity/Player.java -@@ -391,9 +391,7 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -392,9 +392,7 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM public void playNote(@NotNull Location loc, byte instrument, byte note); /** diff --git a/patches/api/0402-Add-BlockLockCheckEvent.patch b/patches/api/0401-Add-BlockLockCheckEvent.patch similarity index 100% rename from patches/api/0402-Add-BlockLockCheckEvent.patch rename to patches/api/0401-Add-BlockLockCheckEvent.patch diff --git a/patches/api/0403-Add-Sneaking-API-for-Entities.patch b/patches/api/0402-Add-Sneaking-API-for-Entities.patch similarity index 88% rename from patches/api/0403-Add-Sneaking-API-for-Entities.patch rename to patches/api/0402-Add-Sneaking-API-for-Entities.patch index 80e58142af..739f3265e3 100644 --- a/patches/api/0403-Add-Sneaking-API-for-Entities.patch +++ b/patches/api/0402-Add-Sneaking-API-for-Entities.patch @@ -35,10 +35,10 @@ index 3f3ea5bb6b3ea6f55b5cd699f1c01ac159619add..a2a423d4e4c2702ba5967223cab0432d * Get the category of spawn to which this entity belongs. * diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java -index eecb88dae2f68322be9add1fda7b50e2b2939f09..8370de0cfea70d00cc484ca5d21dfade5af22984 100644 +index 5234c31b640c21e87215671f0235f6450994fcef..462987f2c119509b3bc1b9ff061e975b774ea5dd 100644 --- a/src/main/java/org/bukkit/entity/Player.java +++ b/src/main/java/org/bukkit/entity/Player.java -@@ -294,6 +294,7 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -295,6 +295,7 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM * * @return true if player is in sneak mode */ @@ -46,7 +46,7 @@ index eecb88dae2f68322be9add1fda7b50e2b2939f09..8370de0cfea70d00cc484ca5d21dfade public boolean isSneaking(); /** -@@ -301,6 +302,7 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -302,6 +303,7 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM * * @param sneak true if player should appear sneaking */ diff --git a/patches/api/0404-Improve-PortalEvents.patch b/patches/api/0403-Improve-PortalEvents.patch similarity index 100% rename from patches/api/0404-Improve-PortalEvents.patch rename to patches/api/0403-Improve-PortalEvents.patch diff --git a/patches/api/0405-Add-exploded-block-state-to-BlockExplodeEvent.patch b/patches/api/0404-Add-exploded-block-state-to-BlockExplodeEvent.patch similarity index 100% rename from patches/api/0405-Add-exploded-block-state-to-BlockExplodeEvent.patch rename to patches/api/0404-Add-exploded-block-state-to-BlockExplodeEvent.patch diff --git a/patches/api/0406-Flying-Fall-Damage-API.patch b/patches/api/0405-Flying-Fall-Damage-API.patch similarity index 88% rename from patches/api/0406-Flying-Fall-Damage-API.patch rename to patches/api/0405-Flying-Fall-Damage-API.patch index 660b23abd3..f2c1f0db9e 100644 --- a/patches/api/0406-Flying-Fall-Damage-API.patch +++ b/patches/api/0405-Flying-Fall-Damage-API.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Flying Fall Damage API diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java -index 8370de0cfea70d00cc484ca5d21dfade5af22984..a6399eb076b7889085ffa1afcd9d432afdc29f85 100644 +index 462987f2c119509b3bc1b9ff061e975b774ea5dd..3f6eb664988b1f2c9d85157e75f3d5f3d89831d7 100644 --- a/src/main/java/org/bukkit/entity/Player.java +++ b/src/main/java/org/bukkit/entity/Player.java -@@ -1486,6 +1486,23 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -1508,6 +1508,23 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM */ public void setAllowFlight(boolean flight); diff --git a/patches/api/0407-Expose-pre-collision-moving-velocity-to-VehicleBlock.patch b/patches/api/0406-Expose-pre-collision-moving-velocity-to-VehicleBlock.patch similarity index 100% rename from patches/api/0407-Expose-pre-collision-moving-velocity-to-VehicleBlock.patch rename to patches/api/0406-Expose-pre-collision-moving-velocity-to-VehicleBlock.patch diff --git a/patches/api/0408-Replace-ItemFlag.HIDE_POTION_EFFECTS.patch b/patches/api/0407-Replace-ItemFlag.HIDE_POTION_EFFECTS.patch similarity index 100% rename from patches/api/0408-Replace-ItemFlag.HIDE_POTION_EFFECTS.patch rename to patches/api/0407-Replace-ItemFlag.HIDE_POTION_EFFECTS.patch diff --git a/patches/api/0409-Win-Screen-API.patch b/patches/api/0408-Win-Screen-API.patch similarity index 94% rename from patches/api/0409-Win-Screen-API.patch rename to patches/api/0408-Win-Screen-API.patch index 97c2b2a9c1..4c98c1ab68 100644 --- a/patches/api/0409-Win-Screen-API.patch +++ b/patches/api/0408-Win-Screen-API.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Win Screen API diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java -index a6399eb076b7889085ffa1afcd9d432afdc29f85..ee446bfb3e6c4b1d4428c00d6406bf9455c68ad5 100644 +index 3f6eb664988b1f2c9d85157e75f3d5f3d89831d7..9cd49bf6db451af67cd15c8857d7bf51a4e1a67a 100644 --- a/src/main/java/org/bukkit/entity/Player.java +++ b/src/main/java/org/bukkit/entity/Player.java -@@ -876,6 +876,47 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM +@@ -877,6 +877,47 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM */ public void sendMap(@NotNull MapView map); diff --git a/patches/api/0410-Add-Entity-Body-Yaw-API.patch b/patches/api/0409-Add-Entity-Body-Yaw-API.patch similarity index 100% rename from patches/api/0410-Add-Entity-Body-Yaw-API.patch rename to patches/api/0409-Add-Entity-Body-Yaw-API.patch diff --git a/patches/api/0411-Fix-HandlerList-for-InventoryBlockStartEvent-subclas.patch b/patches/api/0410-Fix-HandlerList-for-InventoryBlockStartEvent-subclas.patch similarity index 100% rename from patches/api/0411-Fix-HandlerList-for-InventoryBlockStartEvent-subclas.patch rename to patches/api/0410-Fix-HandlerList-for-InventoryBlockStartEvent-subclas.patch diff --git a/patches/api/0412-Add-EntityFertilizeEggEvent.patch b/patches/api/0411-Add-EntityFertilizeEggEvent.patch similarity index 100% rename from patches/api/0412-Add-EntityFertilizeEggEvent.patch rename to patches/api/0411-Add-EntityFertilizeEggEvent.patch diff --git a/patches/api/0413-Add-CompostItemEvent-and-EntityCompostItemEvent.patch b/patches/api/0412-Add-CompostItemEvent-and-EntityCompostItemEvent.patch similarity index 100% rename from patches/api/0413-Add-CompostItemEvent-and-EntityCompostItemEvent.patch rename to patches/api/0412-Add-CompostItemEvent-and-EntityCompostItemEvent.patch diff --git a/patches/api/0414-Add-Shearable-API.patch b/patches/api/0413-Add-Shearable-API.patch similarity index 100% rename from patches/api/0414-Add-Shearable-API.patch rename to patches/api/0413-Add-Shearable-API.patch diff --git a/patches/api/0415-Fix-SpawnEggMeta-get-setSpawnedType.patch b/patches/api/0414-Fix-SpawnEggMeta-get-setSpawnedType.patch similarity index 100% rename from patches/api/0415-Fix-SpawnEggMeta-get-setSpawnedType.patch rename to patches/api/0414-Fix-SpawnEggMeta-get-setSpawnedType.patch diff --git a/patches/api/0416-Add-Mob-Experience-reward-API.patch b/patches/api/0415-Add-Mob-Experience-reward-API.patch similarity index 100% rename from patches/api/0416-Add-Mob-Experience-reward-API.patch rename to patches/api/0415-Add-Mob-Experience-reward-API.patch diff --git a/patches/server/0003-Build-system-changes.patch b/patches/server/0003-Build-system-changes.patch index c362f74f90..6a27314478 100644 --- a/patches/server/0003-Build-system-changes.patch +++ b/patches/server/0003-Build-system-changes.patch @@ -67,7 +67,7 @@ index e090175d2fbe8eba664500feafc29c0567bb0c87..d77f15c58f41f1e00c75e0a022919bb7 exclude("org/bukkit/craftbukkit/inventory/ItemStack*Test.class") } diff --git a/src/main/java/org/bukkit/craftbukkit/Main.java b/src/main/java/org/bukkit/craftbukkit/Main.java -index 0b608dcf8dde96a8a240954aaf6c6a82d3f506e7..f19755a6096b72d6ca302a4ea2d386fadfe2b122 100644 +index 39d0908d8a39524915a894f649b3e2a5c4a4e907..0d76c6880572e7620770f045e1faf59ea047a946 100644 --- a/src/main/java/org/bukkit/craftbukkit/Main.java +++ b/src/main/java/org/bukkit/craftbukkit/Main.java @@ -202,7 +202,7 @@ public class Main { @@ -78,7 +78,7 @@ index 0b608dcf8dde96a8a240954aaf6c6a82d3f506e7..f19755a6096b72d6ca302a4ea2d386fa + Date buildDate = new java.text.SimpleDateFormat("yyyy-MM-dd HH:mm:ss Z").parse(Main.class.getPackage().getImplementationVendor()); // Paper Calendar deadline = Calendar.getInstance(); - deadline.add(Calendar.DAY_OF_YEAR, -7); + deadline.add(Calendar.DAY_OF_YEAR, -21); diff --git a/src/main/java/org/bukkit/craftbukkit/util/Versioning.java b/src/main/java/org/bukkit/craftbukkit/util/Versioning.java index 93046379d0cefd5d3236fc59e698809acdc18f80..774556a62eb240da42e84db4502e2ed43495be17 100644 --- a/src/main/java/org/bukkit/craftbukkit/util/Versioning.java diff --git a/patches/server/0005-Paper-config-files.patch b/patches/server/0005-Paper-config-files.patch index f9298c5eb6..c888ef6da1 100644 --- a/patches/server/0005-Paper-config-files.patch +++ b/patches/server/0005-Paper-config-files.patch @@ -1448,7 +1448,7 @@ index 0000000000000000000000000000000000000000..1bb16fc7598cd53e822d84b69d6a9727 +} diff --git a/src/main/java/io/papermc/paper/configuration/WorldConfiguration.java b/src/main/java/io/papermc/paper/configuration/WorldConfiguration.java new file mode 100644 -index 0000000000000000000000000000000000000000..6b7795451036f5867e2ddbe2013d83256bc83076 +index 0000000000000000000000000000000000000000..ee430563b99e48cd722c2897e4729936457d3017 --- /dev/null +++ b/src/main/java/io/papermc/paper/configuration/WorldConfiguration.java @@ -0,0 +1,481 @@ @@ -4517,7 +4517,7 @@ index c434bec64863cb9023917e737c9471444f23a110..1fe07773cf9664164b29164caba22800 this.setPvpAllowed(dedicatedserverproperties.pvp); this.setFlightAllowed(dedicatedserverproperties.allowFlight); diff --git a/src/main/java/net/minecraft/server/dedicated/Settings.java b/src/main/java/net/minecraft/server/dedicated/Settings.java -index 7c35fb22df0bca2c2ca885a872ee42d6073d852f..26fc8127024d7b81ffe5c1c81b8ef8a68e35cbb6 100644 +index a02be624f7203d9465a8d62ccb734b436781f18c..5ac04182d32922dab00b81bc7f2ee1321066dcd5 100644 --- a/src/main/java/net/minecraft/server/dedicated/Settings.java +++ b/src/main/java/net/minecraft/server/dedicated/Settings.java @@ -75,6 +75,7 @@ public abstract class Settings> { @@ -4570,10 +4570,10 @@ index 9a86fedb7ea4932590b86ef96785141489b03528..40deaa2463876659c0579b5273b52497 this.world = new CraftWorld((ServerLevel) this, gen, biomeProvider, env); diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index ca2d2f44d722d2bf14f50670ac6192830b72c7f0..2cd8fc55056596731b34731a5fdf975f9a9f43ce 100644 +index 07c5931efcb5f3ca269e13183318eee57bb5389f..1e130b0f34d651f2f78f90950c52bac947993a74 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -880,6 +880,7 @@ public final class CraftServer implements Server { +@@ -881,6 +881,7 @@ public final class CraftServer implements Server { } org.spigotmc.SpigotConfig.init((File) console.options.valueOf("spigot-settings")); // Spigot @@ -4582,7 +4582,7 @@ index ca2d2f44d722d2bf14f50670ac6192830b72c7f0..2cd8fc55056596731b34731a5fdf975f world.serverLevelData.setDifficulty(config.difficulty); world.setSpawnSettings(config.spawnMonsters, config.spawnAnimals); diff --git a/src/main/java/org/bukkit/craftbukkit/Main.java b/src/main/java/org/bukkit/craftbukkit/Main.java -index f19755a6096b72d6ca302a4ea2d386fadfe2b122..fe726771b76cabcb58bf624969490d9595965082 100644 +index 0d76c6880572e7620770f045e1faf59ea047a946..6f4efb5553da256ee3a6dc422167d4cdbb208a5d 100644 --- a/src/main/java/org/bukkit/craftbukkit/Main.java +++ b/src/main/java/org/bukkit/craftbukkit/Main.java @@ -141,6 +141,19 @@ public class Main { @@ -4619,7 +4619,7 @@ index b97720e8934121be0f937bff6e257682e5738221..b599e098e6d2e6f78b89114e05cb03d7 for ( Method method : clazz.getDeclaredMethods() ) { diff --git a/src/main/java/org/spigotmc/SpigotWorldConfig.java b/src/main/java/org/spigotmc/SpigotWorldConfig.java -index b17fc2d59a488e59532059e204a9fdc76e15b938..3b7724a8ad8b9df0bbbca7fd2f8328e9885c5a73 100644 +index 65a6aadeca7fbd1271e8e96cd1f708942b6cba2d..afe68aa28f8b39fd490f650a335c90818e1c9a8d 100644 --- a/src/main/java/org/spigotmc/SpigotWorldConfig.java +++ b/src/main/java/org/spigotmc/SpigotWorldConfig.java @@ -58,8 +58,14 @@ public class SpigotWorldConfig diff --git a/patches/server/0008-CB-fixes.patch b/patches/server/0008-CB-fixes.patch index 6e4c9e83c3..ec06440bcf 100644 --- a/patches/server/0008-CB-fixes.patch +++ b/patches/server/0008-CB-fixes.patch @@ -83,10 +83,10 @@ index 161ad6ab1443b2ce33a2d7d91d189c855db0453b..15a9736a870055d639d03063c7cf67fd this.registryAccess = registryManager; this.structureTemplateManager = structureTemplateManager; diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 2cd8fc55056596731b34731a5fdf975f9a9f43ce..059ba63319f6ca04750a7d6b095e6179cae68b4f 100644 +index 1e130b0f34d651f2f78f90950c52bac947993a74..6581c2c498a73c1fb60bb922114e24a43d355748 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -2303,7 +2303,13 @@ public final class CraftServer implements Server { +@@ -2304,7 +2304,13 @@ public final class CraftServer implements Server { Validate.notNull(key, "NamespacedKey cannot be null"); LootTables registry = this.getServer().getLootTables(); diff --git a/patches/server/0009-MC-Utils.patch b/patches/server/0009-MC-Utils.patch index d54c8245ce..7b42abb9ae 100644 --- a/patches/server/0009-MC-Utils.patch +++ b/patches/server/0009-MC-Utils.patch @@ -6528,10 +6528,10 @@ index 3bcbdf37ad9d76ec97ad3f20e7a683e267441ed9..aa164a81d072d9390fa1400120e80197 public ServerLevel(MinecraftServer minecraftserver, Executor executor, LevelStorageSource.LevelStorageAccess convertable_conversionsession, PrimaryLevelData iworlddataserver, ResourceKey resourcekey, LevelStem worlddimension, ChunkProgressListener worldloadlistener, boolean flag, long i, List list, boolean flag1, org.bukkit.World.Environment env, org.bukkit.generator.ChunkGenerator gen, org.bukkit.generator.BiomeProvider biomeProvider) { // IRegistryCustom.Dimension iregistrycustom_dimension = minecraftserver.registryAccess(); // CraftBukkit - decompile error diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java -index d47db4ba6ebca0f92c205476171387735329fbf5..3243cfd90e11176efc2059d864fb962497d70942 100644 +index fcc9aaa87b4092e838b6523e15347f01b38b8943..e8f748a7af40637b6aa5e0b032de909316e1161f 100644 --- a/src/main/java/net/minecraft/server/level/ServerPlayer.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java -@@ -253,6 +253,8 @@ public class ServerPlayer extends Player { +@@ -255,6 +255,8 @@ public class ServerPlayer extends Player { public Integer clientViewDistance; public String kickLeaveMessage = null; // SPIGOT-3034: Forward leave message to PlayerQuitEvent // CraftBukkit end @@ -6540,7 +6540,7 @@ index d47db4ba6ebca0f92c205476171387735329fbf5..3243cfd90e11176efc2059d864fb9624 public ServerPlayer(MinecraftServer server, ServerLevel world, GameProfile profile) { super(world, world.getSharedSpawnPos(), world.getSharedSpawnAngle(), profile); -@@ -318,6 +320,8 @@ public class ServerPlayer extends Player { +@@ -320,6 +322,8 @@ public class ServerPlayer extends Player { this.setMaxUpStep(1.0F); this.fudgeSpawnLocation(world); @@ -6593,10 +6593,10 @@ index a63d5ba706a5b8e430aedc045bdeb3a410bd0eef..e96a0ca47e4701ba187555bd92c96834 public BlockState getBlockState(BlockPos pos) { return this.getChunk(SectionPos.blockToSectionCoord(pos.getX()), SectionPos.blockToSectionCoord(pos.getZ())).getBlockState(pos); diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java -index 3ab9d73dd1f2d2ade24b3e04616a5312debd948f..7a8b26068a244be553d55f0018a9edebe00b6dff 100644 +index 5ef84d53146de440e4eb14ba33bc4fb9885045b8..9909208363443a216cf689197f103d9e79119bbf 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -183,6 +183,7 @@ public abstract class PlayerList { +@@ -185,6 +185,7 @@ public abstract class PlayerList { } public void placeNewPlayer(Connection connection, ServerPlayer player) { @@ -6623,10 +6623,10 @@ index 337e0a7b3c14e1b1a28744920e0dc0a69e0c5a87..f5829ae484d93b547a5437b85a962134 @Override public void tell(R runnable) { diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index 926c319fc4b629cf16cc973c2e26830630dd93ab..4cd1cfbf91ea232756de16120eec4339d8144885 100644 +index 3177b3b974b6a98d41bc9e57c75b49bf9584b17b..956c39b6d0c208366508f2064f7b98270eebaedc 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -318,6 +318,11 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -319,6 +319,11 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { return this.level.hasChunk((int) Math.floor(this.getX()) >> 4, (int) Math.floor(this.getZ()) >> 4); } // CraftBukkit end @@ -6688,7 +6688,7 @@ index a0b5895abc88d297045e05f25bb09527991d43f0..6e0bd0eab0b06a4ac3042496bbb91292 super(type, world); this.xpReward = 5; diff --git a/src/main/java/net/minecraft/world/item/ItemStack.java b/src/main/java/net/minecraft/world/item/ItemStack.java -index 37bf8a861f1336dae61d1ed8f26be92382055e78..e19407edd4847e5a5175e113944d1331bd4d4ffc 100644 +index fecfcd21647efa27c2fb82617070eed10574abc5..81f6b580873fdad106515c3fc619e2288d936ca3 100644 --- a/src/main/java/net/minecraft/world/item/ItemStack.java +++ b/src/main/java/net/minecraft/world/item/ItemStack.java @@ -786,6 +786,25 @@ public final class ItemStack { @@ -7303,10 +7303,10 @@ index f66369ddaeab5c5ac643c0979dac3ed21337ff71..038abf2ac104ceecaab11b10d466ea69 return false; } else { diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -index 5e36e5af2f6e5a705f36105d4ffed8d142886f6f..9a033c136062c43e6db8107fdff059a6807aed02 100644 +index 52ce5136087e954189d3737ca315226515375b3b..981bfb92cd4d167620631facc51da564633b3adc 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -@@ -245,8 +245,8 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -241,8 +241,8 @@ public class CraftWorld extends CraftRegionAccessor implements World { @Override public Chunk[] getLoadedChunks() { @@ -7317,7 +7317,7 @@ index 5e36e5af2f6e5a705f36105d4ffed8d142886f6f..9a033c136062c43e6db8107fdff059a6 } @Override -@@ -321,7 +321,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -317,7 +317,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { @Override public boolean refreshChunk(int x, int z) { @@ -7326,7 +7326,7 @@ index 5e36e5af2f6e5a705f36105d4ffed8d142886f6f..9a033c136062c43e6db8107fdff059a6 if (playerChunk == null) return false; playerChunk.getTickingChunkFuture().thenAccept(either -> { -@@ -1970,4 +1970,32 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -1956,4 +1956,32 @@ public class CraftWorld extends CraftRegionAccessor implements World { return this.spigot; } // Spigot end @@ -7360,7 +7360,7 @@ index 5e36e5af2f6e5a705f36105d4ffed8d142886f6f..9a033c136062c43e6db8107fdff059a6 + // Paper end } diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java -index e24609bb51369c08a68120830ead33706b17dafa..f4cdda9fabb3a13f7cc8b6056815bdbae704db9d 100644 +index a3d5c050ad73697573970e3a4db72845671de9c8..cf9bbc1334a151dfd96be91e6f2cf3cb9afd9384 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java @@ -1182,4 +1182,37 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity { diff --git a/patches/server/0010-Adventure.patch b/patches/server/0010-Adventure.patch index bccb17db69..05e9b34599 100644 --- a/patches/server/0010-Adventure.patch +++ b/patches/server/0010-Adventure.patch @@ -2215,7 +2215,7 @@ index 5725631835ea68802c75934cd85d5c1b1a78d358..b130edcdc4a91e6d1cfc59d80223edf9 } diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java -index 3243cfd90e11176efc2059d864fb962497d70942..7e4c10bfdaf1e7f2dfc03d220e5c731927b0b5f9 100644 +index e8f748a7af40637b6aa5e0b032de909316e1161f..8105a30251c45b4ab111c97d34029c66180922fd 100644 --- a/src/main/java/net/minecraft/server/level/ServerPlayer.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java @@ -161,6 +161,7 @@ import net.minecraft.world.scores.Score; @@ -2226,7 +2226,7 @@ index 3243cfd90e11176efc2059d864fb962497d70942..7e4c10bfdaf1e7f2dfc03d220e5c7319 import org.bukkit.Bukkit; import org.bukkit.Location; import org.bukkit.WeatherType; -@@ -241,6 +242,7 @@ public class ServerPlayer extends Player { +@@ -243,6 +244,7 @@ public class ServerPlayer extends Player { // CraftBukkit start public String displayName; @@ -2234,7 +2234,7 @@ index 3243cfd90e11176efc2059d864fb962497d70942..7e4c10bfdaf1e7f2dfc03d220e5c7319 public Component listName; public org.bukkit.Location compassTarget; public int newExp = 0; -@@ -324,6 +326,7 @@ public class ServerPlayer extends Player { +@@ -326,6 +328,7 @@ public class ServerPlayer extends Player { // CraftBukkit start this.displayName = this.getScoreboardName(); @@ -2242,7 +2242,7 @@ index 3243cfd90e11176efc2059d864fb962497d70942..7e4c10bfdaf1e7f2dfc03d220e5c7319 this.bukkitPickUpLoot = true; this.maxHealthCache = this.getMaxHealth(); } -@@ -817,22 +820,17 @@ public class ServerPlayer extends Player { +@@ -819,22 +822,17 @@ public class ServerPlayer extends Player { String deathmessage = defaultMessage.getString(); this.keepLevel = keepInventory; // SPIGOT-2222: pre-set keepLevel @@ -2269,7 +2269,7 @@ index 3243cfd90e11176efc2059d864fb962497d70942..7e4c10bfdaf1e7f2dfc03d220e5c7319 this.connection.send(new ClientboundPlayerCombatKillPacket(this.getCombatTracker(), ichatbasecomponent), PacketSendListener.exceptionallySend(() -> { boolean flag1 = true; -@@ -1769,13 +1767,13 @@ public class ServerPlayer extends Player { +@@ -1771,13 +1769,13 @@ public class ServerPlayer extends Player { public void sendSystemMessage(Component message, boolean overlay) { if (this.acceptsSystemMessages(overlay)) { @@ -2285,7 +2285,7 @@ index 3243cfd90e11176efc2059d864fb962497d70942..7e4c10bfdaf1e7f2dfc03d220e5c7319 } else { return null; } -@@ -1784,8 +1782,13 @@ public class ServerPlayer extends Player { +@@ -1786,8 +1784,13 @@ public class ServerPlayer extends Player { } public void sendChatMessage(OutgoingChatMessage message, boolean filterMaskEnabled, ChatType.Bound params) { @@ -2300,7 +2300,7 @@ index 3243cfd90e11176efc2059d864fb962497d70942..7e4c10bfdaf1e7f2dfc03d220e5c7319 } } -@@ -1803,6 +1806,7 @@ public class ServerPlayer extends Player { +@@ -1805,6 +1808,7 @@ public class ServerPlayer extends Player { } public String locale = "en_us"; // CraftBukkit - add, lowercase @@ -2308,7 +2308,7 @@ index 3243cfd90e11176efc2059d864fb962497d70942..7e4c10bfdaf1e7f2dfc03d220e5c7319 public void updateOptions(ServerboundClientInformationPacket packet) { // CraftBukkit start if (getMainArm() != packet.mainHand()) { -@@ -1814,6 +1818,10 @@ public class ServerPlayer extends Player { +@@ -1816,6 +1820,10 @@ public class ServerPlayer extends Player { this.server.server.getPluginManager().callEvent(event); } this.locale = packet.language; @@ -2320,7 +2320,7 @@ index 3243cfd90e11176efc2059d864fb962497d70942..7e4c10bfdaf1e7f2dfc03d220e5c7319 // CraftBukkit end this.chatVisibility = packet.chatVisibility(); diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 29cbad55217400f5ba830b876422dc1823c33a71..9116de00912e07dc049735a183719f6f8c2660b4 100644 +index d4065032c7d9f37c1f64f61d67f7204139e3b493..531c8e74e7aa81a483650ec891a994ff7ff70a5c 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java @@ -187,6 +187,8 @@ import net.minecraft.world.phys.shapes.VoxelShape; @@ -2332,7 +2332,7 @@ index 29cbad55217400f5ba830b876422dc1823c33a71..9116de00912e07dc049735a183719f6f import com.mojang.datafixers.util.Pair; import java.util.Arrays; import java.util.concurrent.ExecutionException; -@@ -251,7 +253,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -252,7 +254,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic private static final int NO_BLOCK_UPDATES_TO_ACK = -1; private static final int TRACKED_MESSAGE_DISCONNECT_THRESHOLD = 4096; private static final Component CHAT_VALIDATION_FAILED = Component.translatable("multiplayer.disconnect.chat_validation_failed"); @@ -2341,7 +2341,7 @@ index 29cbad55217400f5ba830b876422dc1823c33a71..9116de00912e07dc049735a183719f6f private final MinecraftServer server; public ServerPlayer player; private int tickCount; -@@ -439,14 +441,17 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -440,14 +442,17 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic return this.server.isSingleplayerOwner(this.player.getGameProfile()); } @@ -2365,7 +2365,7 @@ index 29cbad55217400f5ba830b876422dc1823c33a71..9116de00912e07dc049735a183719f6f // CraftBukkit start - fire PlayerKickEvent if (this.processedDisconnect) { return; -@@ -455,7 +460,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -456,7 +461,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic Waitable waitable = new Waitable() { @Override protected Object evaluate() { @@ -2374,7 +2374,7 @@ index 29cbad55217400f5ba830b876422dc1823c33a71..9116de00912e07dc049735a183719f6f return null; } }; -@@ -472,9 +477,9 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -473,9 +478,9 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic return; } @@ -2386,7 +2386,7 @@ index 29cbad55217400f5ba830b876422dc1823c33a71..9116de00912e07dc049735a183719f6f if (this.cserver.getServer().isRunning()) { this.cserver.getPluginManager().callEvent(event); -@@ -486,7 +491,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -487,7 +492,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic } this.player.kickLeaveMessage = event.getLeaveMessage(); // CraftBukkit - SPIGOT-3034: Forward leave message to PlayerQuitEvent // Send the possibly modified leave message @@ -2395,7 +2395,7 @@ index 29cbad55217400f5ba830b876422dc1823c33a71..9116de00912e07dc049735a183719f6f // CraftBukkit end this.connection.send(new ClientboundDisconnectPacket(ichatbasecomponent), PacketSendListener.thenRun(() -> { -@@ -1783,9 +1788,11 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -1784,9 +1789,11 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic */ this.player.disconnect(); @@ -2410,7 +2410,7 @@ index 29cbad55217400f5ba830b876422dc1823c33a71..9116de00912e07dc049735a183719f6f } // CraftBukkit end this.player.getTextFilter().leave(); -@@ -1882,11 +1889,11 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -1883,11 +1890,11 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic } CompletableFuture completablefuture = this.filterTextPacket(playerchatmessage.signedContent()); @@ -2424,7 +2424,7 @@ index 29cbad55217400f5ba830b876422dc1823c33a71..9116de00912e07dc049735a183719f6f this.broadcastChatMessage(playerchatmessage1); }, this.server.chatExecutor); // CraftBukkit - async chat -@@ -1986,7 +1993,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -1993,7 +2000,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic Optional optional = this.unpackAndApplyLastSeen(acknowledgment); if (this.player.isRemoved() || this.player.getChatVisibility() == ChatVisiblity.HIDDEN) { // CraftBukkit - dead men tell no tales @@ -2433,7 +2433,7 @@ index 29cbad55217400f5ba830b876422dc1823c33a71..9116de00912e07dc049735a183719f6f return Optional.empty(); } else { this.player.resetLastActionTime(); -@@ -2044,7 +2051,12 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -2051,7 +2058,12 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic this.handleCommand(s); } else if (this.player.getChatVisibility() == ChatVisiblity.SYSTEM) { // Do nothing, this is coming from a plugin @@ -2447,7 +2447,7 @@ index 29cbad55217400f5ba830b876422dc1823c33a71..9116de00912e07dc049735a183719f6f Player player = this.getCraftPlayer(); AsyncPlayerChatEvent event = new AsyncPlayerChatEvent(async, player, s, new LazyPlayerSet(this.server)); String originalFormat = event.getFormat(), originalMessage = event.getMessage(); -@@ -2174,7 +2186,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -2181,7 +2193,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic } }); } else if (this.player.getChatVisibility() == ChatVisiblity.SYSTEM) { // Re-add "Command Only" flag check @@ -2456,7 +2456,7 @@ index 29cbad55217400f5ba830b876422dc1823c33a71..9116de00912e07dc049735a183719f6f } else { this.chat(s, message, true); } -@@ -2996,30 +3008,30 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -3003,30 +3015,30 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic return; } @@ -2536,7 +2536,7 @@ index 1cb95db25a20d38faacd99a5805630c1598e9db3..d99b2235038eb1aba8cda474c4aa51e2 @Override diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java -index 7a8b26068a244be553d55f0018a9edebe00b6dff..d00a2da03f8911f0e07ca22c8c569be7fc189842 100644 +index 9909208363443a216cf689197f103d9e79119bbf..857ce5715e4ea68df2964a3f6595cdb8526cd32a 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; @@ -2547,7 +2547,7 @@ index 7a8b26068a244be553d55f0018a9edebe00b6dff..d00a2da03f8911f0e07ca22c8c569be7 import java.io.File; import java.net.SocketAddress; import java.nio.file.Path; -@@ -274,7 +275,7 @@ public abstract class PlayerList { +@@ -276,7 +277,7 @@ public abstract class PlayerList { } // CraftBukkit start ichatmutablecomponent.withStyle(ChatFormatting.YELLOW); @@ -2556,7 +2556,7 @@ index 7a8b26068a244be553d55f0018a9edebe00b6dff..d00a2da03f8911f0e07ca22c8c569be7 playerconnection.teleport(player.getX(), player.getY(), player.getZ(), player.getYRot(), player.getXRot()); ServerStatus serverping = this.server.getStatus(); -@@ -295,19 +296,18 @@ public abstract class PlayerList { +@@ -297,19 +298,18 @@ public abstract class PlayerList { // Ensure that player inventory is populated with its viewer player.containerMenu.transferTo(player.containerMenu, bukkitPlayer); @@ -2581,7 +2581,7 @@ index 7a8b26068a244be553d55f0018a9edebe00b6dff..d00a2da03f8911f0e07ca22c8c569be7 } // CraftBukkit end -@@ -504,7 +504,7 @@ public abstract class PlayerList { +@@ -506,7 +506,7 @@ public abstract class PlayerList { } @@ -2590,7 +2590,7 @@ index 7a8b26068a244be553d55f0018a9edebe00b6dff..d00a2da03f8911f0e07ca22c8c569be7 ServerLevel worldserver = entityplayer.getLevel(); entityplayer.awardStat(Stats.LEAVE_GAME); -@@ -515,7 +515,7 @@ public abstract class PlayerList { +@@ -517,7 +517,7 @@ public abstract class PlayerList { entityplayer.closeContainer(); } @@ -2599,7 +2599,7 @@ index 7a8b26068a244be553d55f0018a9edebe00b6dff..d00a2da03f8911f0e07ca22c8c569be7 this.cserver.getPluginManager().callEvent(playerQuitEvent); entityplayer.getBukkitEntity().disconnect(playerQuitEvent.getQuitMessage()); -@@ -568,7 +568,7 @@ public abstract class PlayerList { +@@ -570,7 +570,7 @@ public abstract class PlayerList { this.cserver.getScoreboardManager().removePlayer(entityplayer.getBukkitEntity()); // CraftBukkit end @@ -2608,7 +2608,7 @@ index 7a8b26068a244be553d55f0018a9edebe00b6dff..d00a2da03f8911f0e07ca22c8c569be7 } // CraftBukkit start - Whole method, SocketAddress to LoginListener, added hostname to signature, return EntityPlayer -@@ -614,10 +614,10 @@ public abstract class PlayerList { +@@ -616,10 +616,10 @@ public abstract class PlayerList { } // return chatmessage; @@ -2621,7 +2621,7 @@ index 7a8b26068a244be553d55f0018a9edebe00b6dff..d00a2da03f8911f0e07ca22c8c569be7 } else if (this.getIpBans().isBanned(socketaddress) && !this.getIpBans().get(socketaddress).hasExpired()) { IpBanListEntry ipbanentry = this.ipBans.get(socketaddress); -@@ -627,17 +627,17 @@ public abstract class PlayerList { +@@ -629,17 +629,17 @@ public abstract class PlayerList { } // return chatmessage; @@ -2642,7 +2642,7 @@ index 7a8b26068a244be553d55f0018a9edebe00b6dff..d00a2da03f8911f0e07ca22c8c569be7 return null; } return entity; -@@ -1148,7 +1148,7 @@ public abstract class PlayerList { +@@ -1150,7 +1150,7 @@ public abstract class PlayerList { public void removeAll() { // CraftBukkit start - disconnect safely for (ServerPlayer player : this.players) { @@ -2651,7 +2651,7 @@ index 7a8b26068a244be553d55f0018a9edebe00b6dff..d00a2da03f8911f0e07ca22c8c569be7 } // CraftBukkit end -@@ -1189,24 +1189,43 @@ public abstract class PlayerList { +@@ -1191,24 +1191,43 @@ public abstract class PlayerList { } public void broadcastChatMessage(PlayerChatMessage message, ServerPlayer sender, ChatType.Bound params) { @@ -2698,7 +2698,7 @@ index 7a8b26068a244be553d55f0018a9edebe00b6dff..d00a2da03f8911f0e07ca22c8c569be7 } if (flag1 && sender != null) { -@@ -1215,7 +1234,7 @@ public abstract class PlayerList { +@@ -1217,7 +1236,7 @@ public abstract class PlayerList { } @@ -2817,10 +2817,10 @@ index 0e04e7467ee27ea9e3ef60fe598cc21ab39f4c68..0f5e92a2256fe22b55d2428f98db403a } collection = icons; diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 059ba63319f6ca04750a7d6b095e6179cae68b4f..cb2dc6db887856c5f60d127f5999a0785702f2f4 100644 +index 6581c2c498a73c1fb60bb922114e24a43d355748..44f10adc1957436d9067657b95f04a12b9b7a867 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -600,8 +600,10 @@ public final class CraftServer implements Server { +@@ -601,8 +601,10 @@ public final class CraftServer implements Server { } @Override @@ -2831,7 +2831,7 @@ index 059ba63319f6ca04750a7d6b095e6179cae68b4f..cb2dc6db887856c5f60d127f5999a078 } @Override -@@ -1439,7 +1441,15 @@ public final class CraftServer implements Server { +@@ -1440,7 +1442,15 @@ public final class CraftServer implements Server { return this.configuration.getInt("settings.spawn-radius", -1); } @@ -2847,7 +2847,7 @@ index 059ba63319f6ca04750a7d6b095e6179cae68b4f..cb2dc6db887856c5f60d127f5999a078 public String getShutdownMessage() { return this.configuration.getString("settings.shutdown-message"); } -@@ -1607,7 +1617,20 @@ public final class CraftServer implements Server { +@@ -1608,7 +1618,20 @@ public final class CraftServer implements Server { } @Override @@ -2868,7 +2868,7 @@ index 059ba63319f6ca04750a7d6b095e6179cae68b4f..cb2dc6db887856c5f60d127f5999a078 Set recipients = new HashSet<>(); for (Permissible permissible : this.getPluginManager().getPermissionSubscriptions(permission)) { if (permissible instanceof CommandSender && permissible.hasPermission(permission)) { -@@ -1615,14 +1638,14 @@ public final class CraftServer implements Server { +@@ -1616,14 +1639,14 @@ public final class CraftServer implements Server { } } @@ -2885,7 +2885,7 @@ index 059ba63319f6ca04750a7d6b095e6179cae68b4f..cb2dc6db887856c5f60d127f5999a078 for (CommandSender recipient : recipients) { recipient.sendMessage(message); -@@ -1873,6 +1896,14 @@ public final class CraftServer implements Server { +@@ -1874,6 +1897,14 @@ public final class CraftServer implements Server { return CraftInventoryCreator.INSTANCE.createInventory(owner, type); } @@ -2900,7 +2900,7 @@ index 059ba63319f6ca04750a7d6b095e6179cae68b4f..cb2dc6db887856c5f60d127f5999a078 @Override public Inventory createInventory(InventoryHolder owner, InventoryType type, String title) { Validate.isTrue(type.isCreatable(), "Cannot open an inventory of type ", type); -@@ -1885,13 +1916,28 @@ public final class CraftServer implements Server { +@@ -1886,13 +1917,28 @@ public final class CraftServer implements Server { return CraftInventoryCreator.INSTANCE.createInventory(owner, size); } @@ -2929,7 +2929,7 @@ index 059ba63319f6ca04750a7d6b095e6179cae68b4f..cb2dc6db887856c5f60d127f5999a078 public Merchant createMerchant(String title) { return new CraftMerchantCustom(title == null ? InventoryType.MERCHANT.getDefaultTitle() : title); } -@@ -1956,6 +2002,12 @@ public final class CraftServer implements Server { +@@ -1957,6 +2003,12 @@ public final class CraftServer implements Server { return Thread.currentThread().equals(console.serverThread) || this.console.hasStopped() || !org.spigotmc.AsyncCatcher.enabled; // All bets are off if we have shut down (e.g. due to watchdog) } @@ -2942,7 +2942,7 @@ index 059ba63319f6ca04750a7d6b095e6179cae68b4f..cb2dc6db887856c5f60d127f5999a078 @Override public String getMotd() { return this.console.getMotd(); -@@ -2382,4 +2434,15 @@ public final class CraftServer implements Server { +@@ -2383,4 +2435,15 @@ public final class CraftServer implements Server { return this.spigot; } // Spigot end @@ -2959,10 +2959,10 @@ index 059ba63319f6ca04750a7d6b095e6179cae68b4f..cb2dc6db887856c5f60d127f5999a078 + // Paper end } diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -index 9a033c136062c43e6db8107fdff059a6807aed02..4186943ba9e94758d579477e8fadaf8e05ef93f3 100644 +index 981bfb92cd4d167620631facc51da564633b3adc..2f83e56b59407dc388240676ae5cfd73de2a9066 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -@@ -150,6 +150,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -151,6 +151,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { private final BlockMetadataStore blockMetadata = new BlockMetadataStore(this); private final Object2IntOpenHashMap spawnCategoryLimit = new Object2IntOpenHashMap<>(); private final CraftPersistentDataContainer persistentDataContainer = new CraftPersistentDataContainer(CraftWorld.DATA_TYPE_REGISTRY); @@ -2970,7 +2970,7 @@ index 9a033c136062c43e6db8107fdff059a6807aed02..4186943ba9e94758d579477e8fadaf8e private static final Random rand = new Random(); -@@ -1997,5 +1998,18 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -1983,5 +1984,18 @@ public class CraftWorld extends CraftRegionAccessor implements World { return ret; } @@ -2990,7 +2990,7 @@ index 9a033c136062c43e6db8107fdff059a6807aed02..4186943ba9e94758d579477e8fadaf8e // Paper end } diff --git a/src/main/java/org/bukkit/craftbukkit/Main.java b/src/main/java/org/bukkit/craftbukkit/Main.java -index fe726771b76cabcb58bf624969490d9595965082..e16a458a708080ff5321362cba440fa465dba7d6 100644 +index 6f4efb5553da256ee3a6dc422167d4cdbb208a5d..4e7208a891da461a10920482e4e4427ace23fb45 100644 --- a/src/main/java/org/bukkit/craftbukkit/Main.java +++ b/src/main/java/org/bukkit/craftbukkit/Main.java @@ -20,6 +20,12 @@ public class Main { @@ -3357,7 +3357,7 @@ index f6c614bb1184f9c79121f64a2a030bf3f094b671..e8334e2264510f5101e80b4f130e7ae1 public net.minecraft.world.item.enchantment.Enchantment getHandle() { return this.target; diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java -index f4cdda9fabb3a13f7cc8b6056815bdbae704db9d..17c914088b467007aada17e3b2238a9c76fb532b 100644 +index cf9bbc1334a151dfd96be91e6f2cf3cb9afd9384..2849f70314f1cd8aeac38c8ab37d293732d4504c 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java @@ -202,6 +202,7 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity { @@ -3420,10 +3420,10 @@ index f4cdda9fabb3a13f7cc8b6056815bdbae704db9d..17c914088b467007aada17e3b2238a9c @Override public boolean isPermissionSet(String name) { diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java -index aea8bdbfe0c16c664d787e8abcd189f1019fccce..e38c32708ac7969dbc342989d2a5a767e26e4c3d 100644 +index 1ea310624abbc949eaa16c1e2b85de6c31dd3d43..a26743682edcd9329d70ae1ff38310c8379f94e1 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java -@@ -321,9 +321,12 @@ public class CraftHumanEntity extends CraftLivingEntity implements HumanEntity { +@@ -322,9 +322,12 @@ public class CraftHumanEntity extends CraftLivingEntity implements HumanEntity { container = CraftEventFactory.callInventoryOpenEvent(player, container); if (container == null) return; @@ -3438,7 +3438,7 @@ index aea8bdbfe0c16c664d787e8abcd189f1019fccce..e38c32708ac7969dbc342989d2a5a767 player.containerMenu = container; player.initMenu(container); } -@@ -392,8 +395,12 @@ public class CraftHumanEntity extends CraftLivingEntity implements HumanEntity { +@@ -393,8 +396,12 @@ public class CraftHumanEntity extends CraftLivingEntity implements HumanEntity { // Now open the window MenuType windowType = CraftContainer.getNotchInventoryType(inventory.getTopInventory()); @@ -3472,10 +3472,10 @@ index 446fdca49a5a6999626a7ee3a1d5c168b15a09dd..f9863e138994f6c7a7975a852f106faa public boolean isOp() { return true; diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -index f00a6d38609d38ea51153997ba526963d734c372..8fcd46bef75b3d48356445575c4a6c1b93b61072 100644 +index 1fc45821f61b7f14876a31a5792cfbd1f2efe6b2..f1208e752cdab08228d790a5195114a62d16d399 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -@@ -279,14 +279,39 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -283,14 +283,39 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @Override public String getDisplayName() { @@ -3515,7 +3515,7 @@ index f00a6d38609d38ea51153997ba526963d734c372..8fcd46bef75b3d48356445575c4a6c1b @Override public String getPlayerListName() { return this.getHandle().listName == null ? getName() : CraftChatMessage.fromComponent(this.getHandle().listName); -@@ -305,42 +330,42 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -309,42 +334,42 @@ public class CraftPlayer extends CraftHumanEntity implements Player { } } @@ -3567,7 +3567,7 @@ index f00a6d38609d38ea51153997ba526963d734c372..8fcd46bef75b3d48356445575c4a6c1b this.getHandle().connection.send(packet); } -@@ -372,6 +397,23 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -376,6 +401,23 @@ public class CraftPlayer extends CraftHumanEntity implements Player { this.getHandle().connection.disconnect(message == null ? "" : message); } @@ -3591,7 +3591,7 @@ index f00a6d38609d38ea51153997ba526963d734c372..8fcd46bef75b3d48356445575c4a6c1b @Override public void setCompassTarget(Location loc) { if (this.getHandle().connection == null) return; -@@ -700,6 +742,35 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -704,6 +746,24 @@ public class CraftPlayer extends CraftHumanEntity implements Player { this.getHandle().connection.send(packet); } @@ -3612,40 +3612,33 @@ index f00a6d38609d38ea51153997ba526963d734c372..8fcd46bef75b3d48356445575c4a6c1b + Component[] components = CraftSign.sanitizeLines(lines); + this.sendSignChange0(components, loc, dyeColor, hasGlowingText); + } -+ -+ private void sendSignChange0(Component[] components, Location loc, DyeColor dyeColor, boolean hasGlowingText) { -+ SignBlockEntity sign = new SignBlockEntity(new BlockPos(loc.getBlockX(), loc.getBlockY(), loc.getBlockZ()), Blocks.OAK_SIGN.defaultBlockState()); -+ sign.setColor(net.minecraft.world.item.DyeColor.byId(dyeColor.getWoolData())); -+ sign.setHasGlowingText(hasGlowingText); -+ for (int i = 0; i < components.length; i++) { -+ sign.setMessage(i, components[i]); -+ } -+ -+ getHandle().connection.send(sign.getUpdatePacket()); -+ } + // Paper end @Override public void sendSignChange(Location loc, String[] lines) { this.sendSignChange(loc, lines, DyeColor.BLACK); -@@ -727,14 +798,15 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -731,6 +791,11 @@ public class CraftPlayer extends CraftHumanEntity implements Player { } Component[] components = CraftSign.sanitizeLines(lines); -- SignBlockEntity sign = new SignBlockEntity(new BlockPos(loc.getBlockX(), loc.getBlockY(), loc.getBlockZ()), Blocks.OAK_SIGN.defaultBlockState()); -+ /*SignBlockEntity sign = new SignBlockEntity(new BlockPos(loc.getBlockX(), loc.getBlockY(), loc.getBlockZ()), Blocks.OAK_SIGN.defaultBlockState()); ++ // Paper start - adventure ++ this.sendSignChange0(components, loc, dyeColor, hasGlowingText); ++ } ++ ++ private void sendSignChange0(Component[] components, Location loc, DyeColor dyeColor, boolean hasGlowingText) { + SignBlockEntity sign = new SignBlockEntity(CraftLocation.toBlockPosition(loc), Blocks.OAK_SIGN.defaultBlockState()); sign.setColor(net.minecraft.world.item.DyeColor.byId(dyeColor.getWoolData())); sign.setHasGlowingText(hasGlowingText); - for (int i = 0; i < components.length; i++) { +@@ -738,7 +803,8 @@ public class CraftPlayer extends CraftHumanEntity implements Player { sign.setMessage(i, components[i]); } - this.getHandle().connection.send(sign.getUpdatePacket()); -+ this.getHandle().connection.send(sign.getUpdatePacket());*/ // Paper -+ this.sendSignChange0(components, loc, dyeColor, hasGlowingText); // Paper ++ getHandle().connection.send(sign.getUpdatePacket()); ++ // Paper end } @Override -@@ -1617,7 +1689,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -1631,7 +1697,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @Override public void setResourcePack(String url) { @@ -3654,7 +3647,7 @@ index f00a6d38609d38ea51153997ba526963d734c372..8fcd46bef75b3d48356445575c4a6c1b } @Override -@@ -1632,7 +1704,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -1646,7 +1712,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @Override public void setResourcePack(String url, byte[] hash, boolean force) { @@ -3663,7 +3656,7 @@ index f00a6d38609d38ea51153997ba526963d734c372..8fcd46bef75b3d48356445575c4a6c1b } @Override -@@ -1648,6 +1720,21 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -1662,6 +1728,21 @@ public class CraftPlayer extends CraftHumanEntity implements Player { } } @@ -3685,7 +3678,7 @@ index f00a6d38609d38ea51153997ba526963d734c372..8fcd46bef75b3d48356445575c4a6c1b public void addChannel(String channel) { Preconditions.checkState(this.channels.size() < 128, "Cannot register channel '%s'. Too many channels registered!", channel); channel = StandardMessenger.validateAndCorrectChannel(channel); -@@ -2052,6 +2139,12 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -2066,6 +2147,12 @@ public class CraftPlayer extends CraftHumanEntity implements Player { return (this.getHandle().clientViewDistance == null) ? Bukkit.getViewDistance() : this.getHandle().clientViewDistance; } @@ -3698,7 +3691,7 @@ index f00a6d38609d38ea51153997ba526963d734c372..8fcd46bef75b3d48356445575c4a6c1b @Override public int getPing() { return this.getHandle().latency; -@@ -2097,6 +2190,254 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -2111,6 +2198,254 @@ public class CraftPlayer extends CraftHumanEntity implements Player { return this.getHandle().allowsListing(); } @@ -3976,10 +3969,10 @@ index 2becf197a5c2d94f23f72a9b20cb2cd05a0807df..99096c1e3f045e4a99335faedfb8e77e @Override public int getLineWidth() { diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java -index c1a3f7b281ecc1551dd51faac046e02064a72afe..9bf4b8865237fd2555ed0e4b2e619afd7dc6845e 100644 +index f81248294a4ccc4a9c88b071654f8a62713e397c..f1dc8eaa571f54e5885ceada9929d965992d7760 100644 --- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java +++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java -@@ -836,9 +836,9 @@ public class CraftEventFactory { +@@ -838,9 +838,9 @@ public class CraftEventFactory { return event; } @@ -3991,7 +3984,7 @@ index c1a3f7b281ecc1551dd51faac046e02064a72afe..9bf4b8865237fd2555ed0e4b2e619afd event.setKeepInventory(keepInventory); event.setKeepLevel(victim.keepLevel); // SPIGOT-2222: pre-set keepLevel org.bukkit.World world = entity.getWorld(); -@@ -863,7 +863,7 @@ public class CraftEventFactory { +@@ -865,7 +865,7 @@ public class CraftEventFactory { * Server methods */ public static ServerListPingEvent callServerListPingEvent(Server craftServer, InetAddress address, String motd, int numPlayers, int maxPlayers) { @@ -4001,10 +3994,10 @@ index c1a3f7b281ecc1551dd51faac046e02064a72afe..9bf4b8865237fd2555ed0e4b2e619afd return event; } diff --git a/src/main/java/org/bukkit/craftbukkit/inventory/CraftContainer.java b/src/main/java/org/bukkit/craftbukkit/inventory/CraftContainer.java -index a94bfca34ba87976a51c5572250059d393041f38..7d0d2cd4d34d6652eb45aa13442e1081a3a6bd56 100644 +index a2b1e3a8747cc26c617f06f9000b7b40b5b9c6c7..fe54d5cb2414c7b6f42d192c74f810e7b5e43f0e 100644 --- a/src/main/java/org/bukkit/craftbukkit/inventory/CraftContainer.java +++ b/src/main/java/org/bukkit/craftbukkit/inventory/CraftContainer.java -@@ -68,6 +68,13 @@ public class CraftContainer extends AbstractContainerMenu { +@@ -72,6 +72,13 @@ public class CraftContainer extends AbstractContainerMenu { return inventory.getType(); } @@ -4017,7 +4010,7 @@ index a94bfca34ba87976a51c5572250059d393041f38..7d0d2cd4d34d6652eb45aa13442e1081 + @Override public String getTitle() { - return inventory instanceof CraftInventoryCustom ? ((CraftInventoryCustom.MinecraftInventory) ((CraftInventory) inventory).getInventory()).getTitle() : inventory.getType().getDefaultTitle(); + return title; diff --git a/src/main/java/org/bukkit/craftbukkit/inventory/CraftInventoryCustom.java b/src/main/java/org/bukkit/craftbukkit/inventory/CraftInventoryCustom.java index 6486a76466691f958349a4706d7c9caff9cb8f64..f3ebaefd949ae73afad3dcb69b8d9c632cc782f7 100644 --- a/src/main/java/org/bukkit/craftbukkit/inventory/CraftInventoryCustom.java @@ -4105,10 +4098,10 @@ index 6486a76466691f958349a4706d7c9caff9cb8f64..f3ebaefd949ae73afad3dcb69b8d9c63 return this.title; } diff --git a/src/main/java/org/bukkit/craftbukkit/inventory/CraftInventoryView.java b/src/main/java/org/bukkit/craftbukkit/inventory/CraftInventoryView.java -index 6a64fbb8b4937f39d5fdc2e2cbec26c83c74c486..7d6b5fdb00a5c1614849735634262a36a4efbd66 100644 +index 4dd9a80af9901287ab6740b072f2b89678c3d0cb..b2586684295b295a3196a2a9cf724cec975b5a40 100644 --- a/src/main/java/org/bukkit/craftbukkit/inventory/CraftInventoryView.java +++ b/src/main/java/org/bukkit/craftbukkit/inventory/CraftInventoryView.java -@@ -64,6 +64,13 @@ public class CraftInventoryView extends InventoryView { +@@ -73,6 +73,13 @@ public class CraftInventoryView extends InventoryView { return CraftItemStack.asCraftMirror(this.container.getSlot(slot).getItem()); } @@ -4121,7 +4114,7 @@ index 6a64fbb8b4937f39d5fdc2e2cbec26c83c74c486..7d6b5fdb00a5c1614849735634262a36 + @Override public String getTitle() { - return CraftChatMessage.fromComponent(this.container.getTitle()); + return this.title; diff --git a/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemFactory.java b/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemFactory.java index 309a0a7e26651a7a675326382df838b423830f33..eeb01a1b54e450f95b33864b030d2183d29309da 100644 --- a/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemFactory.java diff --git a/patches/server/0011-Paper-command.patch b/patches/server/0011-Paper-command.patch index 908f57d0d5..7121669847 100644 --- a/patches/server/0011-Paper-command.patch +++ b/patches/server/0011-Paper-command.patch @@ -615,10 +615,10 @@ index 1fe07773cf9664164b29164caba22800e5a6bdae..cb6f192c11cda6230ec365e6cefb44a3 this.setPvpAllowed(dedicatedserverproperties.pvp); diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index cb2dc6db887856c5f60d127f5999a0785702f2f4..52998bb6b10421283c2b374d2abff5d1253b4e4f 100644 +index 44f10adc1957436d9067657b95f04a12b9b7a867..df1058c8f3198fee567938b91021e253e9fbbf00 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -904,6 +904,7 @@ public final class CraftServer implements Server { +@@ -905,6 +905,7 @@ public final class CraftServer implements Server { this.commandMap.clearCommands(); this.reloadData(); org.spigotmc.SpigotConfig.registerCommands(); // Spigot @@ -626,7 +626,7 @@ index cb2dc6db887856c5f60d127f5999a0785702f2f4..52998bb6b10421283c2b374d2abff5d1 this.overrideAllCommandBlockCommands = this.commandsConfiguration.getStringList("command-block-overrides").contains("*"); this.ignoreVanillaPermissions = this.commandsConfiguration.getBoolean("ignore-vanilla-permissions"); -@@ -2436,6 +2437,34 @@ public final class CraftServer implements Server { +@@ -2437,6 +2438,34 @@ public final class CraftServer implements Server { // Spigot end // Paper start diff --git a/patches/server/0013-Paper-Plugins.patch b/patches/server/0013-Paper-Plugins.patch index 3fb6bf384d..20e8ed1d69 100644 --- a/patches/server/0013-Paper-Plugins.patch +++ b/patches/server/0013-Paper-Plugins.patch @@ -6750,10 +6750,10 @@ index aa054369cef3da4f90ce17788dcb9ca80dc98010..d9f2518a08bc4ae978051be51e467597 Bootstrap.validate(); Util.startTimerHackThread(); diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 52998bb6b10421283c2b374d2abff5d1253b4e4f..63e1ad046051ef60df339e3b9c14f73db0e0de21 100644 +index df1058c8f3198fee567938b91021e253e9fbbf00..2d112dd2ea808773e364396b26f04bca54a6fa37 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -263,7 +263,8 @@ public final class CraftServer implements Server { +@@ -264,7 +264,8 @@ public final class CraftServer implements Server { private final CraftCommandMap commandMap = new CraftCommandMap(this); private final SimpleHelpMap helpMap = new SimpleHelpMap(this); private final StandardMessenger messenger = new StandardMessenger(); @@ -6763,7 +6763,7 @@ index 52998bb6b10421283c2b374d2abff5d1253b4e4f..63e1ad046051ef60df339e3b9c14f73d private final StructureManager structureManager; protected final DedicatedServer console; protected final DedicatedPlayerList playerList; -@@ -411,24 +412,7 @@ public final class CraftServer implements Server { +@@ -412,24 +413,7 @@ public final class CraftServer implements Server { } public void loadPlugins() { @@ -6789,7 +6789,7 @@ index 52998bb6b10421283c2b374d2abff5d1253b4e4f..63e1ad046051ef60df339e3b9c14f73d } public void enablePlugins(PluginLoadOrder type) { -@@ -517,15 +501,17 @@ public final class CraftServer implements Server { +@@ -518,15 +502,17 @@ public final class CraftServer implements Server { private void enablePlugin(Plugin plugin) { try { List perms = plugin.getDescription().getPermissions(); @@ -6813,7 +6813,7 @@ index 52998bb6b10421283c2b374d2abff5d1253b4e4f..63e1ad046051ef60df339e3b9c14f73d this.pluginManager.enablePlugin(plugin); } catch (Throwable ex) { -@@ -928,6 +914,7 @@ public final class CraftServer implements Server { +@@ -929,6 +915,7 @@ public final class CraftServer implements Server { "This plugin is not properly shutting down its async tasks when it is being reloaded. This may cause conflicts with the newly loaded version of the plugin" )); } diff --git a/patches/server/0014-Timings-v2.patch b/patches/server/0014-Timings-v2.patch index ce32914b7e..372bbf2383 100644 --- a/patches/server/0014-Timings-v2.patch +++ b/patches/server/0014-Timings-v2.patch @@ -1270,10 +1270,10 @@ index aa164a81d072d9390fa1400120e801979e5d74d0..f2798373e7d07cc0e46c39297c29e7be 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 9116de00912e07dc049735a183719f6f8c2660b4..e9c8c008ce37ceec3be993e672786eaeb8d01a7e 100644 +index 531c8e74e7aa81a483650ec891a994ff7ff70a5c..26128f53ee00ab914e9ec84ef45edfbb48005ab0 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -338,7 +338,6 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -339,7 +339,6 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic @Override public void tick() { @@ -1281,7 +1281,7 @@ index 9116de00912e07dc049735a183719f6f8c2660b4..e9c8c008ce37ceec3be993e672786eae if (this.ackBlockChangesUpTo > -1) { this.send(new ClientboundBlockChangedAckPacket(this.ackBlockChangesUpTo)); this.ackBlockChangesUpTo = -1; -@@ -419,7 +418,6 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -420,7 +419,6 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic this.player.resetLastActionTime(); // CraftBukkit - SPIGOT-854 this.disconnect(Component.translatable("multiplayer.disconnect.idling")); } @@ -1289,7 +1289,7 @@ index 9116de00912e07dc049735a183719f6f8c2660b4..e9c8c008ce37ceec3be993e672786eae } -@@ -2138,7 +2136,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -2145,7 +2143,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic } private void handleCommand(String s) { @@ -1298,7 +1298,7 @@ index 9116de00912e07dc049735a183719f6f8c2660b4..e9c8c008ce37ceec3be993e672786eae if ( org.spigotmc.SpigotConfig.logCommands ) // Spigot this.LOGGER.info(this.player.getScoreboardName() + " issued server command: " + s); -@@ -2148,7 +2146,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -2155,7 +2153,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic this.cserver.getPluginManager().callEvent(event); if (event.isCancelled()) { @@ -1307,7 +1307,7 @@ index 9116de00912e07dc049735a183719f6f8c2660b4..e9c8c008ce37ceec3be993e672786eae return; } -@@ -2161,7 +2159,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -2168,7 +2166,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic java.util.logging.Logger.getLogger(ServerGamePacketListenerImpl.class.getName()).log(java.util.logging.Level.SEVERE, null, ex); return; } finally { @@ -1317,7 +1317,7 @@ index 9116de00912e07dc049735a183719f6f8c2660b4..e9c8c008ce37ceec3be993e672786eae } // 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 d00a2da03f8911f0e07ca22c8c569be7fc189842..53e85923c417cf4d853c27e6fedbe7ff525a897c 100644 +index 857ce5715e4ea68df2964a3f6595cdb8526cd32a..7e91d802f4b97f0ede734e2cedcf3a81cb06af6c 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 @@ @@ -1327,7 +1327,7 @@ index d00a2da03f8911f0e07ca22c8c569be7fc189842..53e85923c417cf4d853c27e6fedbe7ff import com.google.common.collect.Lists; import com.google.common.collect.Maps; import com.google.common.collect.Sets; -@@ -1037,10 +1038,11 @@ public abstract class PlayerList { +@@ -1039,10 +1040,11 @@ public abstract class PlayerList { } public void saveAll() { @@ -1341,7 +1341,7 @@ index d00a2da03f8911f0e07ca22c8c569be7fc189842..53e85923c417cf4d853c27e6fedbe7ff public UserWhiteList getWhiteList() { diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index 4cd1cfbf91ea232756de16120eec4339d8144885..9171dfb7443d42a5f6d854b2abea55d2671c1177 100644 +index 956c39b6d0c208366508f2064f7b98270eebaedc..e3b5c93f42a2ef01ecc9f1827802f3014ada3a34 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java @@ -134,7 +134,6 @@ import org.bukkit.craftbukkit.event.CraftPortalEvent; @@ -1352,7 +1352,7 @@ index 4cd1cfbf91ea232756de16120eec4339d8144885..9171dfb7443d42a5f6d854b2abea55d2 import org.bukkit.event.entity.EntityCombustByEntityEvent; import org.bukkit.event.hanging.HangingBreakByEntityEvent; import org.bukkit.event.vehicle.VehicleBlockCollisionEvent; -@@ -302,7 +301,6 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -303,7 +302,6 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { public boolean lastDamageCancelled; // SPIGOT-5339, SPIGOT-6252, SPIGOT-6777: Keep track if the event was canceled public boolean persistentInvisibility = false; public BlockPos lastLavaContact; @@ -1360,7 +1360,7 @@ index 4cd1cfbf91ea232756de16120eec4339d8144885..9171dfb7443d42a5f6d854b2abea55d2 // Spigot start public final org.spigotmc.ActivationRange.ActivationType activationType = org.spigotmc.ActivationRange.initializeEntityActivationType(this); public final boolean defaultActivationState; -@@ -752,7 +750,6 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -753,7 +751,6 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { } public void move(MoverType movementType, Vec3 movement) { @@ -1368,7 +1368,7 @@ index 4cd1cfbf91ea232756de16120eec4339d8144885..9171dfb7443d42a5f6d854b2abea55d2 if (this.noPhysics) { this.setPos(this.getX() + movement.x, this.getY() + movement.y, this.getZ() + movement.z); } else { -@@ -916,7 +913,6 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -917,7 +914,6 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { this.level.getProfiler().pop(); } } @@ -1632,10 +1632,10 @@ index 9c3ce492051199acb8d38ade121ec8a0cbc50f54..aa4f2dc63dd79e6c3d7594d2fd63fa00 }; } diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 63e1ad046051ef60df339e3b9c14f73db0e0de21..394d8631cb0a143cc7b5d71c919a8298652d5678 100644 +index 2d112dd2ea808773e364396b26f04bca54a6fa37..78d20c65ac8cb4e3467d0e14397a3c6dfefdc525 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -361,7 +361,7 @@ public final class CraftServer implements Server { +@@ -362,7 +362,7 @@ public final class CraftServer implements Server { this.saveCommandsConfig(); this.overrideAllCommandBlockCommands = this.commandsConfiguration.getStringList("command-block-overrides").contains("*"); this.ignoreVanillaPermissions = this.commandsConfiguration.getBoolean("ignore-vanilla-permissions"); @@ -1644,7 +1644,7 @@ index 63e1ad046051ef60df339e3b9c14f73db0e0de21..394d8631cb0a143cc7b5d71c919a8298 this.overrideSpawnLimits(); console.autosavePeriod = this.configuration.getInt("ticks-per.autosave"); this.warningState = WarningState.value(this.configuration.getString("settings.deprecated-verbose")); -@@ -2391,12 +2391,31 @@ public final class CraftServer implements Server { +@@ -2392,12 +2392,31 @@ public final class CraftServer implements Server { private final org.bukkit.Server.Spigot spigot = new org.bukkit.Server.Spigot() { @@ -1846,10 +1846,10 @@ index b0ffa23faf62629043dfd613315eaf9c5fcc2cfe..00000000000000000000000000000000 - } -} diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -index 8fcd46bef75b3d48356445575c4a6c1b93b61072..039f9b594bc7e3848b7f7a8ab66283baa78f28fa 100644 +index f1208e752cdab08228d790a5195114a62d16d399..f8667311662644ec85ed2af42cff739a8fdc290a 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -@@ -2523,6 +2523,14 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -2531,6 +2531,14 @@ public class CraftPlayer extends CraftHumanEntity implements Player { CraftPlayer.this.getHandle().connection.send(new net.minecraft.network.protocol.game.ClientboundSystemChatPacket(components, position == net.md_5.bungee.api.ChatMessageType.ACTION_BAR)); } diff --git a/patches/server/0018-Rewrite-chunk-system.patch b/patches/server/0018-Rewrite-chunk-system.patch index 6c00ac7753..3586b8765c 100644 --- a/patches/server/0018-Rewrite-chunk-system.patch +++ b/patches/server/0018-Rewrite-chunk-system.patch @@ -15915,10 +15915,10 @@ index e96a0ca47e4701ba187555bd92c968345bc85677..73b96f804079288e9c5fcc11da54e61e + // Paper end } diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index e9c8c008ce37ceec3be993e672786eaeb8d01a7e..542c6ebbf01b91709b73052eca3889347a5aa90a 100644 +index 26128f53ee00ab914e9ec84ef45edfbb48005ab0..5291581c87b65be72f482b4da1fccd33fa053591 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -779,6 +779,13 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -780,6 +780,13 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic this.disconnect(Component.translatable("disconnect.spam")); return; } @@ -15933,10 +15933,10 @@ index e9c8c008ce37ceec3be993e672786eaeb8d01a7e..542c6ebbf01b91709b73052eca388934 StringReader stringreader = new StringReader(packet.getCommand()); diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java -index 53e85923c417cf4d853c27e6fedbe7ff525a897c..cb365522a2b462e8c3e44eac68c64ad99c8738ff 100644 +index 7e91d802f4b97f0ede734e2cedcf3a81cb06af6c..d9f9aba11aa4ee40a3bfd09b4ad065b8ddd2d31e 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -253,7 +253,7 @@ public abstract class PlayerList { +@@ -255,7 +255,7 @@ public abstract class PlayerList { boolean flag1 = gamerules.getBoolean(GameRules.RULE_REDUCEDDEBUGINFO); // Spigot - view distance @@ -15945,7 +15945,7 @@ index 53e85923c417cf4d853c27e6fedbe7ff525a897c..cb365522a2b462e8c3e44eac68c64ad9 player.getBukkitEntity().sendSupportedChannels(); // CraftBukkit playerconnection.send(new ClientboundUpdateEnabledFeaturesPacket(FeatureFlags.REGISTRY.toNames(worldserver1.enabledFeatures()))); playerconnection.send(new ClientboundCustomPayloadPacket(ClientboundCustomPayloadPacket.BRAND, (new FriendlyByteBuf(Unpooled.buffer())).writeUtf(this.getServer().getServerModName()))); -@@ -791,8 +791,8 @@ public abstract class PlayerList { +@@ -793,8 +793,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(), (byte) i, entityplayer1.getLastDeathLocation())); @@ -15955,8 +15955,8 @@ index 53e85923c417cf4d853c27e6fedbe7ff525a897c..cb365522a2b462e8c3e44eac68c64ad9 + entityplayer1.connection.send(new ClientboundSetSimulationDistancePacket(worldserver1.getChunkSource().chunkMap.playerChunkManager.getTargetTickViewDistance())); // Spigot // Paper - replace old player chunk management entityplayer1.spawnIn(worldserver1); entityplayer1.unsetRemoved(); - entityplayer1.connection.teleport(new Location(worldserver1.getWorld(), entityplayer1.getX(), entityplayer1.getY(), entityplayer1.getZ(), entityplayer1.getYRot(), entityplayer1.getXRot())); -@@ -1288,7 +1288,7 @@ public abstract class PlayerList { + entityplayer1.connection.teleport(CraftLocation.toBukkit(entityplayer1.position(), worldserver1.getWorld(), entityplayer1.getYRot(), entityplayer1.getXRot())); +@@ -1290,7 +1290,7 @@ public abstract class PlayerList { public void setViewDistance(int viewDistance) { this.viewDistance = viewDistance; @@ -15965,7 +15965,7 @@ index 53e85923c417cf4d853c27e6fedbe7ff525a897c..cb365522a2b462e8c3e44eac68c64ad9 Iterator iterator = this.server.getAllLevels().iterator(); while (iterator.hasNext()) { -@@ -1303,7 +1303,7 @@ public abstract class PlayerList { +@@ -1305,7 +1305,7 @@ public abstract class PlayerList { public void setSimulationDistance(int simulationDistance) { this.simulationDistance = simulationDistance; @@ -16069,10 +16069,10 @@ index 12e72ad737b1219fcdf88d344d41621d9fd5feec..e0bfeebeaac1aaea64bc07cdfdf7790e if (flag1) { ++this.converted; diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index 9171dfb7443d42a5f6d854b2abea55d2671c1177..8a9700d8bbfe2f813259543ed4167495d13e1b4f 100644 +index e3b5c93f42a2ef01ecc9f1827802f3014ada3a34..dc20ca25f17a6a9b24833e181344dc666be7d424 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -322,6 +322,58 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -323,6 +323,58 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { } // Paper end @@ -16131,7 +16131,7 @@ index 9171dfb7443d42a5f6d854b2abea55d2671c1177..8a9700d8bbfe2f813259543ed4167495 public Entity(EntityType type, Level world) { this.id = Entity.ENTITY_COUNTER.incrementAndGet(); this.passengers = ImmutableList.of(); -@@ -2136,11 +2188,11 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -2137,11 +2189,11 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { return InteractionResult.PASS; } @@ -16145,7 +16145,7 @@ index 9171dfb7443d42a5f6d854b2abea55d2671c1177..8a9700d8bbfe2f813259543ed4167495 return false; } -@@ -3442,6 +3494,16 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -3443,6 +3495,16 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { }; } @@ -16162,7 +16162,7 @@ index 9171dfb7443d42a5f6d854b2abea55d2671c1177..8a9700d8bbfe2f813259543ed4167495 public boolean hasExactlyOnePlayerPassenger() { return this.getIndirectPassengersStream().filter((entity) -> { return entity instanceof Player; -@@ -3769,6 +3831,12 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -3770,6 +3832,12 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { } public final void setPosRaw(double x, double y, double z) { @@ -16175,7 +16175,7 @@ index 9171dfb7443d42a5f6d854b2abea55d2671c1177..8a9700d8bbfe2f813259543ed4167495 if (this.position.x != x || this.position.y != y || this.position.z != z) { this.position = new Vec3(x, y, z); int i = Mth.floor(x); -@@ -3876,6 +3944,13 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -3877,6 +3945,13 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { @Override public final void setRemoved(Entity.RemovalReason reason) { @@ -16189,7 +16189,7 @@ index 9171dfb7443d42a5f6d854b2abea55d2671c1177..8a9700d8bbfe2f813259543ed4167495 if (this.removalReason == null) { this.removalReason = reason; } -@@ -3884,7 +3959,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -3885,7 +3960,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { this.stopRiding(); } @@ -16198,7 +16198,7 @@ index 9171dfb7443d42a5f6d854b2abea55d2671c1177..8a9700d8bbfe2f813259543ed4167495 this.levelCallback.onRemove(reason); } -@@ -3899,7 +3974,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -3900,7 +3975,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { @Override public boolean shouldBeSaved() { @@ -17781,7 +17781,7 @@ index 9f6c2e5b5d9e8d714a47c770e255d06c0ef7c190..ac807277a6b26d140ea9873d17c7aa4f for(SavedTick savedTick : this.pendingTicks) { diff --git a/src/main/java/org/bukkit/craftbukkit/CraftChunk.java b/src/main/java/org/bukkit/craftbukkit/CraftChunk.java -index 60907cc435004398c46381b7b32bf47fe8938736..317bf725767e7dc8b916eeb8cd5bcd30ac219aaa 100644 +index bf4b2f89d3a7133155c6272379c742318b2c1514..33677ec811ceab939c419bf7d31b99585e9a1ef1 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftChunk.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftChunk.java @@ -111,7 +111,7 @@ public class CraftChunk implements Chunk { @@ -17847,10 +17847,10 @@ index 60907cc435004398c46381b7b32bf47fe8938736..317bf725767e7dc8b916eeb8cd5bcd30 @Override diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 394d8631cb0a143cc7b5d71c919a8298652d5678..cd667805a4ace3edc88a8ff11369fd169e5614e3 100644 +index 78d20c65ac8cb4e3467d0e14397a3c6dfefdc525..e6193b5403d4cb762f702b45ca7c07d5f64d8218 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -1124,7 +1124,7 @@ public final class CraftServer implements Server { +@@ -1125,7 +1125,7 @@ public final class CraftServer implements Server { this.console.addLevel(internal); this.getServer().prepareLevels(internal.getChunkSource().chunkMap.progressListener, internal); @@ -17859,7 +17859,7 @@ index 394d8631cb0a143cc7b5d71c919a8298652d5678..cd667805a4ace3edc88a8ff11369fd16 this.pluginManager.callEvent(new WorldLoadEvent(internal.getWorld())); return internal.getWorld(); -@@ -1168,7 +1168,7 @@ public final class CraftServer implements Server { +@@ -1169,7 +1169,7 @@ public final class CraftServer implements Server { } handle.getChunkSource().close(save); @@ -17868,7 +17868,7 @@ index 394d8631cb0a143cc7b5d71c919a8298652d5678..cd667805a4ace3edc88a8ff11369fd16 handle.convertable.close(); } catch (Exception ex) { this.getLogger().log(Level.SEVERE, null, ex); -@@ -1987,7 +1987,7 @@ public final class CraftServer implements Server { +@@ -1988,7 +1988,7 @@ public final class CraftServer implements Server { @Override public boolean isPrimaryThread() { @@ -17878,10 +17878,10 @@ index 394d8631cb0a143cc7b5d71c919a8298652d5678..cd667805a4ace3edc88a8ff11369fd16 // Paper start diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -index 4186943ba9e94758d579477e8fadaf8e05ef93f3..1684b3ee1b51597e799486bbe129b344a9fe3098 100644 +index 2f83e56b59407dc388240676ae5cfd73de2a9066..55b560a5a0dc74a29533eb6fb3cd11f6c7ee4258 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -@@ -325,10 +325,14 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -321,10 +321,14 @@ public class CraftWorld extends CraftRegionAccessor implements World { ChunkHolder playerChunk = this.world.getChunkSource().chunkMap.getVisibleChunkIfPresent(ChunkPos.asLong(x, z)); if (playerChunk == null) return false; @@ -17899,7 +17899,7 @@ index 4186943ba9e94758d579477e8fadaf8e05ef93f3..1684b3ee1b51597e799486bbe129b344 ClientboundLevelChunkWithLightPacket refreshPacket = new ClientboundLevelChunkWithLightPacket(chunk, this.world.getLightEngine(), null, null, true); for (ServerPlayer player : playersInRange) { -@@ -336,8 +340,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -332,8 +336,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { player.connection.send(refreshPacket); } @@ -17909,7 +17909,7 @@ index 4186943ba9e94758d579477e8fadaf8e05ef93f3..1684b3ee1b51597e799486bbe129b344 return true; } -@@ -414,20 +417,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -410,20 +413,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { @Override public Collection getPluginChunkTickets(int x, int z) { DistanceManager chunkDistanceManager = this.world.getChunkSource().chunkMap.distanceManager; @@ -17931,7 +17931,7 @@ index 4186943ba9e94758d579477e8fadaf8e05ef93f3..1684b3ee1b51597e799486bbe129b344 } @Override -@@ -435,7 +425,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -431,7 +421,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { Map> ret = new HashMap<>(); DistanceManager chunkDistanceManager = this.world.getChunkSource().chunkMap.distanceManager; @@ -17940,7 +17940,7 @@ index 4186943ba9e94758d579477e8fadaf8e05ef93f3..1684b3ee1b51597e799486bbe129b344 long chunkKey = chunkTickets.getLongKey(); SortedArraySet> tickets = chunkTickets.getValue(); -@@ -1931,14 +1921,53 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -1917,14 +1907,53 @@ public class CraftWorld extends CraftRegionAccessor implements World { // Spigot start @Override public int getViewDistance() { @@ -17997,10 +17997,10 @@ index 4186943ba9e94758d579477e8fadaf8e05ef93f3..1684b3ee1b51597e799486bbe129b344 // Spigot start private final org.bukkit.World.Spigot spigot = new org.bukkit.World.Spigot() diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -index 039f9b594bc7e3848b7f7a8ab66283baa78f28fa..62709a16dc1c55a026bfbd049f07c29479cb3940 100644 +index f8667311662644ec85ed2af42cff739a8fdc290a..bfd61549b3df0885a03276a2acfc798f078e3245 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -@@ -178,6 +178,81 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -182,6 +182,81 @@ public class CraftPlayer extends CraftHumanEntity implements Player { this.firstPlayed = System.currentTimeMillis(); } diff --git a/patches/server/0019-Add-command-line-option-to-load-extra-plugin-jars-no.patch b/patches/server/0019-Add-command-line-option-to-load-extra-plugin-jars-no.patch index 5f1f11c659..fd60b50555 100644 --- a/patches/server/0019-Add-command-line-option-to-load-extra-plugin-jars-no.patch +++ b/patches/server/0019-Add-command-line-option-to-load-extra-plugin-jars-no.patch @@ -7,10 +7,10 @@ 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/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index cfae708f784546be04e4cedbc707c7b35aa40a46..b9eae8760a642ab5a38980787dde045a3c08046d 100644 +index e6193b5403d4cb762f702b45ca7c07d5f64d8218..401a0976af9f911d1ddcc24b77505dba2665a65f 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -415,6 +415,35 @@ public final class CraftServer implements Server { +@@ -416,6 +416,35 @@ public final class CraftServer implements Server { io.papermc.paper.plugin.entrypoint.LaunchEntryPointHandler.INSTANCE.enter(io.papermc.paper.plugin.entrypoint.Entrypoint.PLUGIN); // Paper - replace implementation } @@ -47,7 +47,7 @@ index cfae708f784546be04e4cedbc707c7b35aa40a46..b9eae8760a642ab5a38980787dde045a if (type == PluginLoadOrder.STARTUP) { this.helpMap.clear(); diff --git a/src/main/java/org/bukkit/craftbukkit/Main.java b/src/main/java/org/bukkit/craftbukkit/Main.java -index 6569c9db3fa026ee4fbfaceac0e4f6a15c1fbe16..0cbabd6ffc7bbc9494c1a0d631567fae828fb045 100644 +index 4e7208a891da461a10920482e4e4427ace23fb45..a1dc92c7fc48a0fafc14c254b0c0b93afd6481e4 100644 --- a/src/main/java/org/bukkit/craftbukkit/Main.java +++ b/src/main/java/org/bukkit/craftbukkit/Main.java @@ -159,6 +159,12 @@ public class Main { diff --git a/patches/server/0022-Configurable-fishing-time-ranges.patch b/patches/server/0022-Configurable-fishing-time-ranges.patch index 638654374d..e0fa197128 100644 --- a/patches/server/0022-Configurable-fishing-time-ranges.patch +++ b/patches/server/0022-Configurable-fishing-time-ranges.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Configurable fishing time ranges diff --git a/src/main/java/net/minecraft/world/entity/projectile/FishingHook.java b/src/main/java/net/minecraft/world/entity/projectile/FishingHook.java -index 5a5086e2d819c2172ea4d0c43bd9a5543da6ae87..d9a01dbd9bcdf634b906b369222e6e7ba90dc7c5 100644 +index b202a522606b9335ebab1c21a2c50fb5f7e9791b..9a753ffd35403358df07408ffe85197ee3318f39 100644 --- a/src/main/java/net/minecraft/world/entity/projectile/FishingHook.java +++ b/src/main/java/net/minecraft/world/entity/projectile/FishingHook.java -@@ -86,6 +86,10 @@ public class FishingHook extends Projectile { +@@ -92,6 +92,10 @@ public class FishingHook extends Projectile { this.noCulling = true; this.luck = Math.max(0, luckOfTheSeaLevel); this.lureSpeed = Math.max(0, lureLevel); @@ -19,7 +19,7 @@ index 5a5086e2d819c2172ea4d0c43bd9a5543da6ae87..d9a01dbd9bcdf634b906b369222e6e7b } public FishingHook(EntityType type, Level world) { -@@ -401,7 +405,7 @@ public class FishingHook extends Projectile { +@@ -409,7 +413,7 @@ public class FishingHook extends Projectile { } else { // CraftBukkit start - logic to modify fishing wait time this.timeUntilLured = Mth.nextInt(this.random, this.minWaitTime, this.maxWaitTime); diff --git a/patches/server/0027-Show-Paper-in-client-crashes-server-lists-and-Mojang.patch b/patches/server/0027-Show-Paper-in-client-crashes-server-lists-and-Mojang.patch index 8678dcd61c..88cb13820c 100644 --- a/patches/server/0027-Show-Paper-in-client-crashes-server-lists-and-Mojang.patch +++ b/patches/server/0027-Show-Paper-in-client-crashes-server-lists-and-Mojang.patch @@ -19,10 +19,10 @@ index 6251d93c2ea61c471b4e1069048327782acc78e7..d3cd196e1a6f707ed5e0008123cc65df public SystemReport fillSystemReport(SystemReport details) { diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index e80510f14b9007afebf76110b936f1b5c29078d6..5e79baa09e3ae468a58b0f2e5f9e08c67fcd7ff8 100644 +index 401a0976af9f911d1ddcc24b77505dba2665a65f..86480565d736e47e9f0c59c80b1242a5589d0f6f 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -254,7 +254,7 @@ import org.yaml.snakeyaml.error.MarkedYAMLException; +@@ -255,7 +255,7 @@ import org.yaml.snakeyaml.error.MarkedYAMLException; import net.md_5.bungee.api.chat.BaseComponent; // Spigot public final class CraftServer implements Server { @@ -32,11 +32,11 @@ index e80510f14b9007afebf76110b936f1b5c29078d6..5e79baa09e3ae468a58b0f2e5f9e08c6 private final String bukkitVersion = Versioning.getBukkitVersion(); private final Logger logger = Logger.getLogger("Minecraft"); diff --git a/src/main/java/org/bukkit/craftbukkit/Main.java b/src/main/java/org/bukkit/craftbukkit/Main.java -index 7252677bd6dabe094bfc9d47882059b9cb86e791..e318b381e9d66fa83a6481f55d17fe5dcbb277ba 100644 +index a1dc92c7fc48a0fafc14c254b0c0b93afd6481e4..f5554fe1aac5e68c2956989e8629d642c473ffa3 100644 --- a/src/main/java/org/bukkit/craftbukkit/Main.java +++ b/src/main/java/org/bukkit/craftbukkit/Main.java @@ -233,12 +233,25 @@ public class Main { - deadline.add(Calendar.DAY_OF_YEAR, -7); + deadline.add(Calendar.DAY_OF_YEAR, -21); if (buildDate.before(deadline.getTime())) { System.err.println("*** Error, this build is outdated ***"); - System.err.println("*** Please download a new build as per instructions from https://www.spigotmc.org/go/outdated-spigot ***"); diff --git a/patches/server/0030-Player-affects-spawning-API.patch b/patches/server/0030-Player-affects-spawning-API.patch index b7edcd5b0f..4f81895266 100644 --- a/patches/server/0030-Player-affects-spawning-API.patch +++ b/patches/server/0030-Player-affects-spawning-API.patch @@ -137,10 +137,10 @@ index be6e3e21ad62da01e5e2dd78e300cbc8efdbeb42..ea98625fe7c00743b8df74a24e6d4b75 for(Player player : this.players()) { if (EntitySelector.NO_SPECTATORS.test(player) && EntitySelector.LIVING_ENTITY_STILL_ALIVE.test(player)) { diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -index 62709a16dc1c55a026bfbd049f07c29479cb3940..98fafd85a08338cf621fd9d0da40dab7b883c7d6 100644 +index bfd61549b3df0885a03276a2acfc798f078e3245..910f95f29c033b8d7adce705eae170235acf427e 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -@@ -2228,8 +2228,20 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -2236,8 +2236,20 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @Override public String getLocale() { return this.getHandle().locale; diff --git a/patches/server/0031-Further-improve-server-tick-loop.patch b/patches/server/0031-Further-improve-server-tick-loop.patch index 68cbe29026..b80e2e9749 100644 --- a/patches/server/0031-Further-improve-server-tick-loop.patch +++ b/patches/server/0031-Further-improve-server-tick-loop.patch @@ -145,10 +145,10 @@ index d3cd196e1a6f707ed5e0008123cc65df80422859..a7f9a3e57c7736b065b8dc4dba6e018c this.startMetricsRecordingTick(); this.profiler.push("tick"); diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 5e79baa09e3ae468a58b0f2e5f9e08c67fcd7ff8..77b8b4d56883dcf672af82189da75ddef7c935a2 100644 +index 86480565d736e47e9f0c59c80b1242a5589d0f6f..4a8aa6dcc8c359c12eadf87d1194cac4919ec2ae 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -2416,6 +2416,17 @@ public final class CraftServer implements Server { +@@ -2417,6 +2417,17 @@ public final class CraftServer implements Server { return CraftMagicNumbers.INSTANCE; } diff --git a/patches/server/0032-Only-refresh-abilities-if-needed.patch b/patches/server/0032-Only-refresh-abilities-if-needed.patch index 021d5e43c1..f849607b54 100644 --- a/patches/server/0032-Only-refresh-abilities-if-needed.patch +++ b/patches/server/0032-Only-refresh-abilities-if-needed.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Only refresh abilities if needed diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -index 98fafd85a08338cf621fd9d0da40dab7b883c7d6..932dddf8f761efde723b27e9d86c326b7fc5b4da 100644 +index 910f95f29c033b8d7adce705eae170235acf427e..617e504e6d19325a03875fc09eda80014d933724 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -@@ -1897,12 +1897,13 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -1905,12 +1905,13 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @Override public void setFlying(boolean value) { diff --git a/patches/server/0033-Entity-Origin-API.patch b/patches/server/0033-Entity-Origin-API.patch index 9d8a517097..0d17921bed 100644 --- a/patches/server/0033-Entity-Origin-API.patch +++ b/patches/server/0033-Entity-Origin-API.patch @@ -25,10 +25,10 @@ index fb7930009db2c219347e6601ca2cde0c8601e2b4..26cc626ad0c5328c20f7ef20e8e270c9 public void onTrackingEnd(Entity entity) { diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index 8a9700d8bbfe2f813259543ed4167495d13e1b4f..cc46ddc81724ea344d09fa75936fae869e396a02 100644 +index dc20ca25f17a6a9b24833e181344dc666be7d424..5fb5e97c7480eea1592b80f8d8e4c4febbb6faa8 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -307,7 +307,27 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -308,7 +308,27 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { public long activatedTick = Integer.MIN_VALUE; public void inactiveTick() { } // Spigot end @@ -56,7 +56,7 @@ index 8a9700d8bbfe2f813259543ed4167495d13e1b4f..cc46ddc81724ea344d09fa75936fae86 public float getBukkitYaw() { return this.yRot; } -@@ -1942,6 +1962,15 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -1943,6 +1963,15 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { this.bukkitEntity.storeBukkitValues(nbt); } // CraftBukkit end @@ -72,7 +72,7 @@ index 8a9700d8bbfe2f813259543ed4167495d13e1b4f..cc46ddc81724ea344d09fa75936fae86 return nbt; } catch (Throwable throwable) { CrashReport crashreport = CrashReport.forThrowable(throwable, "Saving entity NBT"); -@@ -2069,6 +2098,20 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -2070,6 +2099,20 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { } // CraftBukkit end @@ -94,7 +94,7 @@ index 8a9700d8bbfe2f813259543ed4167495d13e1b4f..cc46ddc81724ea344d09fa75936fae86 CrashReport crashreport = CrashReport.forThrowable(throwable, "Loading entity NBT"); CrashReportCategory crashreportsystemdetails = crashreport.addCategory("Entity being loaded"); diff --git a/src/main/java/net/minecraft/world/entity/item/FallingBlockEntity.java b/src/main/java/net/minecraft/world/entity/item/FallingBlockEntity.java -index 88ea09b2f1c33e9fb528aad1564ae858c3c8b064..5e93e55df24941a21721295ef8a3381ae19e1f26 100644 +index 4051c7ea5f3ac70df2329c6f6938dff076206797..ef29262fd2f51c6d90e2bb01fbf843a1a1d5043d 100644 --- a/src/main/java/net/minecraft/world/entity/item/FallingBlockEntity.java +++ b/src/main/java/net/minecraft/world/entity/item/FallingBlockEntity.java @@ -340,6 +340,14 @@ public class FallingBlockEntity extends Entity { @@ -132,7 +132,7 @@ index c133d51a363900164c1492359be5b1579806d5cb..ab5817df2c98d24ee627fd5cf1f71e40 @Nullable diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java -index 17c914088b467007aada17e3b2238a9c76fb532b..7a3ae4daa0f1f8dd2dd200fbfa1010f70f4b1f91 100644 +index 2849f70314f1cd8aeac38c8ab37d293732d4504c..3a0d2613bc84659f9c618e20f3af27e75538331f 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java @@ -1252,5 +1252,20 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity { 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 e3f3ac2e24..d06d473f2c 100644 --- a/patches/server/0035-Configurable-top-of-nether-void-damage.patch +++ b/patches/server/0035-Configurable-top-of-nether-void-damage.patch @@ -6,10 +6,10 @@ 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 3cc8426283f68db0a4cbda6934aa6bfde7663e42..28704015f17da94d8cb063af70bf4aca83d6eed7 100644 +index 5fb5e97c7480eea1592b80f8d8e4c4febbb6faa8..e660773a2b0da661e151559f9bf988c4cb148a77 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -708,7 +708,11 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -709,7 +709,11 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { } public void checkOutOfWorld() { diff --git a/patches/server/0038-Configurable-end-credits.patch b/patches/server/0038-Configurable-end-credits.patch index 96bbbd7686..21f1d38435 100644 --- a/patches/server/0038-Configurable-end-credits.patch +++ b/patches/server/0038-Configurable-end-credits.patch @@ -5,10 +5,10 @@ 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 7e4c10bfdaf1e7f2dfc03d220e5c731927b0b5f9..edb8537e4fdd82991eda914a7d5c3ff6ef773fe0 100644 +index 8105a30251c45b4ab111c97d34029c66180922fd..0d06bb85f2c81331dcf5cccde31c650a7c46f0b9 100644 --- a/src/main/java/net/minecraft/server/level/ServerPlayer.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java -@@ -1023,6 +1023,7 @@ public class ServerPlayer extends Player { +@@ -1025,6 +1025,7 @@ public class ServerPlayer extends Player { this.unRide(); this.getLevel().removePlayerImmediately(this, Entity.RemovalReason.CHANGED_DIMENSION); if (!this.wonGame) { diff --git a/patches/server/0040-Optimize-explosions.patch b/patches/server/0040-Optimize-explosions.patch index f35738271f..8c280d9053 100644 --- a/patches/server/0040-Optimize-explosions.patch +++ b/patches/server/0040-Optimize-explosions.patch @@ -22,7 +22,7 @@ index a7f9a3e57c7736b065b8dc4dba6e018ce73e5157..1554f8847e42cdd584b16c0648c21c40 this.profiler.popPush("connection"); diff --git a/src/main/java/net/minecraft/world/level/Explosion.java b/src/main/java/net/minecraft/world/level/Explosion.java -index 594ac935ae8f77fc16be90ac178581cbdfc65eb7..d21422dfac366037398101626d7d33640725f018 100644 +index 8752dee5dc0ed1c2d81994b627aa187049a3cd7d..65168326eb92dbd45e7b992a34f69aaa12d3e8ff 100644 --- a/src/main/java/net/minecraft/world/level/Explosion.java +++ b/src/main/java/net/minecraft/world/level/Explosion.java @@ -221,7 +221,7 @@ public class Explosion { @@ -34,7 +34,7 @@ index 594ac935ae8f77fc16be90ac178581cbdfc65eb7..d21422dfac366037398101626d7d3364 double d13 = (1.0D - d7) * d12; // CraftBukkit start -@@ -503,4 +503,84 @@ public class Explosion { +@@ -513,4 +513,84 @@ public class Explosion { private BlockInteraction() {} } diff --git a/patches/server/0045-Implement-PlayerLocaleChangeEvent.patch b/patches/server/0045-Implement-PlayerLocaleChangeEvent.patch index d0301b277e..e4729c6ec4 100644 --- a/patches/server/0045-Implement-PlayerLocaleChangeEvent.patch +++ b/patches/server/0045-Implement-PlayerLocaleChangeEvent.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Implement PlayerLocaleChangeEvent diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java -index edb8537e4fdd82991eda914a7d5c3ff6ef773fe0..e1b545cda20f5f165497b751044ff323c7827313 100644 +index 0d06bb85f2c81331dcf5cccde31c650a7c46f0b9..10660cd8df20269f07726af53dc07fa7d9880807 100644 --- a/src/main/java/net/minecraft/server/level/ServerPlayer.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java -@@ -1806,7 +1806,7 @@ public class ServerPlayer extends Player { +@@ -1808,7 +1808,7 @@ public class ServerPlayer extends Player { } } @@ -17,7 +17,7 @@ index edb8537e4fdd82991eda914a7d5c3ff6ef773fe0..e1b545cda20f5f165497b751044ff323 public java.util.Locale adventure$locale = java.util.Locale.US; // Paper public void updateOptions(ServerboundClientInformationPacket packet) { // CraftBukkit start -@@ -1814,9 +1814,10 @@ public class ServerPlayer extends Player { +@@ -1816,9 +1816,10 @@ public class ServerPlayer extends Player { PlayerChangedMainHandEvent event = new PlayerChangedMainHandEvent(this.getBukkitEntity(), getMainArm() == HumanoidArm.LEFT ? MainHand.LEFT : MainHand.RIGHT); this.server.server.getPluginManager().callEvent(event); } @@ -30,10 +30,10 @@ index edb8537e4fdd82991eda914a7d5c3ff6ef773fe0..e1b545cda20f5f165497b751044ff323 this.locale = packet.language; // Paper start diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -index 932dddf8f761efde723b27e9d86c326b7fc5b4da..1e809180b8d06c01eeeb98cbe738ad1cc41b7a18 100644 +index 617e504e6d19325a03875fc09eda80014d933724..dcadf816cfe7e4a54261b936ceb1684b9d6bec17 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -@@ -2228,8 +2228,10 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -2236,8 +2236,10 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @Override public String getLocale() { diff --git a/patches/server/0047-Configurable-container-update-tick-rate.patch b/patches/server/0047-Configurable-container-update-tick-rate.patch index f21251f4d1..22da87ba81 100644 --- a/patches/server/0047-Configurable-container-update-tick-rate.patch +++ b/patches/server/0047-Configurable-container-update-tick-rate.patch @@ -5,10 +5,10 @@ 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 e1b545cda20f5f165497b751044ff323c7827313..fc364823f20f458af936c7209bd7174e05cb0fc0 100644 +index 10660cd8df20269f07726af53dc07fa7d9880807..fef0ce65c01fd56a0ed62de27e8d8457324bb295 100644 --- a/src/main/java/net/minecraft/server/level/ServerPlayer.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java -@@ -239,6 +239,7 @@ public class ServerPlayer extends Player { +@@ -241,6 +241,7 @@ public class ServerPlayer extends Player { private int containerCounter; public int latency; public boolean wonGame; @@ -16,7 +16,7 @@ index e1b545cda20f5f165497b751044ff323c7827313..fc364823f20f458af936c7209bd7174e // CraftBukkit start public String displayName; -@@ -629,7 +630,12 @@ public class ServerPlayer extends Player { +@@ -631,7 +632,12 @@ public class ServerPlayer extends Player { --this.invulnerableTime; } diff --git a/patches/server/0050-Add-PlayerInitialSpawnEvent.patch b/patches/server/0050-Add-PlayerInitialSpawnEvent.patch index 1ac60afa8a..f3e83ec3a2 100644 --- a/patches/server/0050-Add-PlayerInitialSpawnEvent.patch +++ b/patches/server/0050-Add-PlayerInitialSpawnEvent.patch @@ -12,10 +12,10 @@ 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 cb365522a2b462e8c3e44eac68c64ad99c8738ff..c416b0c670d5c1f43d5b2a097e068bc51a6c660d 100644 +index d9f9aba11aa4ee40a3bfd09b4ad065b8ddd2d31e..57281d4a3c6b187d13ba5cadd46f494df411e7ba 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -231,7 +231,7 @@ public abstract class PlayerList { +@@ -233,7 +233,7 @@ public abstract class PlayerList { // Spigot start - spawn location event Player spawnPlayer = player.getBukkitEntity(); @@ -24,7 +24,7 @@ index cb365522a2b462e8c3e44eac68c64ad99c8738ff..c416b0c670d5c1f43d5b2a097e068bc5 this.cserver.getPluginManager().callEvent(ev); Location loc = ev.getSpawnLocation(); -@@ -239,7 +239,10 @@ public abstract class PlayerList { +@@ -241,7 +241,10 @@ public abstract class PlayerList { player.spawnIn(worldserver1); player.gameMode.setLevel((ServerLevel) player.level); diff --git a/patches/server/0052-Ensure-commands-are-not-ran-async.patch b/patches/server/0052-Ensure-commands-are-not-ran-async.patch index 71c3cd93b1..ac0013efd4 100644 --- a/patches/server/0052-Ensure-commands-are-not-ran-async.patch +++ b/patches/server/0052-Ensure-commands-are-not-ran-async.patch @@ -21,10 +21,10 @@ character. Co-authored-by: Jake Potrebic diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 542c6ebbf01b91709b73052eca3889347a5aa90a..0da739370a9cbbde1f2bec8d04a6ab6f6971017d 100644 +index 5291581c87b65be72f482b4da1fccd33fa053591..dae74cda3b9faa0c8aeecc6c7bc329950033f653 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -2035,7 +2035,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -2042,7 +2042,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic return true; } @@ -33,7 +33,7 @@ index 542c6ebbf01b91709b73052eca3889347a5aa90a..0da739370a9cbbde1f2bec8d04a6ab6f for (int i = 0; i < message.length(); ++i) { if (!SharedConstants.isAllowedChatCharacter(message.charAt(i))) { return true; -@@ -2052,7 +2052,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -2059,7 +2059,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic } OutgoingChatMessage outgoing = OutgoingChatMessage.create(original); @@ -42,7 +42,7 @@ index 542c6ebbf01b91709b73052eca3889347a5aa90a..0da739370a9cbbde1f2bec8d04a6ab6f this.handleCommand(s); } else if (this.player.getChatVisibility() == ChatVisiblity.SYSTEM) { // Do nothing, this is coming from a plugin -@@ -2142,7 +2142,29 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -2149,7 +2149,29 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic } } @@ -74,10 +74,10 @@ index 542c6ebbf01b91709b73052eca3889347a5aa90a..0da739370a9cbbde1f2bec8d04a6ab6f if ( org.spigotmc.SpigotConfig.logCommands ) // Spigot this.LOGGER.info(this.player.getScoreboardName() + " issued server command: " + s); diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 77b8b4d56883dcf672af82189da75ddef7c935a2..af2d401c3faa14664732c001a1ea59f61683374e 100644 +index 4a8aa6dcc8c359c12eadf87d1194cac4919ec2ae..080afe93a303626254d737dac1222736587a53c3 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -852,6 +852,28 @@ public final class CraftServer implements Server { +@@ -853,6 +853,28 @@ public final class CraftServer implements Server { Validate.notNull(commandLine, "CommandLine cannot be null"); org.spigotmc.AsyncCatcher.catchOp("command dispatch"); // Spigot @@ -107,10 +107,10 @@ index 77b8b4d56883dcf672af82189da75ddef7c935a2..af2d401c3faa14664732c001a1ea59f6 return true; } diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -index 1e809180b8d06c01eeeb98cbe738ad1cc41b7a18..83407b6149507709d92396f285ac348af95f9034 100644 +index dcadf816cfe7e4a54261b936ceb1684b9d6bec17..859637f7a5eca51db5a880a06355f1fc601bc266 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -@@ -506,7 +506,20 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -510,7 +510,20 @@ public class CraftPlayer extends CraftHumanEntity implements Player { public void chat(String msg) { if (this.getHandle().connection == null) return; diff --git a/patches/server/0054-Expose-server-CommandMap.patch b/patches/server/0054-Expose-server-CommandMap.patch index 78c730394a..372de181ad 100644 --- a/patches/server/0054-Expose-server-CommandMap.patch +++ b/patches/server/0054-Expose-server-CommandMap.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Expose server CommandMap diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index a8a9e109b11d124a2018857d0d13c1aacabfa37a..3a62e416e5d67bff401d5d8fd7e794c213997ae4 100644 +index 080afe93a303626254d737dac1222736587a53c3..5674691d0f4c8b0a4c4255476d3d156b08225206 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -1991,6 +1991,7 @@ public final class CraftServer implements Server { +@@ -1992,6 +1992,7 @@ public final class CraftServer implements Server { return this.helpMap; } diff --git a/patches/server/0056-Player-Tab-List-and-Title-APIs.patch b/patches/server/0056-Player-Tab-List-and-Title-APIs.patch index 4f97d1936a..d80aa181a2 100644 --- a/patches/server/0056-Player-Tab-List-and-Title-APIs.patch +++ b/patches/server/0056-Player-Tab-List-and-Title-APIs.patch @@ -63,7 +63,7 @@ index bd808eb312ade7122973a47f4b96505829511da5..bf0f9cab7c66c089f35b851e799ba4a4 // Paper end buf.writeComponent(this.text); diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -index 83407b6149507709d92396f285ac348af95f9034..1f6bb1e5a277174e299d548daf7f6798ff7b7f35 100644 +index 859637f7a5eca51db5a880a06355f1fc601bc266..f1c73e221a0fc0cb24076171b69db5c9fcb271e5 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java @@ -1,5 +1,6 @@ @@ -73,7 +73,7 @@ index 83407b6149507709d92396f285ac348af95f9034..1f6bb1e5a277174e299d548daf7f6798 import com.google.common.base.Preconditions; import com.google.common.collect.ImmutableSet; import com.google.common.io.BaseEncoding; -@@ -352,6 +353,100 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -356,6 +357,100 @@ public class CraftPlayer extends CraftHumanEntity implements Player { } } diff --git a/patches/server/0057-Add-configurable-portal-search-radius.patch b/patches/server/0057-Add-configurable-portal-search-radius.patch index 517ec4d3fa..dc3426b46b 100644 --- a/patches/server/0057-Add-configurable-portal-search-radius.patch +++ b/patches/server/0057-Add-configurable-portal-search-radius.patch @@ -5,10 +5,10 @@ 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 28704015f17da94d8cb063af70bf4aca83d6eed7..a29f831eca7191f3145477e88921f8f972e580a9 100644 +index e660773a2b0da661e151559f9bf988c4cb148a77..faa958b79b3e6d767f009e7b8b4a6cf1296e39ac 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -3050,7 +3050,13 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -3051,7 +3051,13 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { double d0 = DimensionType.getTeleportationScale(this.level.dimensionType(), destination.dimensionType()); BlockPos blockposition = worldborder.clampToBounds(this.getX() * d0, this.getY(), this.getZ() * d0); // CraftBukkit start diff --git a/patches/server/0058-Add-velocity-warnings.patch b/patches/server/0058-Add-velocity-warnings.patch index b7d4e9b2cc..84bc209e87 100644 --- a/patches/server/0058-Add-velocity-warnings.patch +++ b/patches/server/0058-Add-velocity-warnings.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Add velocity warnings diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 3a62e416e5d67bff401d5d8fd7e794c213997ae4..8aa3e84d5414fecb22069c385103660737132dbb 100644 +index 5674691d0f4c8b0a4c4255476d3d156b08225206..5364bc705fb28380ef66c5faec336287360c7c6f 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -289,6 +289,7 @@ public final class CraftServer implements Server { +@@ -290,6 +290,7 @@ public final class CraftServer implements Server { public boolean ignoreVanillaPermissions = false; private final List playerView; public int reloadCount; @@ -17,7 +17,7 @@ index 3a62e416e5d67bff401d5d8fd7e794c213997ae4..8aa3e84d5414fecb22069c3851036607 static { ConfigurationSerialization.registerClass(CraftOfflinePlayer.class); diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java -index 7a3ae4daa0f1f8dd2dd200fbfa1010f70f4b1f91..9318c47c9e52f8cde5c0ece1dc3723203a41e261 100644 +index 3a0d2613bc84659f9c618e20f3af27e75538331f..e93fef1dc636e98ca11a942d7254256401eb3486 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java @@ -465,10 +465,40 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity { diff --git a/patches/server/0059-Configurable-inter-world-teleportation-safety.patch b/patches/server/0059-Configurable-inter-world-teleportation-safety.patch index 533e6ff98f..e1984f893e 100644 --- a/patches/server/0059-Configurable-inter-world-teleportation-safety.patch +++ b/patches/server/0059-Configurable-inter-world-teleportation-safety.patch @@ -16,10 +16,10 @@ The wanted destination was on top of the emerald block however the player ended This only is the case if the player is teleporting between worlds. diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -index 1f6bb1e5a277174e299d548daf7f6798ff7b7f35..7d1e27f07694588fde273580a517c48ec7dd8d87 100644 +index f1c73e221a0fc0cb24076171b69db5c9fcb271e5..053c07ae24782ab309900851f1a0e0f2b10186f6 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -@@ -1209,7 +1209,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -1207,7 +1207,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player { entity.connection.teleport(to); } else { // The respawn reason should never be used if the passed location is non null. 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 f391e4bd75..39d2e64cff 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,10 +11,10 @@ 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 a29f831eca7191f3145477e88921f8f972e580a9..fe003518ac0f884115af0ce0822a3382c274597a 100644 +index faa958b79b3e6d767f009e7b8b4a6cf1296e39ac..606f3038f6c4a92cb0ae7debb97795abc70a8fb8 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -2681,6 +2681,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -2682,6 +2682,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { @Nullable public Team getTeam() { @@ -23,7 +23,7 @@ index a29f831eca7191f3145477e88921f8f972e580a9..fe003518ac0f884115af0ce0822a3382 } diff --git a/src/main/java/net/minecraft/world/entity/LivingEntity.java b/src/main/java/net/minecraft/world/entity/LivingEntity.java -index 38495e221f0b0584ec8fcd04cd6cd98c2cfa9d10..202eed643693363aa1c052f468d6bd15bb072ff8 100644 +index 4dcaaa2c10966b975d612de8453af7a7f1c32b16..02b3e953f48721030d8c2b4cf82d1b93a4ccf1bf 100644 --- a/src/main/java/net/minecraft/world/entity/LivingEntity.java +++ b/src/main/java/net/minecraft/world/entity/LivingEntity.java @@ -816,6 +816,7 @@ public abstract class LivingEntity extends Entity implements Attackable { diff --git a/patches/server/0065-Complete-resource-pack-API.patch b/patches/server/0065-Complete-resource-pack-API.patch index 7d09649d63..6b21b9b1d2 100644 --- a/patches/server/0065-Complete-resource-pack-API.patch +++ b/patches/server/0065-Complete-resource-pack-API.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Complete resource pack API diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 0da739370a9cbbde1f2bec8d04a6ab6f6971017d..19733418e80d49f65290ba898caf71aa3b0e5334 100644 +index ee0cff3525ff6ca47c91363dd7660c7b85111971..b976e99aaabefefab37651467d4c60d664fda036 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -1755,8 +1755,11 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -1756,8 +1756,11 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic ServerGamePacketListenerImpl.LOGGER.info("Disconnecting {} due to resource pack rejection", this.player.getName()); this.disconnect(Component.translatable("multiplayer.requiredTexturePrompt.disconnect")); } @@ -23,10 +23,10 @@ index 0da739370a9cbbde1f2bec8d04a6ab6f6971017d..19733418e80d49f65290ba898caf71aa @Override diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -index 7d1e27f07694588fde273580a517c48ec7dd8d87..d25c57f25af6d521c471535e8e9ea3e2bc914e9b 100644 +index 053c07ae24782ab309900851f1a0e0f2b10186f6..dfa60512f9113524a584d4a874a7d1e9e53259ba 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -@@ -154,6 +154,7 @@ import org.bukkit.plugin.Plugin; +@@ -158,6 +158,7 @@ import org.bukkit.plugin.Plugin; import org.bukkit.plugin.messaging.StandardMessenger; import org.bukkit.profile.PlayerProfile; import org.bukkit.scoreboard.Scoreboard; @@ -34,7 +34,7 @@ index 7d1e27f07694588fde273580a517c48ec7dd8d87..d25c57f25af6d521c471535e8e9ea3e2 import net.md_5.bungee.api.chat.BaseComponent; // Spigot -@@ -172,6 +173,10 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -176,6 +177,10 @@ public class CraftPlayer extends CraftHumanEntity implements Player { private double healthScale = 20; private CraftWorldBorder clientWorldBorder = null; private BorderChangeListener clientWorldBorderListener = this.createWorldBorderListener(); @@ -45,7 +45,7 @@ index 7d1e27f07694588fde273580a517c48ec7dd8d87..d25c57f25af6d521c471535e8e9ea3e2 public CraftPlayer(CraftServer server, ServerPlayer entity) { super(server, entity); -@@ -2351,6 +2356,45 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -2359,6 +2364,45 @@ public class CraftPlayer extends CraftHumanEntity implements Player { public boolean getAffectsSpawning() { return this.getHandle().affectsSpawning; } diff --git a/patches/server/0066-Default-loading-permissions.yml-before-plugins.patch b/patches/server/0066-Default-loading-permissions.yml-before-plugins.patch index 6533d53954..186807708e 100644 --- a/patches/server/0066-Default-loading-permissions.yml-before-plugins.patch +++ b/patches/server/0066-Default-loading-permissions.yml-before-plugins.patch @@ -16,10 +16,10 @@ modify that. Under the previous logic, plugins were unable (cleanly) override pe A config option has been added for those who depend on the previous behavior, but I don't expect that. diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 8aa3e84d5414fecb22069c385103660737132dbb..6934e0f34d47d2697d9d1326674e7986f510cd40 100644 +index 5364bc705fb28380ef66c5faec336287360c7c6f..377e631bb70c4711152ff2895bc8ffd3c032bba4 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -449,6 +449,7 @@ public final class CraftServer implements Server { +@@ -450,6 +450,7 @@ public final class CraftServer implements Server { if (type == PluginLoadOrder.STARTUP) { this.helpMap.clear(); this.helpMap.initializeGeneralTopics(); @@ -27,7 +27,7 @@ index 8aa3e84d5414fecb22069c385103660737132dbb..6934e0f34d47d2697d9d1326674e7986 } Plugin[] plugins = this.pluginManager.getPlugins(); -@@ -468,7 +469,7 @@ public final class CraftServer implements Server { +@@ -469,7 +470,7 @@ public final class CraftServer implements Server { this.commandMap.registerServerAliases(); DefaultPermissions.registerCorePermissions(); CraftDefaultPermissions.registerCorePermissions(); diff --git a/patches/server/0067-Allow-Reloading-of-Custom-Permissions.patch b/patches/server/0067-Allow-Reloading-of-Custom-Permissions.patch index 06d2b7d733..7ae2905820 100644 --- a/patches/server/0067-Allow-Reloading-of-Custom-Permissions.patch +++ b/patches/server/0067-Allow-Reloading-of-Custom-Permissions.patch @@ -6,10 +6,10 @@ Subject: [PATCH] Allow Reloading of Custom Permissions https://github.com/PaperMC/Paper/issues/49 diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 6934e0f34d47d2697d9d1326674e7986f510cd40..3ec1ed8137b1f6de5cafaab340ad983d9093775d 100644 +index 377e631bb70c4711152ff2895bc8ffd3c032bba4..ec97b740a935196d689fac7ff239968b87884a96 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -2544,5 +2544,23 @@ public final class CraftServer implements Server { +@@ -2545,5 +2545,23 @@ public final class CraftServer implements Server { } return this.adventure$audiences; } diff --git a/patches/server/0068-Remove-Metadata-on-reload.patch b/patches/server/0068-Remove-Metadata-on-reload.patch index 095f010c1a..957790d315 100644 --- a/patches/server/0068-Remove-Metadata-on-reload.patch +++ b/patches/server/0068-Remove-Metadata-on-reload.patch @@ -7,10 +7,10 @@ Metadata is not meant to persist reload as things break badly with non primitive This will remove metadata on reload so it does not crash everything if a plugin uses it. diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 3ec1ed8137b1f6de5cafaab340ad983d9093775d..844cef6971ae6520edcd6d794ff76040509c4552 100644 +index ec97b740a935196d689fac7ff239968b87884a96..90ab7190b1f59f2a6440ebfa6454a4b395f45ab5 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -939,8 +939,16 @@ public final class CraftServer implements Server { +@@ -940,8 +940,16 @@ public final class CraftServer implements Server { world.spigotConfig.init(); // Spigot } diff --git a/patches/server/0073-handle-NaN-health-absorb-values-and-repair-bad-data.patch b/patches/server/0073-handle-NaN-health-absorb-values-and-repair-bad-data.patch index 5fbc59ae98..0262ded23d 100644 --- a/patches/server/0073-handle-NaN-health-absorb-values-and-repair-bad-data.patch +++ b/patches/server/0073-handle-NaN-health-absorb-values-and-repair-bad-data.patch @@ -44,10 +44,10 @@ index 9936fb67766dedba71b582316dd2bddd6567c342..2f161145789890fcd9bfd893b099f25a } diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -index d25c57f25af6d521c471535e8e9ea3e2bc914e9b..c7bc16d568199226885e4cd39c6835feb30bd532 100644 +index dfa60512f9113524a584d4a874a7d1e9e53259ba..2525b010fb36bc28327a33a5def6602e1ecfb3de 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -@@ -2156,6 +2156,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -2164,6 +2164,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player { } public void setRealHealth(double health) { 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 346d409c9d..ea6f2b94ba 100644 --- a/patches/server/0074-Use-a-Shared-Random-for-Entities.patch +++ b/patches/server/0074-Use-a-Shared-Random-for-Entities.patch @@ -6,10 +6,10 @@ 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 fe003518ac0f884115af0ce0822a3382c274597a..7f32aae16af188ec0c3dcbcdd7aeae5f1b9526b6 100644 +index 606f3038f6c4a92cb0ae7debb97795abc70a8fb8..4d2491c04b587c8315173ccbcac9686f42937358 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -161,6 +161,79 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -162,6 +162,79 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { return tag.contains("Bukkit.updateLevel") && tag.getInt("Bukkit.updateLevel") >= level; } @@ -89,7 +89,7 @@ index fe003518ac0f884115af0ce0822a3382c274597a..7f32aae16af188ec0c3dcbcdd7aeae5f private CraftEntity bukkitEntity; public CraftEntity getBukkitEntity() { -@@ -401,7 +474,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -402,7 +475,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { this.bb = Entity.INITIAL_AABB; this.stuckSpeedMultiplier = Vec3.ZERO; this.nextStep = 1.0F; diff --git a/patches/server/0083-Add-PlayerUseUnknownEntityEvent.patch b/patches/server/0083-Add-PlayerUseUnknownEntityEvent.patch index ec096d75b5..5cf35701ac 100644 --- a/patches/server/0083-Add-PlayerUseUnknownEntityEvent.patch +++ b/patches/server/0083-Add-PlayerUseUnknownEntityEvent.patch @@ -22,10 +22,10 @@ index a5d57cc862036012d83b090bb1b3ccf4115a88b3..21068f766b75c414d5818073b7dca083 static final ServerboundInteractPacket.Action ATTACK_ACTION = new ServerboundInteractPacket.Action() { @Override diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 19733418e80d49f65290ba898caf71aa3b0e5334..e4becdbb95f0309b9173722762836037dc38b33d 100644 +index dac2665008b5ba49134c84373f916c5c6ed355e9..8e602afa03f067ed1b62f3c855fa302c3fb3eeeb 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -2535,8 +2535,37 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -2542,8 +2542,37 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic }); } } diff --git a/patches/server/0088-Configurable-Player-Collision.patch b/patches/server/0088-Configurable-Player-Collision.patch index e2c7129b3d..3f96fec8e0 100644 --- a/patches/server/0088-Configurable-Player-Collision.patch +++ b/patches/server/0088-Configurable-Player-Collision.patch @@ -43,7 +43,7 @@ index f48d3bbbfd5b4ebb9c22c6dc2a17a9030af2edf5..2ea0cb1f9bfc5ef7bd8c78cf259da13b 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 c416b0c670d5c1f43d5b2a097e068bc51a6c660d..97b258adb325a6620ddb26f267c04d533e6e1100 100644 +index 57281d4a3c6b187d13ba5cadd46f494df411e7ba..1cd7a99a6280975dac96a33b077b372d358f967c 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java @@ -99,6 +99,7 @@ import net.minecraft.world.level.storage.PlayerDataStorage; @@ -54,7 +54,7 @@ index c416b0c670d5c1f43d5b2a097e068bc51a6c660d..97b258adb325a6620ddb26f267c04d53 import net.minecraft.world.scores.Team; import org.slf4j.Logger; -@@ -162,6 +163,7 @@ public abstract class PlayerList { +@@ -164,6 +165,7 @@ public abstract class PlayerList { // CraftBukkit start private CraftServer cserver; private final Map playersByName = new java.util.HashMap<>(); @@ -62,7 +62,7 @@ index c416b0c670d5c1f43d5b2a097e068bc51a6c660d..97b258adb325a6620ddb26f267c04d53 public PlayerList(MinecraftServer server, LayeredRegistryAccess registryManager, PlayerDataStorage saveHandler, int maxPlayers) { this.cserver = server.server = new CraftServer((DedicatedServer) server, this); -@@ -407,6 +409,13 @@ public abstract class PlayerList { +@@ -409,6 +411,13 @@ public abstract class PlayerList { player.initInventoryMenu(); // CraftBukkit - Moved from above, added world @@ -76,7 +76,7 @@ index c416b0c670d5c1f43d5b2a097e068bc51a6c660d..97b258adb325a6620ddb26f267c04d53 PlayerList.LOGGER.info("{}[{}] logged in with entity id {} at ([{}]{}, {}, {})", player.getName().getString(), s1, player.getId(), worldserver1.serverLevelData.getLevelName(), player.getX(), player.getY(), player.getZ()); } -@@ -526,6 +535,16 @@ public abstract class PlayerList { +@@ -528,6 +537,16 @@ public abstract class PlayerList { entityplayer.doTick(); // SPIGOT-924 // CraftBukkit end @@ -93,7 +93,7 @@ index c416b0c670d5c1f43d5b2a097e068bc51a6c660d..97b258adb325a6620ddb26f267c04d53 this.save(entityplayer); if (entityplayer.isPassenger()) { Entity entity = entityplayer.getRootVehicle(); -@@ -1157,6 +1176,13 @@ public abstract class PlayerList { +@@ -1159,6 +1178,13 @@ public abstract class PlayerList { } // CraftBukkit end diff --git a/patches/server/0095-LootTable-API-Replenishable-Lootables-Feature.patch b/patches/server/0095-LootTable-API-Replenishable-Lootables-Feature.patch index e3bba82f09..18a5705aa7 100644 --- a/patches/server/0095-LootTable-API-Replenishable-Lootables-Feature.patch +++ b/patches/server/0095-LootTable-API-Replenishable-Lootables-Feature.patch @@ -490,10 +490,10 @@ 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 ec566ca4525ab9f6131dab57dc693982357c42d8..0aec74557ef981c1e360485ee4bcb57836eb1dbd 100644 +index 4d2491c04b587c8315173ccbcac9686f42937358..d40c4706918aa2cebc1422fba1a09c83e75e6bf7 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -234,6 +234,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -235,6 +235,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { } // Paper end diff --git a/patches/server/0106-Add-setting-for-proxy-online-mode-status.patch b/patches/server/0106-Add-setting-for-proxy-online-mode-status.patch index c035f73293..a6ef14dc06 100644 --- a/patches/server/0106-Add-setting-for-proxy-online-mode-status.patch +++ b/patches/server/0106-Add-setting-for-proxy-online-mode-status.patch @@ -43,10 +43,10 @@ index da98f074ccd5a40c635824112c97fd174c393cb1..6599f874d9f97e9ef4862039ecad7277 } else { String[] astring1 = astring; diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 844cef6971ae6520edcd6d794ff76040509c4552..423b76b6852cf1eabd491d4c654b78e29a84e44b 100644 +index 90ab7190b1f59f2a6440ebfa6454a4b395f45ab5..94dd69d1b8beaf0edf9faf79a66ba2d41e12b5b8 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -1714,7 +1714,7 @@ public final class CraftServer implements Server { +@@ -1715,7 +1715,7 @@ public final class CraftServer implements Server { // Spigot Start GameProfile profile = null; // Only fetch an online UUID in online mode diff --git a/patches/server/0108-Configurable-packet-in-spam-threshold.patch b/patches/server/0108-Configurable-packet-in-spam-threshold.patch index 0dc3362368..6bb43dba02 100644 --- a/patches/server/0108-Configurable-packet-in-spam-threshold.patch +++ b/patches/server/0108-Configurable-packet-in-spam-threshold.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Configurable packet in spam threshold diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index e4becdbb95f0309b9173722762836037dc38b33d..a2dc13c9440876953f703eedc69ec29db73f6e67 100644 +index 20b9fa814d85b83d46714f4d3743647af473acb6..97996eb06efdf275f34f4aba14b0e377d4515ccf 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -1595,13 +1595,14 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -1596,13 +1596,14 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic // Spigot start - limit place/interactions private int limitedPackets; private long lastLimitedPacket = -1; diff --git a/patches/server/0109-Configurable-flying-kick-messages.patch b/patches/server/0109-Configurable-flying-kick-messages.patch index 7b60d11f83..c390ccb293 100644 --- a/patches/server/0109-Configurable-flying-kick-messages.patch +++ b/patches/server/0109-Configurable-flying-kick-messages.patch @@ -5,10 +5,10 @@ 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 a2dc13c9440876953f703eedc69ec29db73f6e67..f06fde519bc69102dcb69f7f62f250f66d02edf6 100644 +index 97996eb06efdf275f34f4aba14b0e377d4515ccf..fcb56b5c3eb2aa7de373fc3f1f410e5e5e287765 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -354,7 +354,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -355,7 +355,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic if (this.clientIsFloating && !this.player.isSleeping() && !this.player.isPassenger() && !this.player.isDeadOrDying()) { if (++this.aboveGroundTickCount > 80) { ServerGamePacketListenerImpl.LOGGER.warn("{} was kicked for floating too long!", this.player.getName().getString()); @@ -17,7 +17,7 @@ index a2dc13c9440876953f703eedc69ec29db73f6e67..f06fde519bc69102dcb69f7f62f250f6 return; } } else { -@@ -373,7 +373,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -374,7 +374,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic if (this.clientVehicleIsFloating && this.player.getRootVehicle().getControllingPassenger() == this.player) { if (++this.aboveGroundVehicleTickCount > 80) { ServerGamePacketListenerImpl.LOGGER.warn("{} was kicked for floating a vehicle too long!", this.player.getName().getString()); diff --git a/patches/server/0110-Add-EntityZapEvent.patch b/patches/server/0110-Add-EntityZapEvent.patch index 185a344c91..5659e3e59d 100644 --- a/patches/server/0110-Add-EntityZapEvent.patch +++ b/patches/server/0110-Add-EntityZapEvent.patch @@ -28,10 +28,10 @@ index efbf6b316a70b94e4bd490df8ebe77cd9f638ba4..cad8854cc7523d60c06ca1f03bfd4fbf entitywitch.finalizeSpawn(world, world.getCurrentDifficultyAt(entitywitch.blockPosition()), MobSpawnType.CONVERSION, (SpawnGroupData) null, (CompoundTag) null); entitywitch.setNoAi(this.isNoAi()); diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java -index 9bf4b8865237fd2555ed0e4b2e619afd7dc6845e..0d19b629e2e674b9908c25543c739ec357f20d8a 100644 +index f1dc8eaa571f54e5885ceada9929d965992d7760..04b5b28e9127a0e94515d261f6d7d34230cbf447 100644 --- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java +++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java -@@ -1180,6 +1180,14 @@ public class CraftEventFactory { +@@ -1189,6 +1189,14 @@ public class CraftEventFactory { return event; } diff --git a/patches/server/0113-Allow-Reloading-of-Command-Aliases.patch b/patches/server/0113-Allow-Reloading-of-Command-Aliases.patch index 842ef3bf21..09862184b1 100644 --- a/patches/server/0113-Allow-Reloading-of-Command-Aliases.patch +++ b/patches/server/0113-Allow-Reloading-of-Command-Aliases.patch @@ -6,10 +6,10 @@ Subject: [PATCH] Allow Reloading of Command Aliases Reload the aliases stored in commands.yml diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 423b76b6852cf1eabd491d4c654b78e29a84e44b..9044c35ab2d747c89312c2d98fe4c910ddd1365b 100644 +index 94dd69d1b8beaf0edf9faf79a66ba2d41e12b5b8..e2fd156ed79e454f2a4337e5e53e749dd1b02ea1 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -2570,5 +2570,24 @@ public final class CraftServer implements Server { +@@ -2571,5 +2571,24 @@ public final class CraftServer implements Server { DefaultPermissions.registerCorePermissions(); CraftDefaultPermissions.registerCorePermissions(); } diff --git a/patches/server/0114-Add-source-to-PlayerExpChangeEvent.patch b/patches/server/0114-Add-source-to-PlayerExpChangeEvent.patch index 2a5ff459be..3c14c471ea 100644 --- a/patches/server/0114-Add-source-to-PlayerExpChangeEvent.patch +++ b/patches/server/0114-Add-source-to-PlayerExpChangeEvent.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Add source to PlayerExpChangeEvent diff --git a/src/main/java/net/minecraft/world/entity/ExperienceOrb.java b/src/main/java/net/minecraft/world/entity/ExperienceOrb.java -index 5391c60398c8a7d1d49dc2e73116b27862653873..5a79b49e321cba352d8e4189dfbfdd0506ec3e5a 100644 +index 588deb938ca710de33bb42bb02c7015b8cbd8eef..f9ccde41eb20c1d53c438ddb40ca7cc5d2b89836 100644 --- a/src/main/java/net/minecraft/world/entity/ExperienceOrb.java +++ b/src/main/java/net/minecraft/world/entity/ExperienceOrb.java -@@ -248,7 +248,7 @@ public class ExperienceOrb extends Entity { +@@ -249,7 +249,7 @@ public class ExperienceOrb extends Entity { int i = this.repairPlayerItems(player, this.value); if (i > 0) { @@ -18,10 +18,10 @@ index 5391c60398c8a7d1d49dc2e73116b27862653873..5a79b49e321cba352d8e4189dfbfdd05 --this.count; diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java -index 0d19b629e2e674b9908c25543c739ec357f20d8a..774063ea6bd7ef9afbc3fd7046c236519e62e3bc 100644 +index 04b5b28e9127a0e94515d261f6d7d34230cbf447..87da5cfb3be65c57ada7dbfc1f345f27533df064 100644 --- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java +++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java -@@ -1139,6 +1139,17 @@ public class CraftEventFactory { +@@ -1148,6 +1148,17 @@ public class CraftEventFactory { return event; } diff --git a/patches/server/0115-Add-ProjectileCollideEvent.patch b/patches/server/0115-Add-ProjectileCollideEvent.patch index 81bbdccd5e..4b25053508 100644 --- a/patches/server/0115-Add-ProjectileCollideEvent.patch +++ b/patches/server/0115-Add-ProjectileCollideEvent.patch @@ -6,10 +6,10 @@ Subject: [PATCH] Add ProjectileCollideEvent Deprecated now and replaced with ProjectileHitEvent diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java -index 774063ea6bd7ef9afbc3fd7046c236519e62e3bc..fea90633f10bad7498f8f5e90093eee2a09df549 100644 +index 87da5cfb3be65c57ada7dbfc1f345f27533df064..64ddab11cc8bd9e8063450f2bec22a4277e49414 100644 --- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java +++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java -@@ -1283,6 +1283,17 @@ public class CraftEventFactory { +@@ -1292,6 +1292,17 @@ public class CraftEventFactory { return CraftItemStack.asNMSCopy(bitem); } @@ -27,7 +27,7 @@ index 774063ea6bd7ef9afbc3fd7046c236519e62e3bc..fea90633f10bad7498f8f5e90093eee2 public static ProjectileLaunchEvent callProjectileLaunchEvent(Entity entity) { Projectile bukkitEntity = (Projectile) entity.getBukkitEntity(); ProjectileLaunchEvent event = new ProjectileLaunchEvent(bukkitEntity); -@@ -1307,8 +1318,15 @@ public class CraftEventFactory { +@@ -1316,8 +1327,15 @@ public class CraftEventFactory { if (position.getType() == HitResult.Type.ENTITY) { hitEntity = ((EntityHitResult) position).getEntity().getBukkitEntity(); } diff --git a/patches/server/0122-String-based-Action-Bar-API.patch b/patches/server/0122-String-based-Action-Bar-API.patch index b17ec6dcfc..73ceb8a2b0 100644 --- a/patches/server/0122-String-based-Action-Bar-API.patch +++ b/patches/server/0122-String-based-Action-Bar-API.patch @@ -26,10 +26,10 @@ index 32ef3edebe94a2014168b7e438752a80b2687e5f..ab6c58eed6707ab7b0aa3e7549a871ad // Paper end buf.writeComponent(this.text); diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -index c7bc16d568199226885e4cd39c6835feb30bd532..6a12f14f7433ee13605f8dd8b7e0e8d127b915bd 100644 +index 2525b010fb36bc28327a33a5def6602e1ecfb3de..0ae1f334eae66cfcca618655942c13809e38060b 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -@@ -359,6 +359,29 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -363,6 +363,29 @@ public class CraftPlayer extends CraftHumanEntity implements Player { } // Paper start diff --git a/patches/server/0123-Properly-fix-item-duplication-bug.patch b/patches/server/0123-Properly-fix-item-duplication-bug.patch index 5b6f3d8fd2..e374d16f4e 100644 --- a/patches/server/0123-Properly-fix-item-duplication-bug.patch +++ b/patches/server/0123-Properly-fix-item-duplication-bug.patch @@ -6,10 +6,10 @@ Subject: [PATCH] Properly fix item duplication bug Credit to prplz for figuring out the real issue diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java -index fc364823f20f458af936c7209bd7174e05cb0fc0..9d04d3d1e24222bf255a1fc96761909574f67d66 100644 +index fef0ce65c01fd56a0ed62de27e8d8457324bb295..7395cdcf618033f10482001cb9e2a7727e1e8bb2 100644 --- a/src/main/java/net/minecraft/server/level/ServerPlayer.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java -@@ -2279,7 +2279,7 @@ public class ServerPlayer extends Player { +@@ -2307,7 +2307,7 @@ public class ServerPlayer extends Player { @Override public boolean isImmobile() { @@ -19,10 +19,10 @@ index fc364823f20f458af936c7209bd7174e05cb0fc0..9d04d3d1e24222bf255a1fc967619095 @Override diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index f06fde519bc69102dcb69f7f62f250f66d02edf6..55622bca79e52418a81eb713d59c04899e49c1fa 100644 +index 7e24a354a513a452aa1f7babb3ee402de8f6e72d..ba493c748c810e4ba452d59bcf8f1b7599f09b04 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -3179,7 +3179,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -3186,7 +3186,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic } public final boolean isDisconnected() { diff --git a/patches/server/0126-Provide-E-TE-Chunk-count-stat-methods.patch b/patches/server/0126-Provide-E-TE-Chunk-count-stat-methods.patch index 8fbcabe65d..e8d5bc6395 100644 --- a/patches/server/0126-Provide-E-TE-Chunk-count-stat-methods.patch +++ b/patches/server/0126-Provide-E-TE-Chunk-count-stat-methods.patch @@ -20,10 +20,10 @@ index 1a0accca970ca5eb895c63c5a45a5261440d0e12..35eecb719a813fda6113da24a858188a private final List pendingBlockEntityTickers = Lists.newArrayList(); private boolean tickingBlockEntities; diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -index 1684b3ee1b51597e799486bbe129b344a9fe3098..857fac09453f99a56d41a3a57a5f36c22496a643 100644 +index 40e532b616178aced5aac5871f71654f1f740877..6d93bbfcbdb01ba9424b7107bcd1e685c9a15701 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -@@ -152,6 +152,56 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -153,6 +153,56 @@ public class CraftWorld extends CraftRegionAccessor implements World { private final CraftPersistentDataContainer persistentDataContainer = new CraftPersistentDataContainer(CraftWorld.DATA_TYPE_REGISTRY); private net.kyori.adventure.pointer.Pointers adventure$pointers; // Paper - implement pointers diff --git a/patches/server/0127-Enforce-Sync-Player-Saves.patch b/patches/server/0127-Enforce-Sync-Player-Saves.patch index c181182455..309ffb9171 100644 --- a/patches/server/0127-Enforce-Sync-Player-Saves.patch +++ b/patches/server/0127-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 97b258adb325a6620ddb26f267c04d533e6e1100..1179c809674082b6d238c9b32cb2c9ff038dbcf0 100644 +index 1cd7a99a6280975dac96a33b077b372d358f967c..4066a3c6b032d13e4c303b10b012f1224925710f 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -1060,11 +1060,13 @@ public abstract class PlayerList { +@@ -1062,11 +1062,13 @@ public abstract class PlayerList { } public void saveAll() { diff --git a/patches/server/0128-Don-t-allow-entities-to-ride-themselves-572.patch b/patches/server/0128-Don-t-allow-entities-to-ride-themselves-572.patch index f50e947abd..bd6c93d1d0 100644 --- a/patches/server/0128-Don-t-allow-entities-to-ride-themselves-572.patch +++ b/patches/server/0128-Don-t-allow-entities-to-ride-themselves-572.patch @@ -5,10 +5,10 @@ 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 384e4371e56d877118cb68e4ca94a0cc38b4d101..6d76be16ba1b35a65b851c2c861093c9998fcc61 100644 +index d40c4706918aa2cebc1422fba1a09c83e75e6bf7..368a6d73c94addcf948e7cf8f3a026ab2017731e 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -2417,6 +2417,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -2418,6 +2418,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { } protected boolean addPassenger(Entity entity) { // CraftBukkit diff --git a/patches/server/0129-ExperienceOrbs-API-for-Reason-Source-Triggering-play.patch b/patches/server/0129-ExperienceOrbs-API-for-Reason-Source-Triggering-play.patch index b03066a00e..4d3809cf68 100644 --- a/patches/server/0129-ExperienceOrbs-API-for-Reason-Source-Triggering-play.patch +++ b/patches/server/0129-ExperienceOrbs-API-for-Reason-Source-Triggering-play.patch @@ -21,10 +21,10 @@ index 2f21c7920148b812c48da95168fbc63b86b86c9c..fc42bc68ae31f4fad1c382ef3d3c482c return true; diff --git a/src/main/java/net/minecraft/world/entity/ExperienceOrb.java b/src/main/java/net/minecraft/world/entity/ExperienceOrb.java -index 5a79b49e321cba352d8e4189dfbfdd0506ec3e5a..f9488311524bb8ff8a5686763973c9ae0053668d 100644 +index f9ccde41eb20c1d53c438ddb40ca7cc5d2b89836..e952aae85a80a020087c3697624c8c13eab3f914 100644 --- a/src/main/java/net/minecraft/world/entity/ExperienceOrb.java +++ b/src/main/java/net/minecraft/world/entity/ExperienceOrb.java -@@ -38,13 +38,65 @@ public class ExperienceOrb extends Entity { +@@ -39,13 +39,65 @@ public class ExperienceOrb extends Entity { public int value; private int count; private Player followingPlayer; @@ -92,7 +92,7 @@ index 5a79b49e321cba352d8e4189dfbfdd0506ec3e5a..f9488311524bb8ff8a5686763973c9ae } public ExperienceOrb(EntityType type, Level world) { -@@ -154,12 +206,20 @@ public class ExperienceOrb extends Entity { +@@ -155,12 +207,20 @@ public class ExperienceOrb extends Entity { } public static void award(ServerLevel world, Vec3 pos, int amount) { @@ -114,7 +114,7 @@ index 5a79b49e321cba352d8e4189dfbfdd0506ec3e5a..f9488311524bb8ff8a5686763973c9ae } } -@@ -229,6 +289,7 @@ public class ExperienceOrb extends Entity { +@@ -230,6 +290,7 @@ public class ExperienceOrb extends Entity { nbt.putShort("Age", (short) this.age); nbt.putShort("Value", (short) this.value); nbt.putInt("Count", this.count); @@ -122,7 +122,7 @@ index 5a79b49e321cba352d8e4189dfbfdd0506ec3e5a..f9488311524bb8ff8a5686763973c9ae } @Override -@@ -237,6 +298,7 @@ public class ExperienceOrb extends Entity { +@@ -238,6 +299,7 @@ public class ExperienceOrb extends Entity { this.age = nbt.getShort("Age"); this.value = nbt.getShort("Value"); this.count = Math.max(nbt.getInt("Count"), 1); @@ -245,10 +245,10 @@ index 6a56b3c12a733662b23c984975f8dfdb43cf6f9b..69ab58f2d8d9287a64f330a02e7cd3be } diff --git a/src/main/java/net/minecraft/world/entity/projectile/FishingHook.java b/src/main/java/net/minecraft/world/entity/projectile/FishingHook.java -index d9a01dbd9bcdf634b906b369222e6e7ba90dc7c5..7d058efff8820727e2e8531bdd57f85059b5ca30 100644 +index 9a753ffd35403358df07408ffe85197ee3318f39..082fa4318dc03defbdb76e99250b7d71aa6710f5 100644 --- a/src/main/java/net/minecraft/world/entity/projectile/FishingHook.java +++ b/src/main/java/net/minecraft/world/entity/projectile/FishingHook.java -@@ -514,7 +514,7 @@ public class FishingHook extends Projectile { +@@ -522,7 +522,7 @@ public class FishingHook extends Projectile { this.level.addFreshEntity(entityitem); // CraftBukkit start - this.random.nextInt(6) + 1 -> playerFishEvent.getExpToDrop() if (playerFishEvent.getExpToDrop() > 0) { @@ -316,10 +316,10 @@ index 9b54fd08fae889ac9db09ba67deb5eaae0f3d010..4ed87cc5a46d9e10c755631a16f0e0cb @Override diff --git a/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java b/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java -index 9682b8ddc3b2f127217fcd569881691098cf9973..f8399f63d7b511dfeb7a7ee9d24f848afd16e8c1 100644 +index 0b4f7953d88971fd86f85d29beefbb84cd2121b1..7c5d5355237bc00f1c8c8433351ca7a9938f2e8b 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java -@@ -925,7 +925,7 @@ public abstract class CraftRegionAccessor implements RegionAccessor { +@@ -946,7 +946,7 @@ public abstract class CraftRegionAccessor implements RegionAccessor { } else if (TNTPrimed.class.isAssignableFrom(clazz)) { entity = new PrimedTnt(world, x, y, z, null); } else if (ExperienceOrb.class.isAssignableFrom(clazz)) { diff --git a/patches/server/0130-Cap-Entity-Collisions.patch b/patches/server/0130-Cap-Entity-Collisions.patch index 999a259ec2..53286bcb9f 100644 --- a/patches/server/0130-Cap-Entity-Collisions.patch +++ b/patches/server/0130-Cap-Entity-Collisions.patch @@ -12,10 +12,10 @@ 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 6d76be16ba1b35a65b851c2c861093c9998fcc61..7d839daeca968df2044bf2071bf1b5ff2b2aa3d6 100644 +index 368a6d73c94addcf948e7cf8f3a026ab2017731e..1658a5263f0905c2938dae10b8d3d603fcd4bdca 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -382,6 +382,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -383,6 +383,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { public void inactiveTick() { } // Spigot end // Paper start @@ -24,7 +24,7 @@ index 6d76be16ba1b35a65b851c2c861093c9998fcc61..7d839daeca968df2044bf2071bf1b5ff private org.bukkit.util.Vector origin; @javax.annotation.Nullable diff --git a/src/main/java/net/minecraft/world/entity/LivingEntity.java b/src/main/java/net/minecraft/world/entity/LivingEntity.java -index e004dffee9f1efe44c78f9b2e938b98cc4b2b847..2cd9c02fd664e263d9dae030d2c438a082c9e1b4 100644 +index 08087527293c5137af078fa17b6c0f219eab15d0..4505bd3a2b3854b6d2c7e87ee67df338397a1fa8 100644 --- a/src/main/java/net/minecraft/world/entity/LivingEntity.java +++ b/src/main/java/net/minecraft/world/entity/LivingEntity.java @@ -3277,8 +3277,11 @@ public abstract class LivingEntity extends Entity implements Attackable { diff --git a/patches/server/0133-Properly-handle-async-calls-to-restart-the-server.patch b/patches/server/0133-Properly-handle-async-calls-to-restart-the-server.patch index aa52660cb6..4274290956 100644 --- a/patches/server/0133-Properly-handle-async-calls-to-restart-the-server.patch +++ b/patches/server/0133-Properly-handle-async-calls-to-restart-the-server.patch @@ -64,10 +64,10 @@ index e845baf287da216bc5c1d2588b8e720212318266..d9ceef3d9694ab85f807a732789b2871 if (waitForShutdown) { try { diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java -index 1179c809674082b6d238c9b32cb2c9ff038dbcf0..c0f765362d89b73917bb61274afc83812e066227 100644 +index 4066a3c6b032d13e4c303b10b012f1224925710f..a34c9da6dbd37ab01385b768c06fef418de9c7c8 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -1172,8 +1172,15 @@ public abstract class PlayerList { +@@ -1174,8 +1174,15 @@ public abstract class PlayerList { } public void removeAll() { diff --git a/patches/server/0134-Add-option-to-make-parrots-stay-on-shoulders-despite.patch b/patches/server/0134-Add-option-to-make-parrots-stay-on-shoulders-despite.patch index f6e231ce7f..a65f274b48 100644 --- a/patches/server/0134-Add-option-to-make-parrots-stay-on-shoulders-despite.patch +++ b/patches/server/0134-Add-option-to-make-parrots-stay-on-shoulders-despite.patch @@ -14,10 +14,10 @@ To be converted into a Paper-API event at some point in the future? public net.minecraft.world.entity.player.Player removeEntitiesOnShoulder()V diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 55622bca79e52418a81eb713d59c04899e49c1fa..f42cf92eeb2c491a9bf75e67047c11edfc1185ab 100644 +index ba493c748c810e4ba452d59bcf8f1b7599f09b04..8da1aa70d2cdbe722ebb9f0f4e30fb73bdbeab92 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -2323,6 +2323,13 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -2330,6 +2330,13 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic switch (packet.getAction()) { case PRESS_SHIFT_KEY: this.player.setShiftKeyDown(true); diff --git a/patches/server/0135-Add-configuration-option-to-prevent-player-names-fro.patch b/patches/server/0135-Add-configuration-option-to-prevent-player-names-fro.patch index 817ac48bdb..4432fa9dfe 100644 --- a/patches/server/0135-Add-configuration-option-to-prevent-player-names-fro.patch +++ b/patches/server/0135-Add-configuration-option-to-prevent-player-names-fro.patch @@ -6,10 +6,10 @@ Subject: [PATCH] Add configuration option to prevent player names from being diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 9044c35ab2d747c89312c2d98fe4c910ddd1365b..3aabd7aaad60c157740d12932d0cb071ae259c21 100644 +index e2fd156ed79e454f2a4337e5e53e749dd1b02ea1..325e65488b31efe609f60b5d6d95ca89eda39f92 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -2589,5 +2589,10 @@ public final class CraftServer implements Server { +@@ -2590,5 +2590,10 @@ public final class CraftServer implements Server { commandMap.registerServerAliases(); return true; } diff --git a/patches/server/0136-Use-TerminalConsoleAppender-for-console-improvements.patch b/patches/server/0136-Use-TerminalConsoleAppender-for-console-improvements.patch index a7bf6e1cb7..92915e6fb7 100644 --- a/patches/server/0136-Use-TerminalConsoleAppender-for-console-improvements.patch +++ b/patches/server/0136-Use-TerminalConsoleAppender-for-console-improvements.patch @@ -222,10 +222,10 @@ index 35904c69e14c4c0addda204d5e3788518c2e16c4..e6826cd0a596f063e8737dcde3c8c6c5 System.setOut(IoBuilder.forLogger(logger).setLevel(Level.INFO).buildPrintStream()); System.setErr(IoBuilder.forLogger(logger).setLevel(Level.WARN).buildPrintStream()); diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java -index c0f765362d89b73917bb61274afc83812e066227..d5d9579b3313299543f45d6ebf79bca6fddf09ff 100644 +index a34c9da6dbd37ab01385b768c06fef418de9c7c8..ce2291fb34df531b783d34f8453128a7a01049e5 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -167,8 +167,7 @@ public abstract class PlayerList { +@@ -169,8 +169,7 @@ public abstract class PlayerList { public PlayerList(MinecraftServer server, LayeredRegistryAccess registryManager, PlayerDataStorage saveHandler, int maxPlayers) { this.cserver = server.server = new CraftServer((DedicatedServer) server, this); @@ -236,7 +236,7 @@ index c0f765362d89b73917bb61274afc83812e066227..d5d9579b3313299543f45d6ebf79bca6 this.bans = new UserBanList(PlayerList.USERBANLIST_FILE); diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index b43dd6151647b370f3a8138a62ebd9482e095374..729696d7177851d31795c600a33d1abd9a9041c2 100644 +index 325e65488b31efe609f60b5d6d95ca89eda39f92..cd9a7d5f30e0ca11bd735bbc132a80a228ca4c2e 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java @@ -41,7 +41,6 @@ import java.util.logging.Level; @@ -247,7 +247,7 @@ index b43dd6151647b370f3a8138a62ebd9482e095374..729696d7177851d31795c600a33d1abd import net.minecraft.advancements.Advancement; import net.minecraft.commands.CommandSourceStack; import net.minecraft.commands.Commands; -@@ -1280,9 +1279,13 @@ public final class CraftServer implements Server { +@@ -1281,9 +1280,13 @@ public final class CraftServer implements Server { return this.logger; } @@ -262,7 +262,7 @@ index b43dd6151647b370f3a8138a62ebd9482e095374..729696d7177851d31795c600a33d1abd @Override public PluginCommand getPluginCommand(String name) { diff --git a/src/main/java/org/bukkit/craftbukkit/Main.java b/src/main/java/org/bukkit/craftbukkit/Main.java -index a13079a212bc0e4506ebc476ac058f1f8ca3d1de..beec3ebe4abc977885f93ef28aac3e834142d373 100644 +index d6e9f626b9c6ec5b16d37f0816775f1391487a11..730f805790bcab15e97c56bc6fc92cf38e70f5b0 100644 --- a/src/main/java/org/bukkit/craftbukkit/Main.java +++ b/src/main/java/org/bukkit/craftbukkit/Main.java @@ -13,7 +13,6 @@ import java.util.logging.Logger; diff --git a/patches/server/0142-Add-UnknownCommandEvent.patch b/patches/server/0142-Add-UnknownCommandEvent.patch index d510afc1bf..a493f62980 100644 --- a/patches/server/0142-Add-UnknownCommandEvent.patch +++ b/patches/server/0142-Add-UnknownCommandEvent.patch @@ -83,10 +83,10 @@ index 971fc7f5f51ba82a7e8abafa6a5139c24a9aac0b..7f561ab6e56cd1749da8eff950080d3a b1 = 0; diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 8aaba38c7f4dc17c8536a0049be8bdea204f6481..b3500ce8c3c03239fafa529b386bb11610e922fa 100644 +index cd9a7d5f30e0ca11bd735bbc132a80a228ca4c2e..78deb4398cc45cf20d054dcbaacfe04366193ab5 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -515,6 +515,7 @@ public final class CraftServer implements Server { +@@ -516,6 +516,7 @@ public final class CraftServer implements Server { } node = clone; } @@ -94,7 +94,7 @@ index 8aaba38c7f4dc17c8536a0049be8bdea204f6481..b3500ce8c3c03239fafa529b386bb116 dispatcher.getDispatcher().getRoot().addChild(node); } else { -@@ -881,7 +882,13 @@ public final class CraftServer implements Server { +@@ -882,7 +883,13 @@ public final class CraftServer implements Server { // Spigot start if (!org.spigotmc.SpigotConfig.unknownCommandMessage.isEmpty()) { diff --git a/patches/server/0143-Basic-PlayerProfile-API.patch b/patches/server/0143-Basic-PlayerProfile-API.patch index e8d4892776..59ec78d758 100644 --- a/patches/server/0143-Basic-PlayerProfile-API.patch +++ b/patches/server/0143-Basic-PlayerProfile-API.patch @@ -631,10 +631,10 @@ index 4038bb76339d43f18770624bd7fecc79b8d7f2a9..2456edc11b29a92b1648937cd3dd6a9a String s1 = name.toLowerCase(Locale.ROOT); GameProfileCache.GameProfileInfo usercache_usercacheentry = (GameProfileCache.GameProfileInfo) this.profilesByName.get(s1); diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 39e51bbc941b7381c901304d69758b2bca2f02d1..21ca43d22bd9d09bdb03107eec568eb9208ea948 100644 +index 78deb4398cc45cf20d054dcbaacfe04366193ab5..435de87653033ed417d722b99b9acb8e3e68f915 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -252,6 +252,9 @@ import org.yaml.snakeyaml.error.MarkedYAMLException; +@@ -253,6 +253,9 @@ import org.yaml.snakeyaml.error.MarkedYAMLException; import net.md_5.bungee.api.chat.BaseComponent; // Spigot @@ -644,7 +644,7 @@ index 39e51bbc941b7381c901304d69758b2bca2f02d1..21ca43d22bd9d09bdb03107eec568eb9 public final class CraftServer implements Server { private final String serverName = "Paper"; // Paper private final String serverVersion; -@@ -293,6 +296,7 @@ public final class CraftServer implements Server { +@@ -294,6 +297,7 @@ public final class CraftServer implements Server { static { ConfigurationSerialization.registerClass(CraftOfflinePlayer.class); ConfigurationSerialization.registerClass(CraftPlayerProfile.class); @@ -652,7 +652,7 @@ index 39e51bbc941b7381c901304d69758b2bca2f02d1..21ca43d22bd9d09bdb03107eec568eb9 CraftItemFactory.instance(); } -@@ -2604,5 +2608,37 @@ public final class CraftServer implements Server { +@@ -2605,5 +2609,37 @@ public final class CraftServer implements Server { public boolean suggestPlayerNamesWhenNullTabCompletions() { return io.papermc.paper.configuration.GlobalConfiguration.get().commands.suggestPlayerNamesWhenNullTabCompletions; } diff --git a/patches/server/0144-Shoulder-Entities-Release-API.patch b/patches/server/0144-Shoulder-Entities-Release-API.patch index 3e774e14ea..8e5dfce6ac 100644 --- a/patches/server/0144-Shoulder-Entities-Release-API.patch +++ b/patches/server/0144-Shoulder-Entities-Release-API.patch @@ -58,10 +58,10 @@ index 11f1d8cc6f31b5a38db76ce411209a494c9e7e8a..0ed794b051cae00c71e94700dcd594da @Override public abstract boolean isSpectator(); diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java -index e38c32708ac7969dbc342989d2a5a767e26e4c3d..139c4310a31b6cc149de140751cb8bf3d8226010 100644 +index a26743682edcd9329d70ae1ff38310c8379f94e1..03a05d4d34181b34ca67bdbd6c66006071bdcdb4 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java -@@ -517,6 +517,32 @@ public class CraftHumanEntity extends CraftLivingEntity implements HumanEntity { +@@ -518,6 +518,32 @@ public class CraftHumanEntity extends CraftLivingEntity implements HumanEntity { this.getHandle().getCooldowns().addCooldown(CraftMagicNumbers.getItem(material), ticks); } diff --git a/patches/server/0147-Entity-fromMobSpawner.patch b/patches/server/0147-Entity-fromMobSpawner.patch index 76cd51f360..8496bc863f 100644 --- a/patches/server/0147-Entity-fromMobSpawner.patch +++ b/patches/server/0147-Entity-fromMobSpawner.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Entity#fromMobSpawner() diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index 7d839daeca968df2044bf2071bf1b5ff2b2aa3d6..9d82842982a387287a9c2de36f26a1fc80dd948a 100644 +index 1658a5263f0905c2938dae10b8d3d603fcd4bdca..579b0c70043a545798a6c2871a84c77a5f011744 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -383,6 +383,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -384,6 +384,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { // Spigot end // Paper start protected int numCollisions = 0; // Paper @@ -16,7 +16,7 @@ index 7d839daeca968df2044bf2071bf1b5ff2b2aa3d6..9d82842982a387287a9c2de36f26a1fc @javax.annotation.Nullable private org.bukkit.util.Vector origin; @javax.annotation.Nullable -@@ -2049,6 +2050,10 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -2050,6 +2051,10 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { } nbt.put("Paper.Origin", this.newDoubleList(origin.getX(), origin.getY(), origin.getZ())); } @@ -27,7 +27,7 @@ index 7d839daeca968df2044bf2071bf1b5ff2b2aa3d6..9d82842982a387287a9c2de36f26a1fc // Paper end return nbt; } catch (Throwable throwable) { -@@ -2189,6 +2194,8 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -2190,6 +2195,8 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { this.originWorld = originWorld; origin = new org.bukkit.util.Vector(originTag.getDouble(0), originTag.getDouble(1), originTag.getDouble(2)); } @@ -49,7 +49,7 @@ index 3d4e77327295344a5ef8d1fcde96f1ed2fecfbfa..faa4b1bfe8dcd2dcf897470964e7d061 if (org.bukkit.craftbukkit.event.CraftEventFactory.callSpawnerSpawnEvent(entity, pos).isCancelled()) { Entity vehicle = entity.getVehicle(); diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java -index 9318c47c9e52f8cde5c0ece1dc3723203a41e261..5a44b9a94992f3703ae1353dbaad40fe25e89a50 100644 +index e93fef1dc636e98ca11a942d7254256401eb3486..8f225b51c7d4792d97e4344ba66d5423aac55741 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java @@ -1297,5 +1297,10 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity { diff --git a/patches/server/0151-ProfileWhitelistVerifyEvent.patch b/patches/server/0151-ProfileWhitelistVerifyEvent.patch index c4fa0ed824..bdffadff3e 100644 --- a/patches/server/0151-ProfileWhitelistVerifyEvent.patch +++ b/patches/server/0151-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 d5d9579b3313299543f45d6ebf79bca6fddf09ff..41aef5f7b9ab7c97edd79e415264975fc01241b9 100644 +index ce2291fb34df531b783d34f8453128a7a01049e5..39cfbc7e109943878df038b7c3e26c64188104a3 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -637,9 +637,9 @@ public abstract class PlayerList { +@@ -639,9 +639,9 @@ public abstract class PlayerList { // return chatmessage; event.disallow(PlayerLoginEvent.Result.KICK_BANNED, PaperAdventure.asAdventure(ichatmutablecomponent)); // Paper - Adventure @@ -21,7 +21,7 @@ index d5d9579b3313299543f45d6ebf79bca6fddf09ff..41aef5f7b9ab7c97edd79e415264975f } else if (this.getIpBans().isBanned(socketaddress) && !this.getIpBans().get(socketaddress).hasExpired()) { IpBanListEntry ipbanentry = this.ipBans.get(socketaddress); -@@ -1023,7 +1023,23 @@ public abstract class PlayerList { +@@ -1025,7 +1025,23 @@ public abstract class PlayerList { } public boolean isWhiteListed(GameProfile profile) { diff --git a/patches/server/0152-Fix-this-stupid-bullshit.patch b/patches/server/0152-Fix-this-stupid-bullshit.patch index 7cd4a25b8a..2a06550ea8 100644 --- a/patches/server/0152-Fix-this-stupid-bullshit.patch +++ b/patches/server/0152-Fix-this-stupid-bullshit.patch @@ -31,12 +31,12 @@ index e43096e69a00f9ea96badd7c966443cfcf3e7b95..ac2b7b5161eaaca3620268ae865d6f2a Bootstrap.isBootstrapped = true; if (BuiltInRegistries.REGISTRY.keySet().isEmpty()) { diff --git a/src/main/java/org/bukkit/craftbukkit/Main.java b/src/main/java/org/bukkit/craftbukkit/Main.java -index beec3ebe4abc977885f93ef28aac3e834142d373..22aeca9eb61ccc0d2dc8ef3b0eb8ee242dd909bb 100644 +index 730f805790bcab15e97c56bc6fc92cf38e70f5b0..ac153f5f08e0acea60eb1ee01cd0ad3eb6ba410b 100644 --- a/src/main/java/org/bukkit/craftbukkit/Main.java +++ b/src/main/java/org/bukkit/craftbukkit/Main.java @@ -250,10 +250,12 @@ public class Main { Calendar deadline = Calendar.getInstance(); - deadline.add(Calendar.DAY_OF_YEAR, -7); + deadline.add(Calendar.DAY_OF_YEAR, -21); if (buildDate.before(deadline.getTime())) { - System.err.println("*** Error, this build is outdated ***"); + // Paper start - This is some stupid bullshit diff --git a/patches/server/0159-Add-PlayerJumpEvent.patch b/patches/server/0159-Add-PlayerJumpEvent.patch index bf9cbcd85b..18ccb44f88 100644 --- a/patches/server/0159-Add-PlayerJumpEvent.patch +++ b/patches/server/0159-Add-PlayerJumpEvent.patch @@ -5,10 +5,10 @@ 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 f42cf92eeb2c491a9bf75e67047c11edfc1185ab..b1b61ad583405459aff46a7b9964e927974f8a18 100644 +index 4578b9b3833f609787b7f1a1c1502b2b78e127d9..5d42ab9d3ad221aded255f8016a41d72f2c55f99 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -1288,7 +1288,34 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -1289,7 +1289,34 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic boolean flag = d8 > 0.0D; if (this.player.isOnGround() && !packet.isOnGround() && flag) { diff --git a/patches/server/0160-handle-ServerboundKeepAlivePacket-async.patch b/patches/server/0160-handle-ServerboundKeepAlivePacket-async.patch index 36c69be535..fbbf59b122 100644 --- a/patches/server/0160-handle-ServerboundKeepAlivePacket-async.patch +++ b/patches/server/0160-handle-ServerboundKeepAlivePacket-async.patch @@ -15,10 +15,10 @@ also adding some additional logging in order to help work out what is causing random disconnections for clients. diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index b1b61ad583405459aff46a7b9964e927974f8a18..65e6e0bdcb31e0f5a2d5bbd3aa2dc5666f96f441 100644 +index fd6900735b7d1544dcdbb2cd466d2cbb8de2d222..9ebbacca1818d246e999d08583e64fec265968ec 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -3138,14 +3138,18 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -3145,14 +3145,18 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic @Override public void handleKeepAlive(ServerboundKeepAlivePacket packet) { diff --git a/patches/server/0161-Expose-client-protocol-version-and-virtual-host.patch b/patches/server/0161-Expose-client-protocol-version-and-virtual-host.patch index ff41ce3631..e29258c71e 100644 --- a/patches/server/0161-Expose-client-protocol-version-and-virtual-host.patch +++ b/patches/server/0161-Expose-client-protocol-version-and-virtual-host.patch @@ -90,10 +90,10 @@ index 2be1bd39ee1341128f02e38afe5698b837735827..cca08b8c6e1e15f13326a2a7e33e7f32 @Override diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -index 6a12f14f7433ee13605f8dd8b7e0e8d127b915bd..e08cc548950b3ff14a720da693edc45981a4e964 100644 +index 0ae1f334eae66cfcca618655942c13809e38060b..a88c11fda59484d6d8d15dfca06ae1fe5d41259c 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -@@ -303,6 +303,20 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -307,6 +307,20 @@ public class CraftPlayer extends CraftHumanEntity implements Player { } } diff --git a/patches/server/0162-revert-serverside-behavior-of-keepalives.patch b/patches/server/0162-revert-serverside-behavior-of-keepalives.patch index 21e2338654..6362aa4721 100644 --- a/patches/server/0162-revert-serverside-behavior-of-keepalives.patch +++ b/patches/server/0162-revert-serverside-behavior-of-keepalives.patch @@ -17,10 +17,10 @@ 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 65e6e0bdcb31e0f5a2d5bbd3aa2dc5666f96f441..d39eb377a2fb12308eda12435e8bc5cbea13cac1 100644 +index fbab2e349560249382f87354449efadfedec1ed0..f6365bfdcd3c516ce1ce9ea780e0af3d4102a758 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -258,7 +258,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -259,7 +259,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic public ServerPlayer player; private int tickCount; private int ackBlockChangesUpTo = -1; @@ -29,7 +29,7 @@ index 65e6e0bdcb31e0f5a2d5bbd3aa2dc5666f96f441..d39eb377a2fb12308eda12435e8bc5cb private boolean keepAlivePending; private long keepAliveChallenge; // CraftBukkit start - multithreaded fields -@@ -296,6 +296,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -297,6 +297,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic private final LastSeenMessagesValidator lastSeenMessages; private final MessageSignatureCache messageSignatureCache; private final FutureChain chatMessageChain; @@ -37,7 +37,7 @@ index 65e6e0bdcb31e0f5a2d5bbd3aa2dc5666f96f441..d39eb377a2fb12308eda12435e8bc5cb public ServerGamePacketListenerImpl(MinecraftServer server, Connection connection, ServerPlayer player) { this.lastChatTimeStamp = new AtomicReference(Instant.EPOCH); -@@ -387,18 +388,25 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -388,18 +389,25 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic } this.server.getProfiler().push("keepAlive"); diff --git a/patches/server/0168-API-to-get-a-BlockState-without-a-snapshot.patch b/patches/server/0168-API-to-get-a-BlockState-without-a-snapshot.patch index bcd60ce32e..fbe9a5566e 100644 --- a/patches/server/0168-API-to-get-a-BlockState-without-a-snapshot.patch +++ b/patches/server/0168-API-to-get-a-BlockState-without-a-snapshot.patch @@ -51,10 +51,10 @@ index b701a1344db066b9368841f2377ee493514bf282..5768ff2c3e15c038d132c7ad391332fb return null; } diff --git a/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java b/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java -index 0e96f8d01b0499a4d4a8e9e11c2d94f54022bb6b..0951e0836ef16c99505c884ea80e5bd23873b7e6 100644 +index 4974e8366488446ec5bea16454e5b4fbb99a85c5..0cd58fd473f8cc6cb61798ceca972caef3f5c4d4 100644 --- a/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java +++ b/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java -@@ -331,6 +331,13 @@ public class CraftBlock implements Block { +@@ -330,6 +330,13 @@ public class CraftBlock implements Block { return CraftBlockStates.getBlockState(this); } diff --git a/patches/server/0169-AsyncTabCompleteEvent.patch b/patches/server/0169-AsyncTabCompleteEvent.patch index d5f24a67e5..4b245eb6a8 100644 --- a/patches/server/0169-AsyncTabCompleteEvent.patch +++ b/patches/server/0169-AsyncTabCompleteEvent.patch @@ -16,10 +16,10 @@ Also adds isCommand and getLocation to the sync TabCompleteEvent Co-authored-by: Aikar diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index d39eb377a2fb12308eda12435e8bc5cbea13cac1..215f2f196179304bc48633fcb6a8d93bf10c9f19 100644 +index f6365bfdcd3c516ce1ce9ea780e0af3d4102a758..0ad5aed5d1bbfb60d951db4b897e66af6c00ad4d 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -779,12 +779,16 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -780,12 +780,16 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic } @@ -38,7 +38,7 @@ index d39eb377a2fb12308eda12435e8bc5cbea13cac1..215f2f196179304bc48633fcb6a8d93b return; } // Paper start -@@ -795,18 +799,45 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -796,18 +800,45 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic } // Paper end // CraftBukkit end @@ -91,10 +91,10 @@ index d39eb377a2fb12308eda12435e8bc5cbea13cac1..215f2f196179304bc48633fcb6a8d93b @Override diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index a5b16370b59556f74d4c4275f8c19395c1ede60b..690cae728e1f3ef2670d1e7f3dec444833cc5716 100644 +index 435de87653033ed417d722b99b9acb8e3e68f915..de0b3ab49809702c2194f9d148909e5fcaf2ed2f 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -2095,7 +2095,7 @@ public final class CraftServer implements Server { +@@ -2096,7 +2096,7 @@ public final class CraftServer implements Server { offers = this.tabCompleteChat(player, message); } diff --git a/patches/server/0170-PlayerPickupExperienceEvent.patch b/patches/server/0170-PlayerPickupExperienceEvent.patch index aacac2b87b..272e78a563 100644 --- a/patches/server/0170-PlayerPickupExperienceEvent.patch +++ b/patches/server/0170-PlayerPickupExperienceEvent.patch @@ -6,15 +6,15 @@ Subject: [PATCH] PlayerPickupExperienceEvent Allows plugins to cancel a player picking up an experience orb diff --git a/src/main/java/net/minecraft/world/entity/ExperienceOrb.java b/src/main/java/net/minecraft/world/entity/ExperienceOrb.java -index f9488311524bb8ff8a5686763973c9ae0053668d..28949deb54e89742541c1a14e8b69bb5b13848a9 100644 +index e952aae85a80a020087c3697624c8c13eab3f914..c0c0090ab271dba1cc367e216fea3d9f73e5b887 100644 --- a/src/main/java/net/minecraft/world/entity/ExperienceOrb.java +++ b/src/main/java/net/minecraft/world/entity/ExperienceOrb.java -@@ -304,7 +304,7 @@ public class ExperienceOrb extends Entity { +@@ -305,7 +305,7 @@ public class ExperienceOrb extends Entity { @Override public void playerTouch(Player player) { if (!this.level.isClientSide) { - if (player.takeXpDelay == 0) { + if (player.takeXpDelay == 0 && new com.destroystokyo.paper.event.player.PlayerPickupExperienceEvent(((net.minecraft.server.level.ServerPlayer) player).getBukkitEntity(), (org.bukkit.entity.ExperienceOrb) this.getBukkitEntity()).callEvent()) { // Paper - player.takeXpDelay = 2; + player.takeXpDelay = CraftEventFactory.callPlayerXpCooldownEvent(player, 2, PlayerExpCooldownChangeEvent.ChangeReason.PICKUP_ORB).getNewCooldown(); // CraftBukkit - entityhuman.takeXpDelay = 2; player.take(this, 1); int i = this.repairPlayerItems(player, this.value); diff --git a/patches/server/0171-Ability-to-apply-mending-to-XP-API.patch b/patches/server/0171-Ability-to-apply-mending-to-XP-API.patch index e5c35fdcdf..b9e8a9132f 100644 --- a/patches/server/0171-Ability-to-apply-mending-to-XP-API.patch +++ b/patches/server/0171-Ability-to-apply-mending-to-XP-API.patch @@ -14,10 +14,10 @@ public net.minecraft.world.entity.ExperienceOrb durabilityToXp(I)I public net.minecraft.world.entity.ExperienceOrb xpToDurability(I)I diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -index e08cc548950b3ff14a720da693edc45981a4e964..6ad571cfab355ed4684661c4c8b77415865747e8 100644 +index a88c11fda59484d6d8d15dfca06ae1fe5d41259c..5cbbed3f8a82c7cb4158b236ffb2a0c20f3d5077 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -@@ -1527,7 +1527,37 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -1535,7 +1535,37 @@ public class CraftPlayer extends CraftHumanEntity implements Player { } @Override diff --git a/patches/server/0172-PlayerNaturallySpawnCreaturesEvent.patch b/patches/server/0172-PlayerNaturallySpawnCreaturesEvent.patch index f8e0c9f5b3..2a9a3263df 100644 --- a/patches/server/0172-PlayerNaturallySpawnCreaturesEvent.patch +++ b/patches/server/0172-PlayerNaturallySpawnCreaturesEvent.patch @@ -60,7 +60,7 @@ index 80d108ae7faf3fdcb024931e93032215935fe70b..c021733342c09adb04ce3f675209543f 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 9d04d3d1e24222bf255a1fc96761909574f67d66..67b0a9f8e8f122c406057c5db225fa6a03dd624c 100644 +index 7395cdcf618033f10482001cb9e2a7727e1e8bb2..8797bfcf1115fd7011aff9b1d3c0e5ae80aa6d8c 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 @@ @@ -70,7 +70,7 @@ index 9d04d3d1e24222bf255a1fc96761909574f67d66..67b0a9f8e8f122c406057c5db225fa6a import com.google.common.collect.Lists; import com.google.common.net.InetAddresses; import com.mojang.authlib.GameProfile; -@@ -258,6 +259,7 @@ public class ServerPlayer extends Player { +@@ -260,6 +261,7 @@ public class ServerPlayer extends Player { // CraftBukkit end public boolean isRealPlayer; // Paper public final com.destroystokyo.paper.util.misc.PooledLinkedHashSets.PooledObjectLinkedOpenHashSet cachedSingleHashSet; // Paper diff --git a/patches/server/0184-Player.setPlayerProfile-API.patch b/patches/server/0184-Player.setPlayerProfile-API.patch index ed2c493064..6019473305 100644 --- a/patches/server/0184-Player.setPlayerProfile-API.patch +++ b/patches/server/0184-Player.setPlayerProfile-API.patch @@ -9,10 +9,10 @@ This can be useful for changing name or skins after a player has logged in. public-f net.minecraft.world.entity.player.Player gameProfile diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 215f2f196179304bc48633fcb6a8d93bf10c9f19..f2c9270044c0bfdfa0bbbd64ff6436e7ace7fcf0 100644 +index 0ad5aed5d1bbfb60d951db4b897e66af6c00ad4d..560ac213e67d1099b7bc3f385bd8c024f7fd49df 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -1535,7 +1535,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -1536,7 +1536,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic this.internalTeleport(dest.getX(), dest.getY(), dest.getZ(), dest.getYaw(), dest.getPitch(), Collections.emptySet()); } @@ -55,7 +55,7 @@ index e7442952ef1f03969949014492a7ddc6d0796ba5..69a1852905dd4724c30ac8ab88c14251 public Server getServer() { diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -index 6ad571cfab355ed4684661c4c8b77415865747e8..38d4f7f99cdd7707033f65c5c875368cce422867 100644 +index 5cbbed3f8a82c7cb4158b236ffb2a0c20f3d5077..a6ecffe0d8f83425617be2a8fbf91e4fec250470 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java @@ -82,6 +82,7 @@ import net.minecraft.world.entity.ai.attributes.Attributes; @@ -66,7 +66,7 @@ index 6ad571cfab355ed4684661c4c8b77415865747e8..38d4f7f99cdd7707033f65c5c875368c import net.minecraft.world.level.block.entity.SignBlockEntity; import net.minecraft.world.level.border.BorderChangeListener; import net.minecraft.world.level.saveddata.maps.MapDecoration; -@@ -286,11 +287,6 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -290,11 +291,6 @@ public class CraftPlayer extends CraftHumanEntity implements Player { return server.getPlayer(getUniqueId()) != null; } @@ -78,7 +78,7 @@ index 6ad571cfab355ed4684661c4c8b77415865747e8..38d4f7f99cdd7707033f65c5c875368c @Override public InetSocketAddress getAddress() { if (this.getHandle().connection == null) return null; -@@ -1677,8 +1673,15 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -1685,8 +1681,15 @@ public class CraftPlayer extends CraftHumanEntity implements Player { private void untrackAndHideEntity(org.bukkit.entity.Entity entity) { // Remove this entity from the hidden player's EntityTrackerEntry @@ -95,7 +95,7 @@ index 6ad571cfab355ed4684661c4c8b77415865747e8..38d4f7f99cdd7707033f65c5c875368c ChunkMap.TrackedEntity entry = tracker.entityMap.get(other.getId()); if (entry != null) { entry.removePlayer(this.getHandle()); -@@ -1691,8 +1694,6 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -1699,8 +1702,6 @@ public class CraftPlayer extends CraftHumanEntity implements Player { this.getHandle().connection.send(new ClientboundPlayerInfoRemovePacket(List.of(otherPlayer.getUUID()))); } } @@ -104,7 +104,7 @@ index 6ad571cfab355ed4684661c4c8b77415865747e8..38d4f7f99cdd7707033f65c5c875368c } void resetAndHideEntity(org.bukkit.entity.Entity entity) { -@@ -1769,8 +1770,38 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -1777,8 +1778,38 @@ public class CraftPlayer extends CraftHumanEntity implements Player { if (entry != null && !entry.seenBy.contains(this.getHandle().connection)) { entry.updatePlayer(this.getHandle()); } @@ -144,7 +144,7 @@ index 6ad571cfab355ed4684661c4c8b77415865747e8..38d4f7f99cdd7707033f65c5c875368c } void resetAndShowEntity(org.bukkit.entity.Entity entity) { -@@ -1783,6 +1814,36 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -1791,6 +1822,36 @@ public class CraftPlayer extends CraftHumanEntity implements Player { this.trackAndShowEntity(entity); } } diff --git a/patches/server/0185-getPlayerUniqueId-API.patch b/patches/server/0185-getPlayerUniqueId-API.patch index 44dacb68a1..676489a477 100644 --- a/patches/server/0185-getPlayerUniqueId-API.patch +++ b/patches/server/0185-getPlayerUniqueId-API.patch @@ -9,10 +9,10 @@ In Offline Mode, will return an Offline UUID This is a more performant way to obtain a UUID for a name than loading an OfflinePlayer diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 60eded2e31c5f353980e574e863e3ad0397c57b1..d770063b7e17c55b7e13e9ea44c05870cadb9fe7 100644 +index de0b3ab49809702c2194f9d148909e5fcaf2ed2f..f6e7cfc4d86dfdc0ff87642fbc7af330df8eb725 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -1717,6 +1717,25 @@ public final class CraftServer implements Server { +@@ -1718,6 +1718,25 @@ public final class CraftServer implements Server { return recipients.size(); } diff --git a/patches/server/0189-Flag-to-disable-the-channel-limit.patch b/patches/server/0189-Flag-to-disable-the-channel-limit.patch index e007826261..0268c68335 100644 --- a/patches/server/0189-Flag-to-disable-the-channel-limit.patch +++ b/patches/server/0189-Flag-to-disable-the-channel-limit.patch @@ -9,10 +9,10 @@ e.g. servers which allow and support the usage of mod packs. provide an optional flag to disable this check, at your own risk. diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -index 38d4f7f99cdd7707033f65c5c875368cce422867..dd0eec95e1a5ba17cb11607ef632fe156e6fad72 100644 +index a6ecffe0d8f83425617be2a8fbf91e4fec250470..eae9f51464d6bcb26178ac79f7026154c12b6bc9 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -@@ -177,6 +177,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -181,6 +181,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player { // Paper start private org.bukkit.event.player.PlayerResourcePackStatusEvent.Status resourcePackStatus; private String resourcePackHash; @@ -20,7 +20,7 @@ index 38d4f7f99cdd7707033f65c5c875368cce422867..dd0eec95e1a5ba17cb11607ef632fe15 // Paper end public CraftPlayer(CraftServer server, ServerPlayer entity) { -@@ -2052,7 +2053,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -2060,7 +2061,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player { // Paper end public void addChannel(String channel) { diff --git a/patches/server/0190-Add-openSign-method-to-HumanEntity.patch b/patches/server/0190-Add-openSign-method-to-HumanEntity.patch index 579b73b9c6..ec647635b1 100644 --- a/patches/server/0190-Add-openSign-method-to-HumanEntity.patch +++ b/patches/server/0190-Add-openSign-method-to-HumanEntity.patch @@ -5,7 +5,7 @@ Subject: [PATCH] Add openSign method to HumanEntity diff --git a/src/main/java/org/bukkit/craftbukkit/block/CraftSign.java b/src/main/java/org/bukkit/craftbukkit/block/CraftSign.java -index 749f8c6eb39e9cedeec472fc176b6a2a17900201..cdc9474d37028324d39037a456be07fd4f576a6e 100644 +index 9fd6a05fb8022c5e4e3d67f9b0e9df3f477ea637..32592483dfb477501a72360b6b9bc497a608ce0a 100644 --- a/src/main/java/org/bukkit/craftbukkit/block/CraftSign.java +++ b/src/main/java/org/bukkit/craftbukkit/block/CraftSign.java @@ -117,15 +117,15 @@ public class CraftSign extends CraftBlockEntityState< @@ -28,10 +28,10 @@ index 749f8c6eb39e9cedeec472fc176b6a2a17900201..cdc9474d37028324d39037a456be07fd // Paper start diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java -index 139c4310a31b6cc149de140751cb8bf3d8226010..787ccb37a39bb506cf9fd8d54cf772b346981f85 100644 +index 03a05d4d34181b34ca67bdbd6c66006071bdcdb4..04fe1bd9254b084eacbbca0e2a8a1ac100d17f12 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java -@@ -627,6 +627,12 @@ public class CraftHumanEntity extends CraftLivingEntity implements HumanEntity { +@@ -628,6 +628,12 @@ public class CraftHumanEntity extends CraftLivingEntity implements HumanEntity { } } diff --git a/patches/server/0192-Fix-exploit-that-allowed-colored-signs-to-be-created.patch b/patches/server/0192-Fix-exploit-that-allowed-colored-signs-to-be-created.patch index 0c8e7b5cf2..22ffad4aa5 100644 --- a/patches/server/0192-Fix-exploit-that-allowed-colored-signs-to-be-created.patch +++ b/patches/server/0192-Fix-exploit-that-allowed-colored-signs-to-be-created.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Fix exploit that allowed colored signs to be created diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index f2c9270044c0bfdfa0bbbd64ff6436e7ace7fcf0..94e79e72886b97b70fe4dbc2abf6830efd19f37b 100644 +index d9c441f600a1f981a9dad075cba9d1d9b28e1aa0..bed9c637d7d26b758ab587eb5cdf2c7f7fb7b356 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -3152,9 +3152,9 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -3159,9 +3159,9 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic FilteredText filteredtext = (FilteredText) signText.get(i); if (this.player.isTextFilteringEnabled()) { diff --git a/patches/server/0196-Expand-World.spawnParticle-API-and-add-Builder.patch b/patches/server/0196-Expand-World.spawnParticle-API-and-add-Builder.patch index c8634bdeea..ce5b0ad32c 100644 --- a/patches/server/0196-Expand-World.spawnParticle-API-and-add-Builder.patch +++ b/patches/server/0196-Expand-World.spawnParticle-API-and-add-Builder.patch @@ -34,10 +34,10 @@ index d273673978c8270f2e0719412372039406e31f5e..65110445ff8a245742c4f7a7055f544f if (this.sendParticles(entityplayer, force, d0, d1, d2, packetplayoutworldparticles)) { // CraftBukkit diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -index 857fac09453f99a56d41a3a57a5f36c22496a643..323bd3b006f01505f2912ab7e07cd80798a1f054 100644 +index 292e810febf9272688ecafdb8c7ed2e8a97ae67b..32ef1eb646a33a022c0fffcff2a293091288c3e2 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -@@ -1835,11 +1835,17 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -1821,11 +1821,17 @@ public class CraftWorld extends CraftRegionAccessor implements World { @Override public void spawnParticle(Particle particle, double x, double y, double z, int count, double offsetX, double offsetY, double offsetZ, double extra, T data, boolean force) { diff --git a/patches/server/0201-Allow-spawning-Item-entities-with-World.spawnEntity.patch b/patches/server/0201-Allow-spawning-Item-entities-with-World.spawnEntity.patch index bd37edd8c5..e1cb9142a0 100644 --- a/patches/server/0201-Allow-spawning-Item-entities-with-World.spawnEntity.patch +++ b/patches/server/0201-Allow-spawning-Item-entities-with-World.spawnEntity.patch @@ -8,10 +8,10 @@ This API has more capabilities than .dropItem with the Consumer function Item can be set inside of the Consumer pre spawn function. diff --git a/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java b/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java -index f8399f63d7b511dfeb7a7ee9d24f848afd16e8c1..2c0773fec42c7c6223e2c300086058939ec32a52 100644 +index 7c5d5355237bc00f1c8c8433351ca7a9938f2e8b..d9be32a5141d7b322f31b61c685ca712cdb45182 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java -@@ -572,6 +572,10 @@ public abstract class CraftRegionAccessor implements RegionAccessor { +@@ -593,6 +593,10 @@ public abstract class CraftRegionAccessor implements RegionAccessor { entity = net.minecraft.world.entity.EntityType.BOAT.create(world); } entity.moveTo(x, y, z, yaw, pitch); diff --git a/patches/server/0204-Implement-EntityTeleportEndGatewayEvent.patch b/patches/server/0204-Implement-EntityTeleportEndGatewayEvent.patch index c7fdc8ab93..e8767054d5 100644 --- a/patches/server/0204-Implement-EntityTeleportEndGatewayEvent.patch +++ b/patches/server/0204-Implement-EntityTeleportEndGatewayEvent.patch @@ -5,7 +5,7 @@ Subject: [PATCH] Implement EntityTeleportEndGatewayEvent diff --git a/src/main/java/net/minecraft/world/level/block/entity/TheEndGatewayBlockEntity.java b/src/main/java/net/minecraft/world/level/block/entity/TheEndGatewayBlockEntity.java -index 7d2b15edbd1a6bf663c29b7bc63c73d34fefd999..c7de74b7fcfb5f4d8adbe7e703087a03d9d9056d 100644 +index 5fd074909f18f9b865ac1bcbed3711430e5349b0..757be65a8b6a85be91deeeea895e683eb107e809 100644 --- a/src/main/java/net/minecraft/world/level/block/entity/TheEndGatewayBlockEntity.java +++ b/src/main/java/net/minecraft/world/level/block/entity/TheEndGatewayBlockEntity.java @@ -225,9 +225,20 @@ public class TheEndGatewayBlockEntity extends TheEndPortalBlockEntity { @@ -14,7 +14,7 @@ index 7d2b15edbd1a6bf663c29b7bc63c73d34fefd999..c7de74b7fcfb5f4d8adbe7e703087a03 // CraftBukkit end + // Paper start - EntityTeleportEndGatewayEvent - replicated from above + org.bukkit.craftbukkit.entity.CraftEntity bukkitEntity = entity.getBukkitEntity(); -+ org.bukkit.Location location = new Location(world.getWorld(), (double) blockposition1.getX() + 0.5D, (double) blockposition1.getY() + 0.5D, (double) blockposition1.getZ() + 0.5D); ++ org.bukkit.Location location = new org.bukkit.Location(world.getWorld(), (double) blockposition1.getX() + 0.5D, (double) blockposition1.getY() + 0.5D, (double) blockposition1.getZ() + 0.5D); + location.setPitch(bukkitEntity.getLocation().getPitch()); + location.setYaw(bukkitEntity.getLocation().getYaw()); + diff --git a/patches/server/0212-Implement-EntityKnockbackByEntityEvent-and-EntityPus.patch b/patches/server/0212-Implement-EntityKnockbackByEntityEvent-and-EntityPus.patch index fa53cb6071..96dd04011d 100644 --- a/patches/server/0212-Implement-EntityKnockbackByEntityEvent-and-EntityPus.patch +++ b/patches/server/0212-Implement-EntityKnockbackByEntityEvent-and-EntityPus.patch @@ -9,10 +9,10 @@ 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 fbceeb5db8601d58cd449e80e423c1eeaedbcaab..213304a9ad145a2fecead78b82f441ae12825e4e 100644 +index 579b0c70043a545798a6c2871a84c77a5f011744..8b3beb78cf48ea7a23865ddc16c8421ecb047aba 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -1774,8 +1774,17 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -1775,8 +1775,17 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { } public void push(double deltaX, double deltaY, double deltaZ) { diff --git a/patches/server/0213-Expand-Explosions-API.patch b/patches/server/0213-Expand-Explosions-API.patch index 0adbb00c23..c6c17c8ad6 100644 --- a/patches/server/0213-Expand-Explosions-API.patch +++ b/patches/server/0213-Expand-Explosions-API.patch @@ -6,10 +6,10 @@ Subject: [PATCH] Expand Explosions API Add Entity as a Source capability, and add more API choices, and on Location. diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -index 323bd3b006f01505f2912ab7e07cd80798a1f054..920579a1061cd8b46d920e48cea8ac0d6c986ad5 100644 +index 32ef1eb646a33a022c0fffcff2a293091288c3e2..82a3240169b5d9a5c8d6cbb17a82e4a7457bf994 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -@@ -713,6 +713,12 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -709,6 +709,12 @@ public class CraftWorld extends CraftRegionAccessor implements World { public boolean createExplosion(double x, double y, double z, float power, boolean setFire, boolean breakBlocks, Entity source) { return !this.world.explode(source == null ? null : ((CraftEntity) source).getHandle(), x, y, z, power, setFire, breakBlocks ? net.minecraft.world.level.Level.ExplosionInteraction.MOB : net.minecraft.world.level.Level.ExplosionInteraction.NONE).wasCanceled; } diff --git a/patches/server/0217-Implement-World.getEntity-UUID-API.patch b/patches/server/0217-Implement-World.getEntity-UUID-API.patch index 7d39614126..78bc95bc0f 100644 --- a/patches/server/0217-Implement-World.getEntity-UUID-API.patch +++ b/patches/server/0217-Implement-World.getEntity-UUID-API.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Implement World.getEntity(UUID) API diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -index 920579a1061cd8b46d920e48cea8ac0d6c986ad5..ea55b206eb94a3349585435f6e7184fffccd7bd3 100644 +index 82a3240169b5d9a5c8d6cbb17a82e4a7457bf994..c178f57d5e45a6d2c91f0476ccdb3cb690a3200c 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -@@ -1047,6 +1047,15 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -1033,6 +1033,15 @@ public class CraftWorld extends CraftRegionAccessor implements World { return list; } diff --git a/patches/server/0218-InventoryCloseEvent-Reason-API.patch b/patches/server/0218-InventoryCloseEvent-Reason-API.patch index c7685e75a6..d4570886f2 100644 --- a/patches/server/0218-InventoryCloseEvent-Reason-API.patch +++ b/patches/server/0218-InventoryCloseEvent-Reason-API.patch @@ -29,10 +29,10 @@ index 65110445ff8a245742c4f7a7055f544ff6344f75..718a403799246228e085280cb539236b } // Spigot End diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java -index 67b0a9f8e8f122c406057c5db225fa6a03dd624c..9e4c827bba4c87595db8cb8896b77558b3feadf5 100644 +index 8797bfcf1115fd7011aff9b1d3c0e5ae80aa6d8c..57ab89118811cb0825435b9bdde8f5aeee681d75 100644 --- a/src/main/java/net/minecraft/server/level/ServerPlayer.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java -@@ -639,7 +639,7 @@ public class ServerPlayer extends Player { +@@ -641,7 +641,7 @@ public class ServerPlayer extends Player { } // Paper end if (!this.level.isClientSide && !this.containerMenu.stillValid(this)) { @@ -41,7 +41,7 @@ index 67b0a9f8e8f122c406057c5db225fa6a03dd624c..9e4c827bba4c87595db8cb8896b77558 this.containerMenu = this.inventoryMenu; } -@@ -832,7 +832,7 @@ public class ServerPlayer extends Player { +@@ -834,7 +834,7 @@ public class ServerPlayer extends Player { // SPIGOT-943 - only call if they have an inventory open if (this.containerMenu != this.inventoryMenu) { @@ -50,7 +50,7 @@ index 67b0a9f8e8f122c406057c5db225fa6a03dd624c..9e4c827bba4c87595db8cb8896b77558 } net.kyori.adventure.text.Component deathMessage = event.deathMessage() != null ? event.deathMessage() : net.kyori.adventure.text.Component.empty(); // Paper - Adventure -@@ -1451,7 +1451,7 @@ public class ServerPlayer extends Player { +@@ -1453,7 +1453,7 @@ public class ServerPlayer extends Player { } // CraftBukkit end if (this.containerMenu != this.inventoryMenu) { @@ -59,7 +59,7 @@ index 67b0a9f8e8f122c406057c5db225fa6a03dd624c..9e4c827bba4c87595db8cb8896b77558 } // this.nextContainerCounter(); // CraftBukkit - moved up -@@ -1479,7 +1479,13 @@ public class ServerPlayer extends Player { +@@ -1481,7 +1481,13 @@ public class ServerPlayer extends Player { @Override public void closeContainer() { @@ -75,10 +75,10 @@ index 67b0a9f8e8f122c406057c5db225fa6a03dd624c..9e4c827bba4c87595db8cb8896b77558 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 94e79e72886b97b70fe4dbc2abf6830efd19f37b..473b00fcc73097eab908b1dce198a96de38b5530 100644 +index bed9c637d7d26b758ab587eb5cdf2c7f7fb7b356..0f3b223522872aeaacd7f571f60b9f01639820d7 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -219,6 +219,7 @@ import org.bukkit.event.inventory.ClickType; +@@ -220,6 +220,7 @@ import org.bukkit.event.inventory.ClickType; import org.bukkit.event.inventory.CraftItemEvent; import org.bukkit.event.inventory.InventoryAction; import org.bukkit.event.inventory.InventoryClickEvent; @@ -86,7 +86,7 @@ index 94e79e72886b97b70fe4dbc2abf6830efd19f37b..473b00fcc73097eab908b1dce198a96d import org.bukkit.event.inventory.InventoryCreativeEvent; import org.bukkit.event.inventory.InventoryType.SlotType; import org.bukkit.event.inventory.SmithItemEvent; -@@ -2673,10 +2674,15 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -2680,10 +2681,15 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic @Override public void handleContainerClose(ServerboundContainerClosePacket packet) { @@ -104,10 +104,10 @@ index 94e79e72886b97b70fe4dbc2abf6830efd19f37b..473b00fcc73097eab908b1dce198a96d 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 41aef5f7b9ab7c97edd79e415264975fc01241b9..c3c2d7a035e35135a422cfec3513b6a7a268e1e1 100644 +index 39cfbc7e109943878df038b7c3e26c64188104a3..bfc81327f0c64ef3bd2e8ba218f6a4970553a309 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -524,7 +524,7 @@ public abstract class PlayerList { +@@ -526,7 +526,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) { @@ -144,10 +144,10 @@ index 2961e08fc315a0d5f3b95de9d127948da07e66c8..9c12fc197c5367a35acda4155707c602 this.containerMenu = this.inventoryMenu; } diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java -index 787ccb37a39bb506cf9fd8d54cf772b346981f85..f5b3190ffb9e9f92977afc9e40ddfa155d054865 100644 +index 04fe1bd9254b084eacbbca0e2a8a1ac100d17f12..77314674a1f66a514f8f5a0fef5ca188b5af0b6a 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java -@@ -377,7 +377,7 @@ public class CraftHumanEntity extends CraftLivingEntity implements HumanEntity { +@@ -378,7 +378,7 @@ public class CraftHumanEntity extends CraftLivingEntity implements HumanEntity { if (((ServerPlayer) this.getHandle()).connection == null) return; if (this.getHandle().containerMenu != this.getHandle().inventoryMenu) { // fire INVENTORY_CLOSE if one already open @@ -156,7 +156,7 @@ index 787ccb37a39bb506cf9fd8d54cf772b346981f85..f5b3190ffb9e9f92977afc9e40ddfa15 } ServerPlayer player = (ServerPlayer) this.getHandle(); AbstractContainerMenu container; -@@ -447,8 +447,14 @@ public class CraftHumanEntity extends CraftLivingEntity implements HumanEntity { +@@ -448,8 +448,14 @@ public class CraftHumanEntity extends CraftLivingEntity implements HumanEntity { @Override public void closeInventory() { @@ -173,10 +173,10 @@ index 787ccb37a39bb506cf9fd8d54cf772b346981f85..f5b3190ffb9e9f92977afc9e40ddfa15 @Override public boolean isBlocking() { diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -index dd0eec95e1a5ba17cb11607ef632fe156e6fad72..1ce97fdbe5ac2d13ded50493865eff4d7919b66a 100644 +index eae9f51464d6bcb26178ac79f7026154c12b6bc9..db79410d56e0defeb710203f9332dff6d5418ee4 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -@@ -1240,7 +1240,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -1238,7 +1238,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player { // Close any foreign inventory if (this.getHandle().containerMenu != this.getHandle().inventoryMenu) { @@ -186,10 +186,10 @@ index dd0eec95e1a5ba17cb11607ef632fe156e6fad72..1ce97fdbe5ac2d13ded50493865eff4d // Check if the fromWorld and toWorld are the same. diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java -index fea90633f10bad7498f8f5e90093eee2a09df549..8a856d7c65e1002d32fa5b2619606e9d08d7286b 100644 +index 64ddab11cc8bd9e8063450f2bec22a4277e49414..c50cfe19bd40fb75fc66767d2760eb3b5852c4c8 100644 --- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java +++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java -@@ -1252,7 +1252,7 @@ public class CraftEventFactory { +@@ -1261,7 +1261,7 @@ public class CraftEventFactory { public static AbstractContainerMenu callInventoryOpenEvent(ServerPlayer player, AbstractContainerMenu container, boolean cancelled) { if (player.containerMenu != player.inventoryMenu) { // fire INVENTORY_CLOSE if one already open @@ -198,7 +198,7 @@ index fea90633f10bad7498f8f5e90093eee2a09df549..8a856d7c65e1002d32fa5b2619606e9d } CraftServer server = player.level.getCraftServer(); -@@ -1426,8 +1426,18 @@ public class CraftEventFactory { +@@ -1435,8 +1435,18 @@ public class CraftEventFactory { return event; } diff --git a/patches/server/0219-Vex-get-setSummoner-API.patch b/patches/server/0219-Vex-get-setSummoner-API.patch index b39cab89d2..61ba4a29fe 100644 --- a/patches/server/0219-Vex-get-setSummoner-API.patch +++ b/patches/server/0219-Vex-get-setSummoner-API.patch @@ -9,10 +9,10 @@ Allow setting the vex's summoner Co-authored-by: BillyGalbreath diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftVex.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftVex.java -index fecb1e6b84fed241d1028ef24660804e5518ea3b..2ba16e33dd21c3c72cb12244aa78c59bf53e76d1 100644 +index ba8f9d96029aa26e097abb56963261aa707ef645..50b07045cd17a7576a436c64662ad039d4aa2132 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftVex.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftVex.java -@@ -18,6 +18,19 @@ public class CraftVex extends CraftMonster implements Vex { +@@ -19,6 +19,19 @@ public class CraftVex extends CraftMonster implements Vex { return (net.minecraft.world.entity.monster.Vex) super.getHandle(); } diff --git a/patches/server/0220-Refresh-player-inventory-when-cancelling-PlayerInter.patch b/patches/server/0220-Refresh-player-inventory-when-cancelling-PlayerInter.patch index 36219f3656..655c368ca5 100644 --- a/patches/server/0220-Refresh-player-inventory-when-cancelling-PlayerInter.patch +++ b/patches/server/0220-Refresh-player-inventory-when-cancelling-PlayerInter.patch @@ -16,10 +16,10 @@ Refresh the player inventory when PlayerInteractEntityEvent is cancelled to avoid this problem. diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 473b00fcc73097eab908b1dce198a96de38b5530..3ba4ff3712716daa584265b1132901fb30d39eaf 100644 +index 0f3b223522872aeaacd7f571f60b9f01639820d7..c425dc285b6fe42093fb1c8f8fb4d512ec071929 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -2555,6 +2555,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -2562,6 +2562,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic } if (event.isCancelled()) { diff --git a/patches/server/0222-add-more-information-to-Entity.toString.patch b/patches/server/0222-add-more-information-to-Entity.toString.patch index 0639d32ba8..fe3ae30a1e 100644 --- a/patches/server/0222-add-more-information-to-Entity.toString.patch +++ b/patches/server/0222-add-more-information-to-Entity.toString.patch @@ -6,10 +6,10 @@ 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 7b4ceab1d9988573f21df3fb1a85a640f060d3af..c330d8e6894d9a4b6cabd36ccda7443bee33407e 100644 +index 8b3beb78cf48ea7a23865ddc16c8421ecb047aba..8d3712314a1674470bad90895e86bb34d923dcaa 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -3024,7 +3024,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -3025,7 +3025,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { public String toString() { String s = this.level == null ? "~NULL~" : this.level.toString(); diff --git a/patches/server/0228-Vanished-players-don-t-have-rights.patch b/patches/server/0228-Vanished-players-don-t-have-rights.patch index 3e1b81858d..f2b8dd2ac7 100644 --- a/patches/server/0228-Vanished-players-don-t-have-rights.patch +++ b/patches/server/0228-Vanished-players-don-t-have-rights.patch @@ -89,10 +89,10 @@ index f07e70ab26fffaec5055a7dd2571dc4d29c66d35..754e1667aadef89bbaccebc0f437197b public boolean isClientSide() { return this.isClientSide; diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java -index 8a856d7c65e1002d32fa5b2619606e9d08d7286b..171f2f3187b0f1d2e86c884cb566d23c048c337b 100644 +index c50cfe19bd40fb75fc66767d2760eb3b5852c4c8..ff1108579b9f8bb867be02a07784c645d0f4d037 100644 --- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java +++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java -@@ -1289,6 +1289,14 @@ public class CraftEventFactory { +@@ -1298,6 +1298,14 @@ public class CraftEventFactory { Projectile projectile = (Projectile) entity.getBukkitEntity(); org.bukkit.entity.Entity collided = position.getEntity().getBukkitEntity(); com.destroystokyo.paper.event.entity.ProjectileCollideEvent event = new com.destroystokyo.paper.event.entity.ProjectileCollideEvent(projectile, collided); diff --git a/patches/server/0234-Add-TNTPrimeEvent.patch b/patches/server/0234-Add-TNTPrimeEvent.patch index 0bd63955cc..fe2676104d 100644 --- a/patches/server/0234-Add-TNTPrimeEvent.patch +++ b/patches/server/0234-Add-TNTPrimeEvent.patch @@ -21,10 +21,10 @@ index 55a8ab31a26a16adbe78b3b34366dc81851c02d4..da1e60206f300d64f68f5aedeba52a16 this.level.removeBlock(blockposition, false); diff --git a/src/main/java/net/minecraft/world/level/block/FireBlock.java b/src/main/java/net/minecraft/world/level/block/FireBlock.java -index 48b30ead02b0379190f794c4f245affb684aa5b4..33ece83c6d41c65042356c44eee2c76934c07d0b 100644 +index 9b3764fb06c186d1f971f6c7468bed4d7159987f..d16bec52ad650670927093efb9943da1dd5eac3f 100644 --- a/src/main/java/net/minecraft/world/level/block/FireBlock.java +++ b/src/main/java/net/minecraft/world/level/block/FireBlock.java -@@ -291,12 +291,19 @@ public class FireBlock extends BaseFireBlock { +@@ -295,12 +295,19 @@ public class FireBlock extends BaseFireBlock { world.setBlock(blockposition, this.getStateWithAge(world, blockposition, l), 3); } else { @@ -46,59 +46,63 @@ index 48b30ead02b0379190f794c4f245affb684aa5b4..33ece83c6d41c65042356c44eee2c769 } } diff --git a/src/main/java/net/minecraft/world/level/block/TntBlock.java b/src/main/java/net/minecraft/world/level/block/TntBlock.java -index f5b685cb678f523c1c07d72b818ada93af64840a..ade39e877edbb07082bb2d87e00ae4bfb6ab1c8f 100644 +index dab8fdee6a3165a0e0a8aa3e381526cb7c174a88..1a8215b4fe6b12e53d2a83c866bc06dec229b4f8 100644 --- a/src/main/java/net/minecraft/world/level/block/TntBlock.java +++ b/src/main/java/net/minecraft/world/level/block/TntBlock.java -@@ -38,6 +38,11 @@ public class TntBlock extends Block { +@@ -42,6 +42,12 @@ public class TntBlock extends Block { public void onPlace(BlockState state, Level world, BlockPos pos, BlockState oldState, boolean notify) { if (!oldState.is(state.getBlock())) { - if (world.hasNeighborSignal(pos)) { + if (world.hasNeighborSignal(pos) && CraftEventFactory.callTNTPrimeEvent(world, pos, PrimeCause.REDSTONE, null, null)) { // CraftBukkit - TNTPrimeEvent + // Paper start - TNTPrimeEvent -+ org.bukkit.block.Block tntBlock = io.papermc.paper.util.MCUtil.toBukkitBlock(world, pos);; -+ if(!new com.destroystokyo.paper.event.block.TNTPrimeEvent(tntBlock, com.destroystokyo.paper.event.block.TNTPrimeEvent.PrimeReason.REDSTONE, null).callEvent()) ++ org.bukkit.block.Block tntBlock = io.papermc.paper.util.MCUtil.toBukkitBlock(world, pos); ++ if (!new com.destroystokyo.paper.event.block.TNTPrimeEvent(tntBlock, com.destroystokyo.paper.event.block.TNTPrimeEvent.PrimeReason.REDSTONE, null).callEvent()) { + return; ++ } + // Paper end TntBlock.explode(world, pos); world.removeBlock(pos, false); } -@@ -48,6 +53,11 @@ public class TntBlock extends Block { +@@ -52,6 +58,12 @@ public class TntBlock extends Block { @Override public void neighborChanged(BlockState state, Level world, BlockPos pos, Block sourceBlock, BlockPos sourcePos, boolean notify) { - if (world.hasNeighborSignal(pos)) { + if (world.hasNeighborSignal(pos) && CraftEventFactory.callTNTPrimeEvent(world, pos, PrimeCause.REDSTONE, null, sourcePos)) { // CraftBukkit - TNTPrimeEvent + // Paper start - TNTPrimeEvent -+ org.bukkit.block.Block tntBlock = io.papermc.paper.util.MCUtil.toBukkitBlock(world, pos);; -+ if(!new com.destroystokyo.paper.event.block.TNTPrimeEvent(tntBlock, com.destroystokyo.paper.event.block.TNTPrimeEvent.PrimeReason.REDSTONE, null).callEvent()) ++ org.bukkit.block.Block tntBlock = io.papermc.paper.util.MCUtil.toBukkitBlock(world, pos); ++ if (!new com.destroystokyo.paper.event.block.TNTPrimeEvent(tntBlock, com.destroystokyo.paper.event.block.TNTPrimeEvent.PrimeReason.REDSTONE, null).callEvent()) { + return; ++ } + // Paper end TntBlock.explode(world, pos); world.removeBlock(pos, false); } -@@ -66,6 +76,12 @@ public class TntBlock extends Block { +@@ -70,6 +82,13 @@ public class TntBlock extends Block { @Override public void wasExploded(Level world, BlockPos pos, Explosion explosion) { if (!world.isClientSide) { + // Paper start - TNTPrimeEvent + org.bukkit.block.Block tntBlock = io.papermc.paper.util.MCUtil.toBukkitBlock(world, pos); + org.bukkit.entity.Entity source = explosion.source != null ? explosion.source.getBukkitEntity() : null; -+ if(!new com.destroystokyo.paper.event.block.TNTPrimeEvent(tntBlock, com.destroystokyo.paper.event.block.TNTPrimeEvent.PrimeReason.EXPLOSION, source).callEvent()) ++ if (!new com.destroystokyo.paper.event.block.TNTPrimeEvent(tntBlock, com.destroystokyo.paper.event.block.TNTPrimeEvent.PrimeReason.EXPLOSION, source).callEvent()) { + return; ++ } + // Paper end PrimedTnt entitytntprimed = new PrimedTnt(world, (double) pos.getX() + 0.5D, (double) pos.getY(), (double) pos.getZ() + 0.5D, explosion.getIndirectSourceEntity()); int i = entitytntprimed.getFuse(); -@@ -95,6 +111,11 @@ public class TntBlock extends Block { - if (!itemstack.is(Items.FLINT_AND_STEEL) && !itemstack.is(Items.FIRE_CHARGE)) { - return super.use(state, world, pos, player, hand, hit); - } else { +@@ -104,6 +123,12 @@ public class TntBlock extends Block { + return InteractionResult.CONSUME; + } + // CraftBukkit end + // Paper start - TNTPrimeEvent + org.bukkit.block.Block tntBlock = io.papermc.paper.util.MCUtil.toBukkitBlock(world, pos); -+ if(!new com.destroystokyo.paper.event.block.TNTPrimeEvent(tntBlock, com.destroystokyo.paper.event.block.TNTPrimeEvent.PrimeReason.ITEM, player.getBukkitEntity()).callEvent()) ++ if (!new com.destroystokyo.paper.event.block.TNTPrimeEvent(tntBlock, com.destroystokyo.paper.event.block.TNTPrimeEvent.PrimeReason.ITEM, player.getBukkitEntity()).callEvent()) { + return InteractionResult.FAIL; ++ } + // Paper end TntBlock.explode(world, pos, player); world.setBlock(pos, Blocks.AIR.defaultBlockState(), 11); Item item = itemstack.getItem(); -@@ -126,6 +147,12 @@ public class TntBlock extends Block { +@@ -135,6 +160,12 @@ public class TntBlock extends Block { return; } // CraftBukkit end diff --git a/patches/server/0235-Break-up-and-make-tab-spam-limits-configurable.patch b/patches/server/0235-Break-up-and-make-tab-spam-limits-configurable.patch index 3aaf9f1d92..cc05eb2d65 100644 --- a/patches/server/0235-Break-up-and-make-tab-spam-limits-configurable.patch +++ b/patches/server/0235-Break-up-and-make-tab-spam-limits-configurable.patch @@ -22,10 +22,10 @@ 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 3ba4ff3712716daa584265b1132901fb30d39eaf..39144beeb90554ccf39049f9bc334783ea28f825 100644 +index 7f7b897e3633df849b764b7e7f94cc588b55046d..2c3b91cb401880353ca77ce6237214d7068a518e 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -264,6 +264,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -265,6 +265,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic private long keepAliveChallenge; // CraftBukkit start - multithreaded fields private final AtomicInteger chatSpamTickCount = new AtomicInteger(); @@ -33,7 +33,7 @@ index 3ba4ff3712716daa584265b1132901fb30d39eaf..39144beeb90554ccf39049f9bc334783 // CraftBukkit end private int dropSpamTickCount; private double firstGoodX; -@@ -412,6 +413,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -413,6 +414,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic this.server.getProfiler().pop(); // CraftBukkit start for (int spam; (spam = this.chatSpamTickCount.get()) > 0 && !this.chatSpamTickCount.compareAndSet(spam, spam - 1); ) ; @@ -41,7 +41,7 @@ index 3ba4ff3712716daa584265b1132901fb30d39eaf..39144beeb90554ccf39049f9bc334783 /* Use thread-safe field access instead if (this.chatSpamTickCount > 0) { --this.chatSpamTickCount; -@@ -788,7 +790,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -789,7 +791,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic public void handleCustomCommandSuggestions(ServerboundCommandSuggestionPacket packet) { // PacketUtils.ensureRunningOnSameThread(packet, this, this.player.getLevel()); // Paper - run this async // CraftBukkit start diff --git a/patches/server/0236-Fix-NBT-type-issues.patch b/patches/server/0236-Fix-NBT-type-issues.patch index 9fd58bc72d..eb338da33c 100644 --- a/patches/server/0236-Fix-NBT-type-issues.patch +++ b/patches/server/0236-Fix-NBT-type-issues.patch @@ -8,10 +8,10 @@ Addresses two issues: - Allay duplication cooldown is saved and exposed as a long, but loaded as an int diff --git a/src/main/java/net/minecraft/world/entity/ExperienceOrb.java b/src/main/java/net/minecraft/world/entity/ExperienceOrb.java -index 28949deb54e89742541c1a14e8b69bb5b13848a9..2d3994de8e40eedc78c27ea842b6265b1c5ea822 100644 +index c0c0090ab271dba1cc367e216fea3d9f73e5b887..a9f20e6a73e2e1875abd1e122a5d08c4ef44f9d8 100644 --- a/src/main/java/net/minecraft/world/entity/ExperienceOrb.java +++ b/src/main/java/net/minecraft/world/entity/ExperienceOrb.java -@@ -287,7 +287,7 @@ public class ExperienceOrb extends Entity { +@@ -288,7 +288,7 @@ public class ExperienceOrb extends Entity { public void addAdditionalSaveData(CompoundTag nbt) { nbt.putShort("Health", (short) this.health); nbt.putShort("Age", (short) this.age); @@ -20,7 +20,7 @@ index 28949deb54e89742541c1a14e8b69bb5b13848a9..2d3994de8e40eedc78c27ea842b6265b nbt.putInt("Count", this.count); this.savePaperNBT(nbt); // Paper } -@@ -296,7 +296,7 @@ public class ExperienceOrb extends Entity { +@@ -297,7 +297,7 @@ public class ExperienceOrb extends Entity { public void readAdditionalSaveData(CompoundTag nbt) { this.health = nbt.getShort("Health"); this.age = nbt.getShort("Age"); diff --git a/patches/server/0238-Add-Debug-Entities-option-to-debug-dupe-uuid-issues.patch b/patches/server/0238-Add-Debug-Entities-option-to-debug-dupe-uuid-issues.patch index 5d33fb3bae..ca437a8314 100644 --- a/patches/server/0238-Add-Debug-Entities-option-to-debug-dupe-uuid-issues.patch +++ b/patches/server/0238-Add-Debug-Entities-option-to-debug-dupe-uuid-issues.patch @@ -72,10 +72,10 @@ index 718a403799246228e085280cb539236b01720d4b..e46f18e342f2e682c4d5bbac22187a17 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 c330d8e6894d9a4b6cabd36ccda7443bee33407e..8663ea3cc8d5672b03b4b8345d7d970fcbc6a80b 100644 +index 8d3712314a1674470bad90895e86bb34d923dcaa..bb926384659194501bfdbed01b1f66d0909a592a 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -237,6 +237,8 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -238,6 +238,8 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { public com.destroystokyo.paper.loottable.PaperLootableInventoryData lootableData; // Paper private CraftEntity bukkitEntity; diff --git a/patches/server/0239-Add-Early-Warning-Feature-to-WatchDog.patch b/patches/server/0239-Add-Early-Warning-Feature-to-WatchDog.patch index 2b4d1a47dc..4a7c660433 100644 --- a/patches/server/0239-Add-Early-Warning-Feature-to-WatchDog.patch +++ b/patches/server/0239-Add-Early-Warning-Feature-to-WatchDog.patch @@ -33,10 +33,10 @@ index e6826cd0a596f063e8737dcde3c8c6c5b3f71970..1a2607d1b257cea65c82c661a6b3d46c com.destroystokyo.paper.Metrics.PaperMetrics.startMetrics(); com.destroystokyo.paper.VersionHistoryManager.INSTANCE.getClass(); // load version history now diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 8d1dc213ee5acaefd02c1a35140befba5e790d02..2cfcfc256acf322c5279fe967f33705fcd958623 100644 +index f6e7cfc4d86dfdc0ff87642fbc7af330df8eb725..9894d5d10c76469ad6f26100ce3924b65597e738 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -901,6 +901,7 @@ public final class CraftServer implements Server { +@@ -902,6 +902,7 @@ public final class CraftServer implements Server { @Override public void reload() { @@ -44,7 +44,7 @@ index 8d1dc213ee5acaefd02c1a35140befba5e790d02..2cfcfc256acf322c5279fe967f33705f this.reloadCount++; this.configuration = YamlConfiguration.loadConfiguration(this.getConfigFile()); this.commandsConfiguration = YamlConfiguration.loadConfiguration(this.getCommandsConfigFile()); -@@ -990,6 +991,7 @@ public final class CraftServer implements Server { +@@ -991,6 +992,7 @@ public final class CraftServer implements Server { this.enablePlugins(PluginLoadOrder.STARTUP); this.enablePlugins(PluginLoadOrder.POSTWORLD); this.getPluginManager().callEvent(new ServerLoadEvent(ServerLoadEvent.LoadType.RELOAD)); diff --git a/patches/server/0240-Use-ConcurrentHashMap-in-JsonList.patch b/patches/server/0240-Use-ConcurrentHashMap-in-JsonList.patch index 50dab18954..983ab3d413 100644 --- a/patches/server/0240-Use-ConcurrentHashMap-in-JsonList.patch +++ b/patches/server/0240-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 c3c2d7a035e35135a422cfec3513b6a7a268e1e1..93ca3559c92e46352f7f2dcff3afbc08a476f372 100644 +index bfc81327f0c64ef3bd2e8ba218f6a4970553a309..952e0735bf1e66a812c90f283203c4f73e3905a5 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -640,7 +640,7 @@ public abstract class PlayerList { +@@ -642,7 +642,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/0247-Optimize-CraftBlockData-Creation.patch b/patches/server/0247-Optimize-CraftBlockData-Creation.patch index a2f88c22c1..9586bc5275 100644 --- a/patches/server/0247-Optimize-CraftBlockData-Creation.patch +++ b/patches/server/0247-Optimize-CraftBlockData-Creation.patch @@ -26,10 +26,10 @@ index 0eb877c80c6492d03681c70f7866ad705a62454e..7cc6dcb128f2792fc32bb8f50e4c94d6 // Paper start protected boolean shapeExceedsCube = true; diff --git a/src/main/java/org/bukkit/craftbukkit/block/data/CraftBlockData.java b/src/main/java/org/bukkit/craftbukkit/block/data/CraftBlockData.java -index d293ba4f1c4a095c7aee7e4b1b06ab4214ff821c..ccd511f189a9ec57564b2372d7f662da15ef3bba 100644 +index b47fdd7d54ca0fafb8b56b64ae1ab96b6fcf0818..d4a204cdd035d1af2fc5a05036a3374ac89974c5 100644 --- a/src/main/java/org/bukkit/craftbukkit/block/data/CraftBlockData.java +++ b/src/main/java/org/bukkit/craftbukkit/block/data/CraftBlockData.java -@@ -553,7 +553,17 @@ public class CraftBlockData implements BlockData { +@@ -554,7 +554,17 @@ public class CraftBlockData implements BlockData { return craft; } diff --git a/patches/server/0252-Make-CraftWorld-loadChunk-int-int-false-load-unconve.patch b/patches/server/0252-Make-CraftWorld-loadChunk-int-int-false-load-unconve.patch index b67f25d537..dc94cfab1e 100644 --- a/patches/server/0252-Make-CraftWorld-loadChunk-int-int-false-load-unconve.patch +++ b/patches/server/0252-Make-CraftWorld-loadChunk-int-int-false-load-unconve.patch @@ -6,10 +6,10 @@ Subject: [PATCH] Make CraftWorld#loadChunk(int, int, false) load unconverted diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -index ea55b206eb94a3349585435f6e7184fffccd7bd3..577f488cab5219d2cad203972731bd14a28e869e 100644 +index c178f57d5e45a6d2c91f0476ccdb3cb690a3200c..c6e8144a9f2b50fec6e9556a4fa22da48895ad2c 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -@@ -403,7 +403,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -399,7 +399,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { @Override public boolean loadChunk(int x, int z, boolean generate) { org.spigotmc.AsyncCatcher.catchOp("chunk load"); // Spigot diff --git a/patches/server/0254-Expose-attack-cooldown-methods-for-Player.patch b/patches/server/0254-Expose-attack-cooldown-methods-for-Player.patch index 707e01b828..b76ec8861c 100644 --- a/patches/server/0254-Expose-attack-cooldown-methods-for-Player.patch +++ b/patches/server/0254-Expose-attack-cooldown-methods-for-Player.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Expose attack cooldown methods for Player diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -index 1ce97fdbe5ac2d13ded50493865eff4d7919b66a..95bb1282395f18758ee167c2fa4d28aa90a03ca0 100644 +index db79410d56e0defeb710203f9332dff6d5418ee4..124cc062b8b8f63788d903b5706999dc64b8c974 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -@@ -2809,6 +2809,21 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -2817,6 +2817,21 @@ public class CraftPlayer extends CraftHumanEntity implements Player { return this.adventure$pointers; } diff --git a/patches/server/0255-Improve-death-events.patch b/patches/server/0255-Improve-death-events.patch index a6517c2af3..393fc27372 100644 --- a/patches/server/0255-Improve-death-events.patch +++ b/patches/server/0255-Improve-death-events.patch @@ -19,10 +19,10 @@ public net.minecraft.world.entity.LivingEntity getDeathSound()Lnet/minecraft/sou public net.minecraft.world.entity.LivingEntity getSoundVolume()F diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java -index 9e4c827bba4c87595db8cb8896b77558b3feadf5..e5058fae42532c20f5d3332f881177e9294c4c3f 100644 +index 57ab89118811cb0825435b9bdde8f5aeee681d75..3f9ae61ac16a4ec13c6a571ab3d5188f37d205f2 100644 --- a/src/main/java/net/minecraft/server/level/ServerPlayer.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java -@@ -241,6 +241,10 @@ public class ServerPlayer extends Player { +@@ -243,6 +243,10 @@ public class ServerPlayer extends Player { public int latency; public boolean wonGame; private int containerUpdateDelay; // Paper @@ -33,7 +33,7 @@ index 9e4c827bba4c87595db8cb8896b77558b3feadf5..e5058fae42532c20f5d3332f881177e9 // CraftBukkit start public String displayName; -@@ -829,6 +833,15 @@ public class ServerPlayer extends Player { +@@ -831,6 +835,15 @@ public class ServerPlayer extends Player { String deathmessage = defaultMessage.getString(); this.keepLevel = keepInventory; // SPIGOT-2222: pre-set keepLevel org.bukkit.event.entity.PlayerDeathEvent event = CraftEventFactory.callPlayerDeathEvent(this, loot, PaperAdventure.asAdventure(defaultMessage), defaultMessage.getString(), keepInventory); // Paper - Adventure @@ -49,7 +49,7 @@ index 9e4c827bba4c87595db8cb8896b77558b3feadf5..e5058fae42532c20f5d3332f881177e9 // SPIGOT-943 - only call if they have an inventory open if (this.containerMenu != this.inventoryMenu) { -@@ -980,8 +993,17 @@ public class ServerPlayer extends Player { +@@ -982,8 +995,17 @@ public class ServerPlayer extends Player { } } } @@ -352,10 +352,10 @@ index e38cbdff34479673f1640c46d727f1a807a609c7..dbb4bfb3d1f1ce2e435ca531be36ea44 this.gameEvent(GameEvent.ENTITY_DIE); } diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -index 95bb1282395f18758ee167c2fa4d28aa90a03ca0..3a962f836bc60d6262d813da53bd474d8541ff81 100644 +index 124cc062b8b8f63788d903b5706999dc64b8c974..081317023417d759ff8d0e754af426fb0902b642 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -@@ -2312,7 +2312,14 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -2320,7 +2320,14 @@ public class CraftPlayer extends CraftHumanEntity implements Player { } public void sendHealthUpdate() { @@ -372,10 +372,10 @@ index 95bb1282395f18758ee167c2fa4d28aa90a03ca0..3a962f836bc60d6262d813da53bd474d public void injectScaledMaxHealth(Collection collection, boolean force) { diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java -index 171f2f3187b0f1d2e86c884cb566d23c048c337b..b8dbc05857e5fa1c0bacabd022be3669884aba40 100644 +index ff1108579b9f8bb867be02a07784c645d0f4d037..f77bb8401f0d4b5acc64c8b707083bc251caf8e5 100644 --- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java +++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java -@@ -822,9 +822,16 @@ public class CraftEventFactory { +@@ -824,9 +824,16 @@ public class CraftEventFactory { public static EntityDeathEvent callEntityDeathEvent(net.minecraft.world.entity.LivingEntity victim, List drops) { CraftLivingEntity entity = (CraftLivingEntity) victim.getBukkitEntity(); EntityDeathEvent event = new EntityDeathEvent(entity, drops, victim.getExpReward()); @@ -392,7 +392,7 @@ index 171f2f3187b0f1d2e86c884cb566d23c048c337b..b8dbc05857e5fa1c0bacabd022be3669 victim.expToDrop = event.getDroppedExp(); for (org.bukkit.inventory.ItemStack stack : event.getDrops()) { -@@ -841,8 +848,15 @@ public class CraftEventFactory { +@@ -843,8 +850,15 @@ public class CraftEventFactory { PlayerDeathEvent event = new PlayerDeathEvent(entity, drops, victim.getExpReward(), 0, deathMessage, stringDeathMessage); // Paper - Adventure event.setKeepInventory(keepInventory); event.setKeepLevel(victim.keepLevel); // SPIGOT-2222: pre-set keepLevel @@ -408,7 +408,7 @@ index 171f2f3187b0f1d2e86c884cb566d23c048c337b..b8dbc05857e5fa1c0bacabd022be3669 victim.keepLevel = event.getKeepLevel(); victim.newLevel = event.getNewLevel(); -@@ -859,6 +873,31 @@ public class CraftEventFactory { +@@ -861,6 +875,31 @@ public class CraftEventFactory { return event; } diff --git a/patches/server/0269-Add-sun-related-API.patch b/patches/server/0269-Add-sun-related-API.patch index 3a8ec3995c..b774ac0822 100644 --- a/patches/server/0269-Add-sun-related-API.patch +++ b/patches/server/0269-Add-sun-related-API.patch @@ -7,10 +7,10 @@ Subject: [PATCH] Add sun related API public net.minecraft.world.entity.Mob isSunBurnTick()Z diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -index 577f488cab5219d2cad203972731bd14a28e869e..fd908bbcbb652b2b6bc8703c5cdf1374b77a70dd 100644 +index c6e8144a9f2b50fec6e9556a4fa22da48895ad2c..24b24ed9a2d6b609ece153d49c675b362cdf11dc 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -@@ -689,6 +689,13 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -685,6 +685,13 @@ public class CraftWorld extends CraftRegionAccessor implements World { } } diff --git a/patches/server/0271-Call-player-spectator-target-events-and-improve-impl.patch b/patches/server/0271-Call-player-spectator-target-events-and-improve-impl.patch index 4b0a707f1e..ca425a8898 100644 --- a/patches/server/0271-Call-player-spectator-target-events-and-improve-impl.patch +++ b/patches/server/0271-Call-player-spectator-target-events-and-improve-impl.patch @@ -19,10 +19,10 @@ 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 e5058fae42532c20f5d3332f881177e9294c4c3f..4d4e1f62a33ca04401c00424934302867e2efa0c 100644 +index 3f9ae61ac16a4ec13c6a571ab3d5188f37d205f2..9f6531a2d20583355587dab1503573024a12144d 100644 --- a/src/main/java/net/minecraft/server/level/ServerPlayer.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java -@@ -1931,6 +1931,19 @@ public class ServerPlayer extends Player { +@@ -1933,6 +1933,19 @@ public class ServerPlayer extends Player { this.camera = (Entity) (entity == null ? this : entity); if (entity1 != this.camera) { @@ -42,7 +42,7 @@ index e5058fae42532c20f5d3332f881177e9294c4c3f..4d4e1f62a33ca04401c0042493430286 Level world = this.camera.getLevel(); if (world instanceof ServerLevel) { -@@ -1946,7 +1959,6 @@ public class ServerPlayer extends Player { +@@ -1948,7 +1961,6 @@ public class ServerPlayer extends Player { this.connection.send(new ClientboundSetCameraPacket(this.camera)); this.connection.resetPosition(); } diff --git a/patches/server/0275-Add-option-to-prevent-players-from-moving-into-unloa.patch b/patches/server/0275-Add-option-to-prevent-players-from-moving-into-unloa.patch index 995f5253a3..874f4effbe 100644 --- a/patches/server/0275-Add-option-to-prevent-players-from-moving-into-unloa.patch +++ b/patches/server/0275-Add-option-to-prevent-players-from-moving-into-unloa.patch @@ -6,10 +6,10 @@ 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 39144beeb90554ccf39049f9bc334783ea28f825..a7465f6eaa8269d715be935b0de95d7dadd80fdd 100644 +index 2c3b91cb401880353ca77ce6237214d7068a518e..dce8658b06b5c86aebd5df8aa9b40eb2d10290d1 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -566,9 +566,9 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -567,9 +567,9 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic double d0 = entity.getX(); double d1 = entity.getY(); double d2 = entity.getZ(); @@ -22,7 +22,7 @@ index 39144beeb90554ccf39049f9bc334783ea28f825..a7465f6eaa8269d715be935b0de95d7d float f = Mth.wrapDegrees(packet.getYRot()); float f1 = Mth.wrapDegrees(packet.getXRot()); double d6 = d3 - this.vehicleFirstGoodX; -@@ -603,6 +603,16 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -604,6 +604,16 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic } speed *= 2f; // TODO: Get the speed of the vehicle instead of the player @@ -39,7 +39,7 @@ index 39144beeb90554ccf39049f9bc334783ea28f825..a7465f6eaa8269d715be935b0de95d7d if (d10 - d9 > Math.max(100.0D, Math.pow((double) (org.spigotmc.SpigotConfig.movedTooQuicklyMultiplier * (float) i * speed), 2)) && !this.isSingleplayerOwner()) { // CraftBukkit end ServerGamePacketListenerImpl.LOGGER.warn("{} (vehicle of {}) moved too quickly! {},{},{}", new Object[]{entity.getName().getString(), this.player.getName().getString(), d6, d7, d8}); -@@ -1252,9 +1262,9 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -1253,9 +1263,9 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic this.allowedPlayerTicks = 20; // CraftBukkit } else { this.awaitingTeleportTime = this.tickCount; @@ -52,7 +52,7 @@ index 39144beeb90554ccf39049f9bc334783ea28f825..a7465f6eaa8269d715be935b0de95d7d float f = Mth.wrapDegrees(packet.getYRot(this.player.getYRot())); float f1 = Mth.wrapDegrees(packet.getXRot(this.player.getXRot())); -@@ -1310,6 +1320,12 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -1311,6 +1321,12 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic } else { speed = this.player.getAbilities().walkingSpeed * 10f; } diff --git a/patches/server/0276-Reset-players-airTicks-on-respawn.patch b/patches/server/0276-Reset-players-airTicks-on-respawn.patch index e962f8ef6b..e3296f5e4e 100644 --- a/patches/server/0276-Reset-players-airTicks-on-respawn.patch +++ b/patches/server/0276-Reset-players-airTicks-on-respawn.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Reset players airTicks on respawn diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java -index 4d4e1f62a33ca04401c00424934302867e2efa0c..dd729d17eadd8e8860bf2344a534534bf21c2619 100644 +index 9f6531a2d20583355587dab1503573024a12144d..fbd470bb9fccf1f923c55f3b7906bc65aa34c01e 100644 --- a/src/main/java/net/minecraft/server/level/ServerPlayer.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java -@@ -2341,6 +2341,7 @@ public class ServerPlayer extends Player { +@@ -2369,6 +2369,7 @@ public class ServerPlayer extends Player { this.setHealth(this.getMaxHealth()); this.stopUsingItem(); // CraftBukkit - SPIGOT-6682: Clear active item on reset diff --git a/patches/server/0280-Restore-custom-InventoryHolder-support.patch b/patches/server/0280-Restore-custom-InventoryHolder-support.patch index e7d842234d..1cce252dbb 100644 --- a/patches/server/0280-Restore-custom-InventoryHolder-support.patch +++ b/patches/server/0280-Restore-custom-InventoryHolder-support.patch @@ -161,10 +161,19 @@ index 0000000000000000000000000000000000000000..224d4b2cc45b0d02230a76caee9c8857 + } +} diff --git a/src/main/java/org/bukkit/craftbukkit/inventory/CraftContainer.java b/src/main/java/org/bukkit/craftbukkit/inventory/CraftContainer.java -index 7d0d2cd4d34d6652eb45aa13442e1081a3a6bd56..191e8233deaa859d969d54242e297e722f3d947b 100644 +index fe54d5cb2414c7b6f42d192c74f810e7b5e43f0e..04088918e172eecb8d53b0e6de9be0071ccf33b5 100644 --- a/src/main/java/org/bukkit/craftbukkit/inventory/CraftContainer.java +++ b/src/main/java/org/bukkit/craftbukkit/inventory/CraftContainer.java -@@ -71,13 +71,13 @@ public class CraftContainer extends AbstractContainerMenu { +@@ -49,7 +49,7 @@ public class CraftContainer extends AbstractContainerMenu { + public CraftContainer(final Inventory inventory, final Player player, int id) { + this(new InventoryView() { + +- private final String originalTitle = (inventory instanceof CraftInventoryCustom) ? ((CraftInventoryCustom.MinecraftInventory) ((CraftInventory) inventory).getInventory()).getTitle() : inventory.getType().getDefaultTitle(); ++ private final String originalTitle = inventory instanceof CraftInventoryCustom ? ((CraftInventoryCustom) inventory).getTitle() : inventory.getType().getDefaultTitle(); // Paper + private String title = this.originalTitle; + + @Override +@@ -75,7 +75,7 @@ public class CraftContainer extends AbstractContainerMenu { // Paper start @Override public net.kyori.adventure.text.Component title() { @@ -173,14 +182,7 @@ index 7d0d2cd4d34d6652eb45aa13442e1081a3a6bd56..191e8233deaa859d969d54242e297e72 } // Paper end - @Override - public String getTitle() { -- return inventory instanceof CraftInventoryCustom ? ((CraftInventoryCustom.MinecraftInventory) ((CraftInventory) inventory).getInventory()).getTitle() : inventory.getType().getDefaultTitle(); -+ return inventory instanceof CraftInventoryCustom custom ? custom.getTitle() : inventory.getType().getDefaultTitle(); // Paper - } - }, player, id); - } -@@ -232,6 +232,10 @@ public class CraftContainer extends AbstractContainerMenu { +@@ -248,6 +248,10 @@ public class CraftContainer extends AbstractContainerMenu { this.lastSlots = delegate.lastSlots; this.slots = delegate.slots; this.remoteSlots = delegate.remoteSlots; diff --git a/patches/server/0281-Use-Vanilla-Minecart-Speeds.patch b/patches/server/0281-Use-Vanilla-Minecart-Speeds.patch index 4f6ba8f5ef..436aa005d3 100644 --- a/patches/server/0281-Use-Vanilla-Minecart-Speeds.patch +++ b/patches/server/0281-Use-Vanilla-Minecart-Speeds.patch @@ -6,10 +6,10 @@ Subject: [PATCH] Use Vanilla Minecart Speeds CraftBukkit changed the values on flying speed, restore back to vanilla diff --git a/src/main/java/net/minecraft/world/entity/vehicle/AbstractMinecart.java b/src/main/java/net/minecraft/world/entity/vehicle/AbstractMinecart.java -index 29c0335116ef9bed0bcd55b0e600360b87d264cb..1e39bdb3146bcc577abc77021d7b9c9dcce51f4c 100644 +index 09157d234616faaf66546b02b281f9fb7e5c57c0..b66f06d0442ed65023f84ea15651ddfc72f056a5 100644 --- a/src/main/java/net/minecraft/world/entity/vehicle/AbstractMinecart.java +++ b/src/main/java/net/minecraft/world/entity/vehicle/AbstractMinecart.java -@@ -102,9 +102,9 @@ public abstract class AbstractMinecart extends Entity { +@@ -103,9 +103,9 @@ public abstract class AbstractMinecart extends Entity { private double derailedX = 0.5; private double derailedY = 0.5; private double derailedZ = 0.5; diff --git a/patches/server/0283-Don-t-allow-digging-into-unloaded-chunks.patch b/patches/server/0283-Don-t-allow-digging-into-unloaded-chunks.patch index aff2abfb0a..d819193804 100644 --- a/patches/server/0283-Don-t-allow-digging-into-unloaded-chunks.patch +++ b/patches/server/0283-Don-t-allow-digging-into-unloaded-chunks.patch @@ -59,10 +59,10 @@ index 21401c872035d4dc46a05c066b321d99e0d94b72..618888eac8381b174850e351577601f1 this.level.destroyBlockProgress(this.player.getId(), pos, -1); diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index a7465f6eaa8269d715be935b0de95d7dadd80fdd..ed7680eb0c50eabd5366e8d5b27d02223e6e8041 100644 +index dce8658b06b5c86aebd5df8aa9b40eb2d10290d1..a69f7ea461ccfd6d6f842a4b33672187f10264ec 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -1659,6 +1659,12 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -1660,6 +1660,12 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic case START_DESTROY_BLOCK: case ABORT_DESTROY_BLOCK: case STOP_DESTROY_BLOCK: diff --git a/patches/server/0284-Make-the-default-permission-message-configurable.patch b/patches/server/0284-Make-the-default-permission-message-configurable.patch index c5fde71321..29e31c1ed1 100644 --- a/patches/server/0284-Make-the-default-permission-message-configurable.patch +++ b/patches/server/0284-Make-the-default-permission-message-configurable.patch @@ -18,10 +18,10 @@ index e3467aaf6d0c8d486b84362e3c20b3fe631b50ff..8f16640fc2f1233c10392d7e32a54d78 } diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 2cfcfc256acf322c5279fe967f33705fcd958623..b43be6e03ab51b9956ff3faff97e8e050e15a909 100644 +index 9894d5d10c76469ad6f26100ce3924b65597e738..c4970f883d27fe2082bf5cb1d43fa32e9b9b8a30 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -2630,6 +2630,16 @@ public final class CraftServer implements Server { +@@ -2631,6 +2631,16 @@ public final class CraftServer implements Server { return io.papermc.paper.configuration.GlobalConfiguration.get().commands.suggestPlayerNamesWhenNullTabCompletions; } diff --git a/patches/server/0287-force-entity-dismount-during-teleportation.patch b/patches/server/0287-force-entity-dismount-during-teleportation.patch index 0fd584f973..2f35adc633 100644 --- a/patches/server/0287-force-entity-dismount-during-teleportation.patch +++ b/patches/server/0287-force-entity-dismount-during-teleportation.patch @@ -20,10 +20,10 @@ 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 584927547bbaf7e76db9d1a4275fba41d4467227..1b6b71d80a8c1e213186473f1c0ff72ca72ce307 100644 +index bb926384659194501bfdbed01b1f66d0909a592a..55658cdb2b5aca0bfebefc7fcec36aefe5f42e7b 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -2422,11 +2422,16 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -2423,11 +2423,16 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { } public void removeVehicle() { @@ -41,7 +41,7 @@ index 584927547bbaf7e76db9d1a4275fba41d4467227..1b6b71d80a8c1e213186473f1c0ff72c } } -@@ -2490,7 +2495,10 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -2491,7 +2496,10 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { return true; // CraftBukkit } @@ -53,7 +53,7 @@ index 584927547bbaf7e76db9d1a4275fba41d4467227..1b6b71d80a8c1e213186473f1c0ff72c if (entity.getVehicle() == this) { throw new IllegalStateException("Use x.stopRiding(y), not y.removePassenger(x)"); } else { -@@ -2500,7 +2508,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -2501,7 +2509,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { if (this.getBukkitEntity() instanceof Vehicle && entity.getBukkitEntity() instanceof LivingEntity) { VehicleExitEvent event = new VehicleExitEvent( (Vehicle) this.getBukkitEntity(), @@ -62,7 +62,7 @@ index 584927547bbaf7e76db9d1a4275fba41d4467227..1b6b71d80a8c1e213186473f1c0ff72c ); // Suppress during worldgen if (this.valid) { -@@ -2514,7 +2522,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -2515,7 +2523,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { } // CraftBukkit end // Spigot start diff --git a/patches/server/0289-Book-Size-Limits.patch b/patches/server/0289-Book-Size-Limits.patch index 03f54ae370..61221c290b 100644 --- a/patches/server/0289-Book-Size-Limits.patch +++ b/patches/server/0289-Book-Size-Limits.patch @@ -6,10 +6,10 @@ 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 ed7680eb0c50eabd5366e8d5b27d02223e6e8041..8d26c0e0e5df49898e1ba4396d5b27eda6b5ce71 100644 +index a69f7ea461ccfd6d6f842a4b33672187f10264ec..3b5384e27436b93351fcf4b4d938bc13cca9fd58 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -1119,6 +1119,45 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -1120,6 +1120,45 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic @Override public void handleEditBook(ServerboundEditBookPacket packet) { diff --git a/patches/server/0292-Add-APIs-to-replace-OfflinePlayer-getLastPlayed.patch b/patches/server/0292-Add-APIs-to-replace-OfflinePlayer-getLastPlayed.patch index 2b6d3a900c..feccc88cee 100644 --- a/patches/server/0292-Add-APIs-to-replace-OfflinePlayer-getLastPlayed.patch +++ b/patches/server/0292-Add-APIs-to-replace-OfflinePlayer-getLastPlayed.patch @@ -16,10 +16,10 @@ intent to remove) and replace it with two new methods, clearly named and documented as to their purpose. diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java -index dd729d17eadd8e8860bf2344a534534bf21c2619..35db7ee2aace8d7375a1474a849b78a1ca4059be 100644 +index fbd470bb9fccf1f923c55f3b7906bc65aa34c01e..140fdbdcc20b53d7dc3e1d4d027878d9d2db4ef7 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 { +@@ -243,6 +243,7 @@ public class ServerPlayer extends Player { public int latency; public boolean wonGame; private int containerUpdateDelay; // Paper @@ -28,10 +28,10 @@ index dd729d17eadd8e8860bf2344a534534bf21c2619..35db7ee2aace8d7375a1474a849b78a1 public boolean queueHealthUpdatePacket = false; public net.minecraft.network.protocol.game.ClientboundSetHealthPacket queuedHealthUpdatePacket; diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java -index 93ca3559c92e46352f7f2dcff3afbc08a476f372..c1c7dca57cc7a4db3061186fc502d9e36a6ea0a5 100644 +index 952e0735bf1e66a812c90f283203c4f73e3905a5..06961cb5cf7c3e8898c93b4f4d0449e7c3edc4b4 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -187,6 +187,7 @@ public abstract class PlayerList { +@@ -189,6 +189,7 @@ public abstract class PlayerList { public void placeNewPlayer(Connection connection, ServerPlayer player) { player.isRealPlayer = true; // Paper @@ -106,10 +106,10 @@ index 69a1852905dd4724c30ac8ab88c14251eee2c371..17b3d5de58a9ef3acc67624c46cd6bbd public Location getLastDeathLocation() { if (this.getData().contains("LastDeathLocation", 10)) { diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -index 3a962f836bc60d6262d813da53bd474d8541ff81..6255e20cfc19835b2bee098678b09b89d0b9a147 100644 +index 081317023417d759ff8d0e754af426fb0902b642..ea8dc87ce9a995ace56c27c53a15ef51dc4a871d 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -@@ -178,6 +178,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -182,6 +182,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player { private org.bukkit.event.player.PlayerResourcePackStatusEvent.Status resourcePackStatus; private String resourcePackHash; private static final boolean DISABLE_CHANNEL_LIMIT = System.getProperty("paper.disableChannelLimit") != null; // Paper - add a flag to disable the channel limit @@ -117,7 +117,7 @@ index 3a962f836bc60d6262d813da53bd474d8541ff81..6255e20cfc19835b2bee098678b09b89 // Paper end public CraftPlayer(CraftServer server, ServerPlayer entity) { -@@ -1924,6 +1925,18 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -1932,6 +1933,18 @@ public class CraftPlayer extends CraftHumanEntity implements Player { this.firstPlayed = firstPlayed; } @@ -136,7 +136,7 @@ index 3a962f836bc60d6262d813da53bd474d8541ff81..6255e20cfc19835b2bee098678b09b89 public void readExtraData(CompoundTag nbttagcompound) { this.hasPlayedBefore = true; if (nbttagcompound.contains("bukkit")) { -@@ -1946,6 +1959,8 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -1954,6 +1967,8 @@ public class CraftPlayer extends CraftHumanEntity implements Player { } public void setExtraData(CompoundTag nbttagcompound) { @@ -145,7 +145,7 @@ index 3a962f836bc60d6262d813da53bd474d8541ff81..6255e20cfc19835b2bee098678b09b89 if (!nbttagcompound.contains("bukkit")) { nbttagcompound.put("bukkit", new CompoundTag()); } -@@ -1960,6 +1975,16 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -1968,6 +1983,16 @@ public class CraftPlayer extends CraftHumanEntity implements Player { data.putLong("firstPlayed", this.getFirstPlayed()); data.putLong("lastPlayed", System.currentTimeMillis()); data.putString("lastKnownName", handle.getScoreboardName()); diff --git a/patches/server/0293-Workaround-for-vehicle-tracking-issue-on-disconnect.patch b/patches/server/0293-Workaround-for-vehicle-tracking-issue-on-disconnect.patch index 575dfd55dd..de3155219c 100644 --- a/patches/server/0293-Workaround-for-vehicle-tracking-issue-on-disconnect.patch +++ b/patches/server/0293-Workaround-for-vehicle-tracking-issue-on-disconnect.patch @@ -5,10 +5,10 @@ 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 35db7ee2aace8d7375a1474a849b78a1ca4059be..74c2f5bf6adfce37cdf152578edf1f8a17b885af 100644 +index 140fdbdcc20b53d7dc3e1d4d027878d9d2db4ef7..4a4c9bcfa24e116aa242de2cc4291cf4480331b1 100644 --- a/src/main/java/net/minecraft/server/level/ServerPlayer.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java -@@ -1596,6 +1596,13 @@ public class ServerPlayer extends Player { +@@ -1598,6 +1598,13 @@ public class ServerPlayer extends Player { public void disconnect() { this.disconnected = true; this.ejectPassengers(); diff --git a/patches/server/0294-Block-Entity-remove-from-being-called-on-Players.patch b/patches/server/0294-Block-Entity-remove-from-being-called-on-Players.patch index 23a5e04415..148233653a 100644 --- a/patches/server/0294-Block-Entity-remove-from-being-called-on-Players.patch +++ b/patches/server/0294-Block-Entity-remove-from-being-called-on-Players.patch @@ -12,10 +12,10 @@ Player we will look at limiting the scope of this change. It appears to be unintentional in the few cases we've seen so far. diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -index 6255e20cfc19835b2bee098678b09b89d0b9a147..f21bbbc7ff8aee29e0eb35e779bf02dbba703950 100644 +index ea8dc87ce9a995ace56c27c53a15ef51dc4a871d..5e4735ed74e47c28d85c2e7e08458e74f6559e47 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -@@ -2856,6 +2856,15 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -2864,6 +2864,15 @@ public class CraftPlayer extends CraftHumanEntity implements Player { public void resetCooldown() { getHandle().resetAttackStrengthTicker(); } diff --git a/patches/server/0297-Implement-Brigadier-Mojang-API.patch b/patches/server/0297-Implement-Brigadier-Mojang-API.patch index 6e35e47dbc..cb8739471f 100644 --- a/patches/server/0297-Implement-Brigadier-Mojang-API.patch +++ b/patches/server/0297-Implement-Brigadier-Mojang-API.patch @@ -131,10 +131,10 @@ index 286dab2ed3c6b962c9702b8b10105e1456b04f7b..7d47e15468f59ce7bc25f692e9963a29 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 8d26c0e0e5df49898e1ba4396d5b27eda6b5ce71..cafc68064ee88a741d7ae4962046717e8c92f81d 100644 +index 3b5384e27436b93351fcf4b4d938bc13cca9fd58..0b61a213eeae7d39b6478b732ebb8d9ecd8c994a 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -831,8 +831,12 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -832,8 +832,12 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic ParseResults parseresults = this.server.getCommands().getDispatcher().parse(stringreader, this.player.createCommandSourceStack()); this.server.getCommands().getDispatcher().getCompletionSuggestions(parseresults).thenAccept((suggestions) -> { @@ -149,7 +149,7 @@ index 8d26c0e0e5df49898e1ba4396d5b27eda6b5ce71..cafc68064ee88a741d7ae4962046717e }); }); } -@@ -847,7 +851,13 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -848,7 +852,13 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic builder.suggest(completion.suggestion(), PaperAdventure.asVanilla(completion.tooltip())); } }); diff --git a/patches/server/0299-Limit-Client-Sign-length-more.patch b/patches/server/0299-Limit-Client-Sign-length-more.patch index a814847476..5e00371baf 100644 --- a/patches/server/0299-Limit-Client-Sign-length-more.patch +++ b/patches/server/0299-Limit-Client-Sign-length-more.patch @@ -22,10 +22,10 @@ it only impacts data sent from the client. Set -DPaper.maxSignLength=XX to change limit or -1 to disable diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index cafc68064ee88a741d7ae4962046717e8c92f81d..741d28d56a59776df5134a1b769aaa41fa76ec55 100644 +index b834142d8b7eae50b8b9a1b0edaa41f64b950f43..e9cbca84ad7c2c48445fbd0266c5792b12227cd7 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -299,6 +299,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -300,6 +300,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic private final MessageSignatureCache messageSignatureCache; private final FutureChain chatMessageChain; private static final long KEEPALIVE_LIMIT = Long.getLong("paper.playerconnection.keepalive", 30) * 1000; // Paper - provide property to set keepalive limit @@ -33,7 +33,7 @@ index cafc68064ee88a741d7ae4962046717e8c92f81d..741d28d56a59776df5134a1b769aaa41 public ServerGamePacketListenerImpl(MinecraftServer server, Connection connection, ServerPlayer player) { this.lastChatTimeStamp = new AtomicReference(Instant.EPOCH); -@@ -3192,7 +3193,19 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -3199,7 +3200,19 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic @Override public void handleSignUpdate(ServerboundSignUpdatePacket packet) { diff --git a/patches/server/0303-Call-WhitelistToggleEvent-when-whitelist-is-toggled.patch b/patches/server/0303-Call-WhitelistToggleEvent-when-whitelist-is-toggled.patch index d8bd3965d9..5da1dbf674 100644 --- a/patches/server/0303-Call-WhitelistToggleEvent-when-whitelist-is-toggled.patch +++ b/patches/server/0303-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 c1c7dca57cc7a4db3061186fc502d9e36a6ea0a5..65b8adf4a905606ce44a4966ad817ba05156a533 100644 +index 06961cb5cf7c3e8898c93b4f4d0449e7c3edc4b4..9f855fcbc9be12f7542557e1c32248748fad14c3 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -1148,6 +1148,7 @@ public abstract class PlayerList { +@@ -1150,6 +1150,7 @@ public abstract class PlayerList { } public void setUsingWhiteList(boolean whitelistEnabled) { diff --git a/patches/server/0304-Entity-getEntitySpawnReason.patch b/patches/server/0304-Entity-getEntitySpawnReason.patch index 81b056a60f..b33d8ea39b 100644 --- a/patches/server/0304-Entity-getEntitySpawnReason.patch +++ b/patches/server/0304-Entity-getEntitySpawnReason.patch @@ -22,10 +22,10 @@ index e46f18e342f2e682c4d5bbac22187a171df8eb33..58c1769ea15249df950a40e2f164e2ff // 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 65b8adf4a905606ce44a4966ad817ba05156a533..7df1bd503f4aad4c8a4f6d2642139e1460a8df8a 100644 +index 9f855fcbc9be12f7542557e1c32248748fad14c3..e261521d526cb2192761a0432b28f82c83258540 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -224,6 +224,11 @@ public abstract class PlayerList { +@@ -226,6 +226,11 @@ public abstract class PlayerList { worldserver1 = worldserver; } @@ -37,7 +37,7 @@ index 65b8adf4a905606ce44a4966ad817ba05156a533..7df1bd503f4aad4c8a4f6d2642139e14 player.setLevel(worldserver1); String s1 = "local"; -@@ -364,7 +369,7 @@ public abstract class PlayerList { +@@ -366,7 +371,7 @@ public abstract class PlayerList { // CraftBukkit start ServerLevel finalWorldServer = worldserver1; Entity entity = EntityType.loadEntityRecursive(nbttagcompound1.getCompound("Entity"), finalWorldServer, (entity1) -> { @@ -47,10 +47,10 @@ index 65b8adf4a905606ce44a4966ad817ba05156a533..7df1bd503f4aad4c8a4f6d2642139e14 }); diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index 1b6b71d80a8c1e213186473f1c0ff72ca72ce307..b75129ade324835f02a35ae390c15a03139aa6aa 100644 +index 55658cdb2b5aca0bfebefc7fcec36aefe5f42e7b..7288d6d7f08b2e6b9696948d6c4451f479e419b6 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -233,6 +233,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -234,6 +234,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { } } // Paper end @@ -58,7 +58,7 @@ index 1b6b71d80a8c1e213186473f1c0ff72ca72ce307..b75129ade324835f02a35ae390c15a03 public com.destroystokyo.paper.loottable.PaperLootableInventoryData lootableData; // Paper private CraftEntity bukkitEntity; -@@ -2061,6 +2062,9 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -2062,6 +2063,9 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { } nbt.put("Paper.Origin", this.newDoubleList(origin.getX(), origin.getY(), origin.getZ())); } @@ -68,7 +68,7 @@ index 1b6b71d80a8c1e213186473f1c0ff72ca72ce307..b75129ade324835f02a35ae390c15a03 // Save entity's from mob spawner status if (spawnedViaMobSpawner) { nbt.putBoolean("Paper.FromMobSpawner", true); -@@ -2207,6 +2211,26 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -2208,6 +2212,26 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { } spawnedViaMobSpawner = nbt.getBoolean("Paper.FromMobSpawner"); // Restore entity's from mob spawner status @@ -108,7 +108,7 @@ index 405f36e9e115ad44bb91aad885785761786204ca..091c72b95e3c4c3528812ace4aec64d4 // Spigot Start if (org.bukkit.craftbukkit.event.CraftEventFactory.callSpawnerSpawnEvent(entity, pos).isCancelled()) { diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java -index dc4060aee09ec9700a9379e0536fd758c3c1eb25..13169525ce6260f6d4a0501af0f5bea284a5ba96 100644 +index c69f5192f11f8bf080d752971264a01bdb91a30f..02ef4c66b18edd2138a92b609f837664ec20a559 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java @@ -1303,5 +1303,10 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity { diff --git a/patches/server/0306-Implement-PlayerPostRespawnEvent.patch b/patches/server/0306-Implement-PlayerPostRespawnEvent.patch index 4f814aaafc..b2b7f01c14 100644 --- a/patches/server/0306-Implement-PlayerPostRespawnEvent.patch +++ b/patches/server/0306-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 7df1bd503f4aad4c8a4f6d2642139e1460a8df8a..1bb2ea3dab8d978db4b90b9e719a7dfa27cc646f 100644 +index e261521d526cb2192761a0432b28f82c83258540..9ea6ee5a04c14a2d1b178c36d34b118a43fa05b0 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -749,9 +749,14 @@ public abstract class PlayerList { +@@ -751,9 +751,14 @@ public abstract class PlayerList { boolean flag2 = false; @@ -24,7 +24,7 @@ index 7df1bd503f4aad4c8a4f6d2642139e1460a8df8a..1bb2ea3dab8d978db4b90b9e719a7dfa ServerLevel worldserver1 = this.server.getLevel(entityplayer.getRespawnDimension()); if (worldserver1 != null) { Optional optional; -@@ -803,6 +808,7 @@ public abstract class PlayerList { +@@ -805,6 +810,7 @@ public abstract class PlayerList { location = respawnEvent.getRespawnLocation(); if (!flag) entityplayer.reset(); // SPIGOT-4785 @@ -32,7 +32,7 @@ index 7df1bd503f4aad4c8a4f6d2642139e1460a8df8a..1bb2ea3dab8d978db4b90b9e719a7dfa } else { location.setWorld(worldserver.getWorld()); } -@@ -862,6 +868,13 @@ public abstract class PlayerList { +@@ -864,6 +870,13 @@ public abstract class PlayerList { if (entityplayer.connection.isDisconnected()) { this.save(entityplayer); } diff --git a/patches/server/0309-PlayerDeathEvent-getItemsToKeep.patch b/patches/server/0309-PlayerDeathEvent-getItemsToKeep.patch index 9068388af3..e1017711c8 100644 --- a/patches/server/0309-PlayerDeathEvent-getItemsToKeep.patch +++ b/patches/server/0309-PlayerDeathEvent-getItemsToKeep.patch @@ -11,10 +11,10 @@ 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 74c2f5bf6adfce37cdf152578edf1f8a17b885af..8b23e586b9b8f68dbec65a9f738e0e735c124b6b 100644 +index 4a4c9bcfa24e116aa242de2cc4291cf4480331b1..dd2607bc1388bf59bed3635c336e733414bf8e96 100644 --- a/src/main/java/net/minecraft/server/level/ServerPlayer.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java -@@ -804,6 +804,46 @@ public class ServerPlayer extends Player { +@@ -806,6 +806,46 @@ public class ServerPlayer extends Player { }); } @@ -61,7 +61,7 @@ index 74c2f5bf6adfce37cdf152578edf1f8a17b885af..8b23e586b9b8f68dbec65a9f738e0e73 @Override public void die(DamageSource damageSource) { this.gameEvent(GameEvent.ENTITY_DIE); -@@ -887,7 +927,12 @@ public class ServerPlayer extends Player { +@@ -889,7 +929,12 @@ public class ServerPlayer extends Player { this.dropExperience(); // we clean the player's inventory after the EntityDeathEvent is called so plugins can get the exact state of the inventory. if (!event.getKeepInventory()) { diff --git a/patches/server/0311-Add-Heightmap-API.patch b/patches/server/0311-Add-Heightmap-API.patch index 5685f02bd6..2250fc4416 100644 --- a/patches/server/0311-Add-Heightmap-API.patch +++ b/patches/server/0311-Add-Heightmap-API.patch @@ -5,11 +5,11 @@ Subject: [PATCH] Add Heightmap API diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -index fd908bbcbb652b2b6bc8703c5cdf1374b77a70dd..d828b777ae2435579d5f7ea51f920e77a684bb7b 100644 +index 24b24ed9a2d6b609ece153d49c675b362cdf11dc..159684576b235cf9a01de75c7e274bd6bf3127d0 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -@@ -222,6 +222,29 @@ public class CraftWorld extends CraftRegionAccessor implements World { - return this.getHighestBlockYAt(x, z, org.bukkit.HeightMap.MOTION_BLOCKING); +@@ -218,6 +218,29 @@ public class CraftWorld extends CraftRegionAccessor implements World { + return CraftBlock.at(world, new BlockPos(x, y, z)); } + // Paper start - Implement heightmap api diff --git a/patches/server/0313-Fix-CB-call-to-changed-postToMainThread-method.patch b/patches/server/0313-Fix-CB-call-to-changed-postToMainThread-method.patch index 570e5d8ec1..9573844d11 100644 --- a/patches/server/0313-Fix-CB-call-to-changed-postToMainThread-method.patch +++ b/patches/server/0313-Fix-CB-call-to-changed-postToMainThread-method.patch @@ -5,10 +5,10 @@ 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 741d28d56a59776df5134a1b769aaa41fa76ec55..7ea67e64d7ec63c80bc8996983dccd513a425036 100644 +index 9059b5c3cbb0f6cb0c9e6c6030929046225a87e2..4069debcda5afd68ba28c82174da9f33f55d7d18 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -514,7 +514,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -515,7 +515,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic Objects.requireNonNull(this.connection); // CraftBukkit - Don't wait diff --git a/patches/server/0315-Implement-CraftBlockSoundGroup.patch b/patches/server/0315-Implement-CraftBlockSoundGroup.patch index 65d89b1928..8d7dd98554 100644 --- a/patches/server/0315-Implement-CraftBlockSoundGroup.patch +++ b/patches/server/0315-Implement-CraftBlockSoundGroup.patch @@ -50,10 +50,10 @@ index 0000000000000000000000000000000000000000..c5b07ec346105d1b95c1c938ffca12a2 + } +} diff --git a/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java b/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java -index 0951e0836ef16c99505c884ea80e5bd23873b7e6..ee8315595faae22c63c97748d8047038a671263e 100644 +index 0cd58fd473f8cc6cb61798ceca972caef3f5c4d4..fadf95c9ce9ca1d8e1aba5d7035338939ee010ec 100644 --- a/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java +++ b/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java -@@ -647,4 +647,16 @@ public class CraftBlock implements Block { +@@ -646,4 +646,16 @@ public class CraftBlock implements Block { public String getTranslationKey() { return this.getNMS().getBlock().getDescriptionId(); } diff --git a/patches/server/0316-Configurable-Keep-Spawn-Loaded-range-per-world.patch b/patches/server/0316-Configurable-Keep-Spawn-Loaded-range-per-world.patch index 9ecd1cde37..fd6573d5b5 100644 --- a/patches/server/0316-Configurable-Keep-Spawn-Loaded-range-per-world.patch +++ b/patches/server/0316-Configurable-Keep-Spawn-Loaded-range-per-world.patch @@ -200,10 +200,10 @@ index 4d2348df25410a0b5364eec066880326d6667dad..286aad3205ef8a9e21a47ef07893844f this.maxCount = i * i; } diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -index d828b777ae2435579d5f7ea51f920e77a684bb7b..112d6202635d8e9ce101248d69cc7ab5e1feb2cb 100644 +index 159684576b235cf9a01de75c7e274bd6bf3127d0..9d50bd4535989438743b77580018ba9d16e896c8 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -@@ -1356,15 +1356,21 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -1342,15 +1342,21 @@ public class CraftWorld extends CraftRegionAccessor implements World { @Override public void setKeepSpawnInMemory(boolean keepLoaded) { diff --git a/patches/server/0318-Expose-the-internal-current-tick.patch b/patches/server/0318-Expose-the-internal-current-tick.patch index 231d524cf8..7eeb7acf77 100644 --- a/patches/server/0318-Expose-the-internal-current-tick.patch +++ b/patches/server/0318-Expose-the-internal-current-tick.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Expose the internal current tick diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 8f6d54197401ea8722be73e4291aad34000cab58..2c38caaff8c4535eca8a29fafc4e662fb7e6d87f 100644 +index c4970f883d27fe2082bf5cb1d43fa32e9b9b8a30..5c7bae55758760a67f54c48427ddc3f021c22087 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -2671,5 +2671,10 @@ public final class CraftServer implements Server { +@@ -2672,5 +2672,10 @@ public final class CraftServer implements Server { profile.getProperties().putAll(((CraftPlayer)player).getHandle().getGameProfile().getProperties()); return new com.destroystokyo.paper.profile.CraftPlayerProfile(profile); } diff --git a/patches/server/0319-Fix-World-isChunkGenerated-calls.patch b/patches/server/0319-Fix-World-isChunkGenerated-calls.patch index cec8db868d..fef1ca13c0 100644 --- a/patches/server/0319-Fix-World-isChunkGenerated-calls.patch +++ b/patches/server/0319-Fix-World-isChunkGenerated-calls.patch @@ -156,10 +156,10 @@ index 8f729134d8f024678f3f5927059791e28ccb5b90..b294ef87fb93e7f4651dc04128124f29 } catch (Throwable throwable) { if (dataoutputstream != null) { diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -index 112d6202635d8e9ce101248d69cc7ab5e1feb2cb..7f04e2009f4917f3350f9e223891cdd9b394d163 100644 +index 9d50bd4535989438743b77580018ba9d16e896c8..e95c0d533f518837d5f6000eb919d685c921d302 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -@@ -310,9 +310,23 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -306,9 +306,23 @@ public class CraftWorld extends CraftRegionAccessor implements World { @Override public boolean isChunkGenerated(int x, int z) { @@ -185,7 +185,7 @@ index 112d6202635d8e9ce101248d69cc7ab5e1feb2cb..7f04e2009f4917f3350f9e223891cdd9 throw new RuntimeException(ex); } } -@@ -426,20 +440,48 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -422,20 +436,48 @@ public class CraftWorld extends CraftRegionAccessor implements World { @Override public boolean loadChunk(int x, int z, boolean generate) { org.spigotmc.AsyncCatcher.catchOp("chunk load"); // Spigot diff --git a/patches/server/0324-Fix-MC-158900.patch b/patches/server/0324-Fix-MC-158900.patch index 8f0b2826e2..ad116d0439 100644 --- a/patches/server/0324-Fix-MC-158900.patch +++ b/patches/server/0324-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 1bb2ea3dab8d978db4b90b9e719a7dfa27cc646f..c334d750a1eac24474061de8e764d7366ada0578 100644 +index 9ea6ee5a04c14a2d1b178c36d34b118a43fa05b0..4efa85f9c18927248dc2397df0bd3cd0a9063347 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -633,8 +633,10 @@ public abstract class PlayerList { +@@ -635,8 +635,10 @@ public abstract class PlayerList { Player player = entity.getBukkitEntity(); PlayerLoginEvent event = new PlayerLoginEvent(player, loginlistener.connection.hostname, ((java.net.InetSocketAddress) socketaddress).getAddress(), ((java.net.InetSocketAddress) loginlistener.connection.channel.remoteAddress()).getAddress()); diff --git a/patches/server/0326-Dont-send-unnecessary-sign-update.patch b/patches/server/0326-Dont-send-unnecessary-sign-update.patch index ee02c3ad22..da55b6f133 100644 --- a/patches/server/0326-Dont-send-unnecessary-sign-update.patch +++ b/patches/server/0326-Dont-send-unnecessary-sign-update.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Dont send unnecessary sign update diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 7ea67e64d7ec63c80bc8996983dccd513a425036..e4d65aff300c276d0968b9786ddc20ba63caca41 100644 +index 574ff62d6ae3b44a95cc9a08e7cc684acaab5057..0bf9726714697a192cdd1e4c74330b2a0acf8920 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -3230,6 +3230,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -3237,6 +3237,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic if (!tileentitysign.isEditable() || !this.player.getUUID().equals(tileentitysign.getPlayerWhoMayEdit())) { ServerGamePacketListenerImpl.LOGGER.warn("Player {} just tried to change non-editable sign", this.player.getName().getString()); diff --git a/patches/server/0332-PlayerDeathEvent-shouldDropExperience.patch b/patches/server/0332-PlayerDeathEvent-shouldDropExperience.patch index c092d8258b..7b1dcd7f1a 100644 --- a/patches/server/0332-PlayerDeathEvent-shouldDropExperience.patch +++ b/patches/server/0332-PlayerDeathEvent-shouldDropExperience.patch @@ -5,10 +5,10 @@ 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 8b23e586b9b8f68dbec65a9f738e0e735c124b6b..d159433db275cc7308c6f4ad93b5fee075e0cfb1 100644 +index dd2607bc1388bf59bed3635c336e733414bf8e96..c93ede55cdd575f0c928bc9bf90c47480e52f91b 100644 --- a/src/main/java/net/minecraft/server/level/ServerPlayer.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java -@@ -924,7 +924,7 @@ public class ServerPlayer extends Player { +@@ -926,7 +926,7 @@ public class ServerPlayer extends Player { this.tellNeutralMobsThatIDied(); } // SPIGOT-5478 must be called manually now diff --git a/patches/server/0340-Fix-last-firework-in-stack-not-having-effects-when-d.patch b/patches/server/0340-Fix-last-firework-in-stack-not-having-effects-when-d.patch index 2c0691f196..b8c578f5e6 100644 --- a/patches/server/0340-Fix-last-firework-in-stack-not-having-effects-when-d.patch +++ b/patches/server/0340-Fix-last-firework-in-stack-not-having-effects-when-d.patch @@ -9,10 +9,10 @@ dispensed. The resulting item would have size == 0 and therefore be convertered to air, hence why the effects disappeared. diff --git a/src/main/java/net/minecraft/core/dispenser/DispenseItemBehavior.java b/src/main/java/net/minecraft/core/dispenser/DispenseItemBehavior.java -index 2773dfea3346793127b06d7e6d0b1344b03845d0..429b9729188fe340b62a3305e6436fabbb1a7caf 100644 +index 18e746e064f8e39e070a51218357f54c6b16fb7b..abd20f9495c315e73c1eb6572b8fc47db27450d7 100644 --- a/src/main/java/net/minecraft/core/dispenser/DispenseItemBehavior.java +++ b/src/main/java/net/minecraft/core/dispenser/DispenseItemBehavior.java -@@ -515,7 +515,7 @@ public interface DispenseItemBehavior { +@@ -516,7 +516,7 @@ public interface DispenseItemBehavior { } itemstack1 = CraftItemStack.asNMSCopy(event.getItem()); diff --git a/patches/server/0341-Entity-Activation-Range-2.0.patch b/patches/server/0341-Entity-Activation-Range-2.0.patch index cefec0d83f..f1a2570ac6 100644 --- a/patches/server/0341-Entity-Activation-Range-2.0.patch +++ b/patches/server/0341-Entity-Activation-Range-2.0.patch @@ -112,10 +112,10 @@ index dcdf59d18c0336f766bd320b2d536c115df3435d..5ad746ae673ef09f5581cf9fbbf1c9af } else { passenger.stopRiding(); diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index b75129ade324835f02a35ae390c15a03139aa6aa..a8b136800e6e233930f152df869e0ba1a9f1282c 100644 +index 7288d6d7f08b2e6b9696948d6c4451f479e419b6..8be765356261190a070715effbcaadfc83ab6c9c 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -385,6 +385,8 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -386,6 +386,8 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { public void inactiveTick() { } // Spigot end // Paper start @@ -124,7 +124,7 @@ index b75129ade324835f02a35ae390c15a03139aa6aa..a8b136800e6e233930f152df869e0ba1 protected int numCollisions = 0; // Paper public boolean spawnedViaMobSpawner; // Paper - Yes this name is similar to above, upstream took the better one @javax.annotation.Nullable -@@ -910,6 +912,8 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -911,6 +913,8 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { } else { this.wasOnFire = this.isOnFire(); if (movementType == MoverType.PISTON) { @@ -133,7 +133,7 @@ index b75129ade324835f02a35ae390c15a03139aa6aa..a8b136800e6e233930f152df869e0ba1 movement = this.limitPistonMovement(movement); if (movement.equals(Vec3.ZERO)) { return; -@@ -922,6 +926,13 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -923,6 +927,13 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { this.stuckSpeedMultiplier = Vec3.ZERO; this.setDeltaMovement(Vec3.ZERO); } @@ -745,7 +745,7 @@ index 08bf9f85fe02a3f89640a2f3ae23089a119a394a..f158fc8a151272428a33dc5f6e174287 isActive = false; } diff --git a/src/main/java/org/spigotmc/SpigotWorldConfig.java b/src/main/java/org/spigotmc/SpigotWorldConfig.java -index 70b3ff4a6a9aea24e28d99997a936e850d46b05e..a345befaee2e4703294c3941f4060c496838c496 100644 +index e873a311e2918e1cb72f190e14d088a3ed540aa8..77698b0555c5930645659b4af061c3f428bf8f65 100644 --- a/src/main/java/org/spigotmc/SpigotWorldConfig.java +++ b/src/main/java/org/spigotmc/SpigotWorldConfig.java @@ -205,14 +205,60 @@ public class SpigotWorldConfig diff --git a/patches/server/0343-Anti-Xray.patch b/patches/server/0343-Anti-Xray.patch index 293e97b67e..38bf806dcf 100644 --- a/patches/server/0343-Anti-Xray.patch +++ b/patches/server/0343-Anti-Xray.patch @@ -1559,7 +1559,7 @@ index b1c5e5ecf2488d1a6f0a5261d4ba8958de9659ae..4138ba8bdf6f359327dfc86d3402b787 // CraftBukkit end diff --git a/src/main/java/org/bukkit/craftbukkit/CraftChunk.java b/src/main/java/org/bukkit/craftbukkit/CraftChunk.java -index 8f79bcd6132b7064167edb883593873d78b9fe63..ef52dbf5009c7ba14cd0aa9c6c1f3b5534f7af06 100644 +index b738e1f7debac7d70910d5ac908ca9d4f60640d5..269ebe8e8826a0c89e471cb59b503900d7ebe0fa 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftChunk.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftChunk.java @@ -52,7 +52,7 @@ public class CraftChunk implements Chunk { @@ -1572,10 +1572,10 @@ index 8f79bcd6132b7064167edb883593873d78b9fe63..ef52dbf5009c7ba14cd0aa9c6c1f3b55 public CraftChunk(net.minecraft.world.level.chunk.LevelChunk chunk) { diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 4d9f1aae00db09ca0419b702da679b69ab8d59f8..d5a6c8b18ee1aae724e84f83ea7ff17c4c51c870 100644 +index 5c7bae55758760a67f54c48427ddc3f021c22087..2be7afb4cfd77dd2b6cb0ca700b52812f2b5ffe1 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -2243,7 +2243,7 @@ public final class CraftServer implements Server { +@@ -2244,7 +2244,7 @@ public final class CraftServer implements Server { public ChunkGenerator.ChunkData createChunkData(World world) { Validate.notNull(world, "World cannot be null"); ServerLevel handle = ((CraftWorld) world).getHandle(); @@ -1585,10 +1585,10 @@ index 4d9f1aae00db09ca0419b702da679b69ab8d59f8..d5a6c8b18ee1aae724e84f83ea7ff17c @Override diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -index 7f04e2009f4917f3350f9e223891cdd9b394d163..a17ae89a82958bdc3bfa0553440e2887585693c1 100644 +index e95c0d533f518837d5f6000eb919d685c921d302..dbc211b8d23d766ecff7aab1884c72dc7e568dfb 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -@@ -421,11 +421,16 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -417,11 +417,16 @@ public class CraftWorld extends CraftRegionAccessor implements World { List playersInRange = playerChunk.playerProvider.getPlayers(playerChunk.getPos(), false); if (playersInRange.isEmpty()) return true; // Paper - rewrite player chunk loader diff --git a/patches/server/0345-Tracking-Range-Improvements.patch b/patches/server/0345-Tracking-Range-Improvements.patch index 0f18f97b1f..6663d3754d 100644 --- a/patches/server/0345-Tracking-Range-Improvements.patch +++ b/patches/server/0345-Tracking-Range-Improvements.patch @@ -20,10 +20,10 @@ index bba77d5001638307fe640b2e656df0a2b3cb4c43..40177f2e0206f89b83bbc0b6c80d7478 if (j > i) { i = j; diff --git a/src/main/java/org/spigotmc/TrackingRange.java b/src/main/java/org/spigotmc/TrackingRange.java -index 2d5cb8991e368372f1ab227735aac0c060deb199..55ce69b5fe097841d00ef5c241459dce9bb0d4db 100644 +index 7ce2b657ba94c67236ab64c0029b35ee39f71c8f..71225959e1b17974374b1fb998de573ea55d85a4 100644 --- a/src/main/java/org/spigotmc/TrackingRange.java +++ b/src/main/java/org/spigotmc/TrackingRange.java -@@ -6,7 +6,6 @@ import net.minecraft.world.entity.ExperienceOrb; +@@ -7,7 +7,6 @@ import net.minecraft.world.entity.ExperienceOrb; import net.minecraft.world.entity.decoration.ItemFrame; import net.minecraft.world.entity.decoration.Painting; import net.minecraft.world.entity.item.ItemEntity; @@ -31,7 +31,7 @@ index 2d5cb8991e368372f1ab227735aac0c060deb199..55ce69b5fe097841d00ef5c241459dce public class TrackingRange { -@@ -29,26 +28,26 @@ public class TrackingRange +@@ -30,22 +29,21 @@ public class TrackingRange if ( entity instanceof ServerPlayer ) { return config.playerTrackingRange; @@ -67,6 +67,9 @@ index 2d5cb8991e368372f1ab227735aac0c060deb199..55ce69b5fe097841d00ef5c241459dce + // Paper end { return config.miscTrackingRange; + } else if ( entity instanceof Display ) +@@ -53,6 +51,7 @@ public class TrackingRange + return config.displayTrackingRange; } else { + if (entity instanceof net.minecraft.world.entity.boss.enderdragon.EnderDragon) return ((net.minecraft.server.level.ServerLevel)(entity.getCommandSenderWorld())).getChunkSource().chunkMap.getEffectiveViewDistance(); // Paper - enderdragon is exempt diff --git a/patches/server/0346-Fix-items-vanishing-through-end-portal.patch b/patches/server/0346-Fix-items-vanishing-through-end-portal.patch index 71587f713e..eedf7d4044 100644 --- a/patches/server/0346-Fix-items-vanishing-through-end-portal.patch +++ b/patches/server/0346-Fix-items-vanishing-through-end-portal.patch @@ -13,10 +13,10 @@ 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 a0dbb02019d31b890a450d0ffe2197fc095f8362..8f8f8ec38737b50ad23bb2408f9f8262d7b3a507 100644 +index 8be765356261190a070715effbcaadfc83ab6c9c..64bd1cb6c5dd65a62df133926b969e37a3e31f76 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -3229,6 +3229,9 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -3230,6 +3230,9 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { if (flag1) { blockposition1 = ServerLevel.END_SPAWN_POINT; } else { diff --git a/patches/server/0347-implement-optional-per-player-mob-spawns.patch b/patches/server/0347-implement-optional-per-player-mob-spawns.patch index 1c95053d91..60adc768e6 100644 --- a/patches/server/0347-implement-optional-per-player-mob-spawns.patch +++ b/patches/server/0347-implement-optional-per-player-mob-spawns.patch @@ -362,10 +362,10 @@ index c021733342c09adb04ce3f675209543f84ac4bda..d137aa95f670aab516e9e08272f33b21 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 d159433db275cc7308c6f4ad93b5fee075e0cfb1..72e29dc97b38bde3c44edec505fa26633fcdd243 100644 +index c93ede55cdd575f0c928bc9bf90c47480e52f91b..b014f1bd167bad3e1dc613dce5c929f201ef27cc 100644 --- a/src/main/java/net/minecraft/server/level/ServerPlayer.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java -@@ -246,6 +246,11 @@ public class ServerPlayer extends Player { +@@ -248,6 +248,11 @@ public class ServerPlayer extends Player { public boolean queueHealthUpdatePacket = false; public net.minecraft.network.protocol.game.ClientboundSetHealthPacket queuedHealthUpdatePacket; // Paper end @@ -377,7 +377,7 @@ index d159433db275cc7308c6f4ad93b5fee075e0cfb1..72e29dc97b38bde3c44edec505fa2663 // CraftBukkit start public String displayName; -@@ -337,6 +342,7 @@ public class ServerPlayer extends Player { +@@ -339,6 +344,7 @@ public class ServerPlayer extends Player { this.adventure$displayName = net.kyori.adventure.text.Component.text(this.getScoreboardName()); // Paper this.bukkitPickUpLoot = true; this.maxHealthCache = this.getMaxHealth(); diff --git a/patches/server/0349-Improve-Block-breakNaturally-API.patch b/patches/server/0349-Improve-Block-breakNaturally-API.patch index d5ad3ad816..3db5473999 100644 --- a/patches/server/0349-Improve-Block-breakNaturally-API.patch +++ b/patches/server/0349-Improve-Block-breakNaturally-API.patch @@ -34,10 +34,10 @@ index 943b5ee11fb066afcfb3717befe4dab35db5b600..5ecf02ce83b7496c977adfeb203b8ead if (world.dimensionType().ultraWarm()) { world.removeBlock(pos, false); diff --git a/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java b/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java -index ee8315595faae22c63c97748d8047038a671263e..ac543a4c6bc21435de3c6721af37fd5f554e403e 100644 +index fadf95c9ce9ca1d8e1aba5d7035338939ee010ec..707ee755cb9ebf2a2b61a6079efbc54368beeed0 100644 --- a/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java +++ b/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java -@@ -477,6 +477,18 @@ public class CraftBlock implements Block { +@@ -476,6 +476,18 @@ public class CraftBlock implements Block { @Override public boolean breakNaturally(ItemStack item) { @@ -56,7 +56,7 @@ index ee8315595faae22c63c97748d8047038a671263e..ac543a4c6bc21435de3c6721af37fd5f // Order matters here, need to drop before setting to air so skulls can get their data net.minecraft.world.level.block.state.BlockState iblockdata = this.getNMS(); net.minecraft.world.level.block.Block block = iblockdata.getBlock(); -@@ -486,11 +498,35 @@ public class CraftBlock implements Block { +@@ -485,11 +497,35 @@ public class CraftBlock implements Block { // Modelled off EntityHuman#hasBlock if (block != Blocks.AIR && (item == null || !iblockdata.requiresCorrectToolForDrops() || nmsItem.isCorrectToolForDrops(iblockdata))) { net.minecraft.world.level.block.Block.dropResources(iblockdata, this.world.getMinecraftWorld(), position, this.world.getBlockEntity(position), null, nmsItem); diff --git a/patches/server/0355-Add-option-to-nerf-pigmen-from-nether-portals.patch b/patches/server/0355-Add-option-to-nerf-pigmen-from-nether-portals.patch index cda82d805d..578dcb5bbb 100644 --- a/patches/server/0355-Add-option-to-nerf-pigmen-from-nether-portals.patch +++ b/patches/server/0355-Add-option-to-nerf-pigmen-from-nether-portals.patch @@ -5,10 +5,10 @@ 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 8f8f8ec38737b50ad23bb2408f9f8262d7b3a507..6fa842ae2f419a42d830b417f4d624451e6c4325 100644 +index 64bd1cb6c5dd65a62df133926b969e37a3e31f76..479586efacc17e418dd8d64d884efe67355e1844 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 { +@@ -388,6 +388,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { // Paper start public long activatedImmunityTick = Integer.MIN_VALUE; // Paper public boolean isTemporarilyActive = false; // Paper @@ -16,7 +16,7 @@ index 8f8f8ec38737b50ad23bb2408f9f8262d7b3a507..6fa842ae2f419a42d830b417f4d62445 protected int numCollisions = 0; // Paper public boolean spawnedViaMobSpawner; // Paper - Yes this name is similar to above, upstream took the better one @javax.annotation.Nullable -@@ -2080,6 +2081,9 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -2081,6 +2082,9 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { if (spawnedViaMobSpawner) { nbt.putBoolean("Paper.FromMobSpawner", true); } @@ -26,7 +26,7 @@ index 8f8f8ec38737b50ad23bb2408f9f8262d7b3a507..6fa842ae2f419a42d830b417f4d62445 // Paper end return nbt; } catch (Throwable throwable) { -@@ -2222,6 +2226,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -2223,6 +2227,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { } spawnedViaMobSpawner = nbt.getBoolean("Paper.FromMobSpawner"); // Restore entity's from mob spawner status diff --git a/patches/server/0357-add-hand-to-BlockMultiPlaceEvent.patch b/patches/server/0357-add-hand-to-BlockMultiPlaceEvent.patch index 294afa1a91..bd7339a1d5 100644 --- a/patches/server/0357-add-hand-to-BlockMultiPlaceEvent.patch +++ b/patches/server/0357-add-hand-to-BlockMultiPlaceEvent.patch @@ -5,10 +5,10 @@ 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 b8dbc05857e5fa1c0bacabd022be3669884aba40..e35f44571666d125bb2ce6c30037c6298e428c3f 100644 +index f77bb8401f0d4b5acc64c8b707083bc251caf8e5..cdf93e8751fa2520881290b2a7385f99ec4d0dc2 100644 --- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java +++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java -@@ -364,13 +364,18 @@ public class CraftEventFactory { +@@ -366,13 +366,18 @@ public class CraftEventFactory { } org.bukkit.inventory.ItemStack item; diff --git a/patches/server/0363-Add-tick-times-API-and-mspt-command.patch b/patches/server/0363-Add-tick-times-API-and-mspt-command.patch index 505c2d540d..d538b5a761 100644 --- a/patches/server/0363-Add-tick-times-API-and-mspt-command.patch +++ b/patches/server/0363-Add-tick-times-API-and-mspt-command.patch @@ -184,10 +184,10 @@ index 2e29d1c3e5faf970bfaf3a545ef3553f284d68ef..d00545c31de383470bcb8e4d9c6edad2 + // Paper end } diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 5101993aabe77289b56f3ae33900a97d2177fe33..d728eec810e0586c38ca37010fdb665c93089d6b 100644 +index 2be7afb4cfd77dd2b6cb0ca700b52812f2b5ffe1..a59e4c85d69f342bb55942e8b12053d907e97dd9 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -2493,6 +2493,16 @@ public final class CraftServer implements Server { +@@ -2494,6 +2494,16 @@ public final class CraftServer implements Server { net.minecraft.server.MinecraftServer.getServer().tps15.getAverage() }; } diff --git a/patches/server/0364-Expose-MinecraftServer-isRunning.patch b/patches/server/0364-Expose-MinecraftServer-isRunning.patch index bcd7170a20..ee52cbd820 100644 --- a/patches/server/0364-Expose-MinecraftServer-isRunning.patch +++ b/patches/server/0364-Expose-MinecraftServer-isRunning.patch @@ -6,10 +6,10 @@ Subject: [PATCH] Expose MinecraftServer#isRunning This allows for plugins to detect if the server is actually turning off in onDisable rather than just plugins reloading. diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 271a17f767b316384fef563251a4777d297e2da2..341b441f54b65302ecfbf050ae740e2b25492a6d 100644 +index a59e4c85d69f342bb55942e8b12053d907e97dd9..d6ed4cff5dba860f8ccd694052d68034426949be 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -2686,5 +2686,10 @@ public final class CraftServer implements Server { +@@ -2687,5 +2687,10 @@ public final class CraftServer implements Server { public int getCurrentTick() { return net.minecraft.server.MinecraftServer.currentTick; } diff --git a/patches/server/0366-Pillager-patrol-spawn-settings-and-per-player-option.patch b/patches/server/0366-Pillager-patrol-spawn-settings-and-per-player-option.patch index adf30732bd..8499fba689 100644 --- a/patches/server/0366-Pillager-patrol-spawn-settings-and-per-player-option.patch +++ b/patches/server/0366-Pillager-patrol-spawn-settings-and-per-player-option.patch @@ -10,10 +10,10 @@ 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 72e29dc97b38bde3c44edec505fa26633fcdd243..9726ff668e252be8edf35ff3611ad0e774ca9aca 100644 +index b014f1bd167bad3e1dc613dce5c929f201ef27cc..421be41fc09d53b50c08e74f9c32a198e90a2c7c 100644 --- a/src/main/java/net/minecraft/server/level/ServerPlayer.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java -@@ -242,6 +242,7 @@ public class ServerPlayer extends Player { +@@ -244,6 +244,7 @@ public class ServerPlayer extends Player { public boolean wonGame; private int containerUpdateDelay; // Paper public long loginTime; // Paper diff --git a/patches/server/0370-Don-t-tick-dead-players.patch b/patches/server/0370-Don-t-tick-dead-players.patch index f71b69106d..4a700e795a 100644 --- a/patches/server/0370-Don-t-tick-dead-players.patch +++ b/patches/server/0370-Don-t-tick-dead-players.patch @@ -7,10 +7,10 @@ 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 9726ff668e252be8edf35ff3611ad0e774ca9aca..52ee3440b09b227bf1f488f374a0e282690f6ba4 100644 +index 421be41fc09d53b50c08e74f9c32a198e90a2c7c..e6945abd9337af07625793fb893718b00e67168a 100644 --- a/src/main/java/net/minecraft/server/level/ServerPlayer.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java -@@ -681,7 +681,7 @@ public class ServerPlayer extends Player { +@@ -683,7 +683,7 @@ public class ServerPlayer extends Player { public void doTick() { try { diff --git a/patches/server/0372-Optimize-Collision-to-not-load-chunks.patch b/patches/server/0372-Optimize-Collision-to-not-load-chunks.patch index a2e830ff6e..4adb47c4f3 100644 --- a/patches/server/0372-Optimize-Collision-to-not-load-chunks.patch +++ b/patches/server/0372-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 c334d750a1eac24474061de8e764d7366ada0578..54028d2702e2f168717f5492e7e1f4d4ef2bc778 100644 +index 4efa85f9c18927248dc2397df0bd3cd0a9063347..635d803066fa34a13174935ba0b63a0c86c0b1f4 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -818,6 +818,7 @@ public abstract class PlayerList { +@@ -820,6 +820,7 @@ public abstract class PlayerList { entityplayer1.forceSetPositionRotation(location.getX(), location.getY(), location.getZ(), location.getYaw(), location.getPitch()); // CraftBukkit end @@ -26,10 +26,10 @@ index c334d750a1eac24474061de8e764d7366ada0578..54028d2702e2f168717f5492e7e1f4d4 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 dc1af76289cee7e38f6cbfdb5e62fac5802a08b3..8c922e29ae57f781d4f27d53b04ed90a24d81ca4 100644 +index 479586efacc17e418dd8d64d884efe67355e1844..33d37c7e1bd7e676d70ba942476def5c49a59176 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -236,6 +236,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -237,6 +237,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { public org.bukkit.event.entity.CreatureSpawnEvent.SpawnReason spawnReason; // Paper public com.destroystokyo.paper.loottable.PaperLootableInventoryData lootableData; // Paper diff --git a/patches/server/0373-Don-t-move-existing-players-to-world-spawn.patch b/patches/server/0373-Don-t-move-existing-players-to-world-spawn.patch index 1ddfb5e09f..714d0165f7 100644 --- a/patches/server/0373-Don-t-move-existing-players-to-world-spawn.patch +++ b/patches/server/0373-Don-t-move-existing-players-to-world-spawn.patch @@ -13,10 +13,10 @@ 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 52ee3440b09b227bf1f488f374a0e282690f6ba4..007513080938a8d0cf43c050ef4e1132a939918c 100644 +index e6945abd9337af07625793fb893718b00e67168a..7dbf61d79db8a7f08e518c7858142bb0e0f469c4 100644 --- a/src/main/java/net/minecraft/server/level/ServerPlayer.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java -@@ -334,7 +334,7 @@ public class ServerPlayer extends Player { +@@ -336,7 +336,7 @@ public class ServerPlayer extends Player { this.stats = server.getPlayerList().getPlayerStats(this); this.advancements = server.getPlayerList().getPlayerAdvancements(this); this.setMaxUpStep(1.0F); @@ -25,20 +25,20 @@ index 52ee3440b09b227bf1f488f374a0e282690f6ba4..007513080938a8d0cf43c050ef4e1132 this.cachedSingleHashSet = new com.destroystokyo.paper.util.misc.PooledLinkedHashSets.PooledObjectLinkedOpenHashSet<>(this); // Paper -@@ -568,7 +568,7 @@ public class ServerPlayer extends Player { - position = Vec3.atCenterOf(((ServerLevel) world).getSharedSpawnPos()); +@@ -570,7 +570,7 @@ public class ServerPlayer extends Player { + position = Vec3.atCenterOf(world.getSharedSpawnPos()); } this.level = world; -- this.setPos(position.x(), position.y(), position.z()); +- this.setPos(position); + this.setPosRaw(position.x(), position.y(), position.z()); // Paper - don't register to chunks yet } 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 54028d2702e2f168717f5492e7e1f4d4ef2bc778..90631dcce9e102d9aa1b3f92078b762633b5cf40 100644 +index 635d803066fa34a13174935ba0b63a0c86c0b1f4..3f5706d4b30b74ba54032ed48d37990ce6ddd715 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -227,6 +227,7 @@ public abstract class PlayerList { +@@ -229,6 +229,7 @@ public abstract class PlayerList { // Paper start if (nbttagcompound == null) { player.spawnReason = org.bukkit.event.entity.CreatureSpawnEvent.SpawnReason.DEFAULT; // set Player SpawnReason to DEFAULT on first login diff --git a/patches/server/0375-Improved-Watchdog-Support.patch b/patches/server/0375-Improved-Watchdog-Support.patch index f657c9252f..7aca26937e 100644 --- a/patches/server/0375-Improved-Watchdog-Support.patch +++ b/patches/server/0375-Improved-Watchdog-Support.patch @@ -269,10 +269,10 @@ index f22c50f0a2ef05e9f52550db7c40b5b99632650c..549ea8e0fe702615eefcbfd1cd6a30e0 } diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java -index 90631dcce9e102d9aa1b3f92078b762633b5cf40..5c2105528b8e1820b3cc6379b27d363e267b6a7b 100644 +index 3f5706d4b30b74ba54032ed48d37990ce6ddd715..fd0b72abbbb237c640510aee65eafb9aa9fa0376 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -538,7 +538,7 @@ public abstract class PlayerList { +@@ -540,7 +540,7 @@ public abstract class PlayerList { this.cserver.getPluginManager().callEvent(playerQuitEvent); entityplayer.getBukkitEntity().disconnect(playerQuitEvent.getQuitMessage()); @@ -318,7 +318,7 @@ index 703830416a0483e960643bee269fe01e170112bd..ee1c9f2c8dd30b3f32a6d49aa1c43148 final String msg = String.format("BlockEntity threw exception at %s:%s,%s,%s", LevelChunk.this.getLevel().getWorld().getName(), this.getPos().getX(), this.getPos().getY(), this.getPos().getZ()); net.minecraft.server.MinecraftServer.LOGGER.error(msg, throwable); diff --git a/src/main/java/org/bukkit/craftbukkit/Main.java b/src/main/java/org/bukkit/craftbukkit/Main.java -index 8a7261bcda3fd436b12eae2877abb5ee1c45dbde..3522b9556fea11395b9951ef7265912ccaa70a55 100644 +index 5a22fdbcbe2f2eee2140bff87bc402a437792e9f..70d6bfa86a17cd0f12194e397d15db1833638de6 100644 --- a/src/main/java/org/bukkit/craftbukkit/Main.java +++ b/src/main/java/org/bukkit/craftbukkit/Main.java @@ -178,6 +178,36 @@ public class Main { diff --git a/patches/server/0379-Prevent-opening-inventories-when-frozen.patch b/patches/server/0379-Prevent-opening-inventories-when-frozen.patch index fb79898e65..0fbc94c923 100644 --- a/patches/server/0379-Prevent-opening-inventories-when-frozen.patch +++ b/patches/server/0379-Prevent-opening-inventories-when-frozen.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Prevent opening inventories when frozen diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java -index 007513080938a8d0cf43c050ef4e1132a939918c..71fac1a579b375759462b843d9ef7c8a2a463db5 100644 +index 7dbf61d79db8a7f08e518c7858142bb0e0f469c4..fedd9727e9d73fdbced6431b313a080705b1d9a5 100644 --- a/src/main/java/net/minecraft/server/level/ServerPlayer.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java -@@ -650,7 +650,7 @@ public class ServerPlayer extends Player { +@@ -652,7 +652,7 @@ public class ServerPlayer extends Player { containerUpdateDelay = level.paperConfig().tickRates.containerUpdate; } // Paper end @@ -17,7 +17,7 @@ index 007513080938a8d0cf43c050ef4e1132a939918c..71fac1a579b375759462b843d9ef7c8a this.closeContainer(org.bukkit.event.inventory.InventoryCloseEvent.Reason.CANT_USE); // Paper this.containerMenu = this.inventoryMenu; } -@@ -1499,7 +1499,7 @@ public class ServerPlayer extends Player { +@@ -1501,7 +1501,7 @@ public class ServerPlayer extends Player { } else { // CraftBukkit start this.containerMenu = container; @@ -27,10 +27,10 @@ index 007513080938a8d0cf43c050ef4e1132a939918c..71fac1a579b375759462b843d9ef7c8a this.initMenu(container); return OptionalInt.of(this.containerCounter); diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java -index f5b3190ffb9e9f92977afc9e40ddfa155d054865..b3307db9a0707dd0883d04637eb553995190ca1c 100644 +index 77314674a1f66a514f8f5a0fef5ca188b5af0b6a..14984e791bd9309672b1fb404b8552849854d393 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java -@@ -326,7 +326,7 @@ public class CraftHumanEntity extends CraftLivingEntity implements HumanEntity { +@@ -327,7 +327,7 @@ public class CraftHumanEntity extends CraftLivingEntity implements HumanEntity { if (adventure$title == null) adventure$title = net.kyori.adventure.text.serializer.legacy.LegacyComponentSerializer.legacySection().deserialize(container.getBukkitView().getTitle()); // Paper //player.connection.send(new ClientboundOpenScreenPacket(container.containerId, windowType, CraftChatMessage.fromString(title)[0])); // Paper - comment @@ -39,7 +39,7 @@ index f5b3190ffb9e9f92977afc9e40ddfa155d054865..b3307db9a0707dd0883d04637eb55399 player.containerMenu = container; player.initMenu(container); } -@@ -400,7 +400,7 @@ public class CraftHumanEntity extends CraftLivingEntity implements HumanEntity { +@@ -401,7 +401,7 @@ public class CraftHumanEntity extends CraftLivingEntity implements HumanEntity { net.kyori.adventure.text.Component adventure$title = inventory.title(); // Paper if (adventure$title == null) adventure$title = net.kyori.adventure.text.serializer.legacy.LegacyComponentSerializer.legacySection().deserialize(inventory.getTitle()); // Paper //player.connection.send(new ClientboundOpenScreenPacket(container.containerId, windowType, CraftChatMessage.fromString(title)[0])); // Paper - comment diff --git a/patches/server/0381-Implement-Player-Client-Options-API.patch b/patches/server/0381-Implement-Player-Client-Options-API.patch index 2fe03d3c1b..0980f77c4f 100644 --- a/patches/server/0381-Implement-Player-Client-Options-API.patch +++ b/patches/server/0381-Implement-Player-Client-Options-API.patch @@ -87,10 +87,10 @@ index 0000000000000000000000000000000000000000..b6f4400df3d8ec7e06a996de54f8cabb + } +} diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java -index 71fac1a579b375759462b843d9ef7c8a2a463db5..2d54f2abae82521fbd34aa046f26ec8e72df8362 100644 +index fedd9727e9d73fdbced6431b313a080705b1d9a5..75350988934c6eb1cd39587fa1f53335bf05db17 100644 --- a/src/main/java/net/minecraft/server/level/ServerPlayer.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java -@@ -1902,9 +1902,24 @@ public class ServerPlayer extends Player { +@@ -1904,9 +1904,24 @@ public class ServerPlayer extends Player { } } @@ -116,10 +116,10 @@ index 71fac1a579b375759462b843d9ef7c8a2a463db5..2d54f2abae82521fbd34aa046f26ec8e if (getMainArm() != packet.mainHand()) { PlayerChangedMainHandEvent event = new PlayerChangedMainHandEvent(this.getBukkitEntity(), getMainArm() == HumanoidArm.LEFT ? MainHand.LEFT : MainHand.RIGHT); diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -index f21bbbc7ff8aee29e0eb35e779bf02dbba703950..16cc7cfd39158cfb4045375d8be664b91d4a57d4 100644 +index 5e4735ed74e47c28d85c2e7e08458e74f6559e47..a77858a6253a3195879aaa3bccccee6c0af5b00a 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -@@ -622,6 +622,28 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -626,6 +626,28 @@ public class CraftPlayer extends CraftHumanEntity implements Player { connection.disconnect(message == null ? net.kyori.adventure.text.Component.empty() : message); } } diff --git a/patches/server/0383-Fix-Longstanding-Broken-behavior-of-PlayerJoinEvent.patch b/patches/server/0383-Fix-Longstanding-Broken-behavior-of-PlayerJoinEvent.patch index 3906b0fa27..4d7a62672a 100644 --- a/patches/server/0383-Fix-Longstanding-Broken-behavior-of-PlayerJoinEvent.patch +++ b/patches/server/0383-Fix-Longstanding-Broken-behavior-of-PlayerJoinEvent.patch @@ -43,10 +43,10 @@ index 9c5925bc6a0fb277970d46c34dd812cc765a537a..f2bdb647f137a1334789dc56e517844b 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 2d54f2abae82521fbd34aa046f26ec8e72df8362..e465e3e45eeeecc31dafc1f04505c04ea382615a 100644 +index 75350988934c6eb1cd39587fa1f53335bf05db17..35091999392e7c5e6763aee490020c675e19134b 100644 --- a/src/main/java/net/minecraft/server/level/ServerPlayer.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java -@@ -265,6 +265,7 @@ public class ServerPlayer extends Player { +@@ -267,6 +267,7 @@ public class ServerPlayer extends Player { public double maxHealthCache; public boolean joining = true; public boolean sentListPacket = false; @@ -55,10 +55,10 @@ index 2d54f2abae82521fbd34aa046f26ec8e72df8362..e465e3e45eeeecc31dafc1f04505c04e 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 5c2105528b8e1820b3cc6379b27d363e267b6a7b..a0832d8e8b9e91073c15e5a87953d6ccee544ae0 100644 +index fd0b72abbbb237c640510aee65eafb9aa9fa0376..0e2a84148e721a8f799f0746e379c16a5f7f0dd3 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -302,6 +302,12 @@ public abstract class PlayerList { +@@ -304,6 +304,12 @@ public abstract class PlayerList { this.playersByUUID.put(player.getUUID(), player); // this.broadcastAll(ClientboundPlayerInfoUpdatePacket.createPlayerInitializing(List.of(entityplayer))); // CraftBukkit - replaced with loop below @@ -71,7 +71,7 @@ index 5c2105528b8e1820b3cc6379b27d363e267b6a7b..a0832d8e8b9e91073c15e5a87953d6cc // CraftBukkit start CraftPlayer bukkitPlayer = player.getBukkitEntity(); -@@ -340,6 +346,8 @@ public abstract class PlayerList { +@@ -342,6 +348,8 @@ public abstract class PlayerList { player.connection.send(ClientboundPlayerInfoUpdatePacket.createPlayerInitializing(List.of(entityplayer1))); } player.sentListPacket = true; @@ -80,7 +80,7 @@ index 5c2105528b8e1820b3cc6379b27d363e267b6a7b..a0832d8e8b9e91073c15e5a87953d6cc // CraftBukkit end player.getEntityData().refresh(player); // CraftBukkit - BungeeCord#2321, send complete data to self on spawn -@@ -365,6 +373,11 @@ public abstract class PlayerList { +@@ -367,6 +375,11 @@ public abstract class PlayerList { playerconnection.send(new ClientboundUpdateMobEffectPacket(player.getId(), mobeffect)); } @@ -92,7 +92,7 @@ index 5c2105528b8e1820b3cc6379b27d363e267b6a7b..a0832d8e8b9e91073c15e5a87953d6cc if (nbttagcompound != null && nbttagcompound.contains("RootVehicle", 10)) { CompoundTag nbttagcompound1 = nbttagcompound.getCompound("RootVehicle"); // CraftBukkit start -@@ -413,6 +426,10 @@ public abstract class PlayerList { +@@ -415,6 +428,10 @@ public abstract class PlayerList { } } @@ -103,7 +103,7 @@ index 5c2105528b8e1820b3cc6379b27d363e267b6a7b..a0832d8e8b9e91073c15e5a87953d6cc player.initInventoryMenu(); // CraftBukkit - Moved from above, added world // Paper start - Add to collideRule team if needed -@@ -422,6 +439,7 @@ public abstract class PlayerList { +@@ -424,6 +441,7 @@ public abstract class PlayerList { scoreboard.addPlayerToTeam(player.getScoreboardName(), collideRuleTeam); } // Paper end diff --git a/patches/server/0384-Move-player-to-spawn-point-if-spawn-in-unloaded-worl.patch b/patches/server/0384-Move-player-to-spawn-point-if-spawn-in-unloaded-worl.patch index a00181f54c..d1daf68a0e 100644 --- a/patches/server/0384-Move-player-to-spawn-point-if-spawn-in-unloaded-worl.patch +++ b/patches/server/0384-Move-player-to-spawn-point-if-spawn-in-unloaded-worl.patch @@ -7,10 +7,10 @@ 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 8cfa823940b0fada04022034023f5372f1ca8b9f..d3f9954bda58b459e2f64b5d949807ab60905d48 100644 +index 33d37c7e1bd7e676d70ba942476def5c49a59176..ecff22945c0a4cbc5cd26c04bb8e6416ba07fffd 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -2199,9 +2199,11 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -2200,9 +2200,11 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { bworld = server.getWorld(worldName); } diff --git a/patches/server/0388-Fix-numerous-item-duplication-issues-and-teleport-is.patch b/patches/server/0388-Fix-numerous-item-duplication-issues-and-teleport-is.patch index daf9eb7706..61dce981a6 100644 --- a/patches/server/0388-Fix-numerous-item-duplication-issues-and-teleport-is.patch +++ b/patches/server/0388-Fix-numerous-item-duplication-issues-and-teleport-is.patch @@ -16,10 +16,10 @@ 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 d04c5cd4afd09fbe511811a198135c19ee99c036..52339e85607adb77c260744a48701d8d8da4ef2e 100644 +index ecff22945c0a4cbc5cd26c04bb8e6416ba07fffd..04a388bd3a89a27f0b75134ef781b5e22da633de 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -2329,11 +2329,12 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -2330,11 +2330,12 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { } else { // CraftBukkit start - Capture drops for death event if (this instanceof net.minecraft.world.entity.LivingEntity && !((net.minecraft.world.entity.LivingEntity) this).forceDrops) { @@ -34,7 +34,7 @@ index d04c5cd4afd09fbe511811a198135c19ee99c036..52339e85607adb77c260744a48701d8d entityitem.setDefaultPickUpDelay(); // CraftBukkit start -@@ -3114,6 +3115,12 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -3115,6 +3116,12 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { @Nullable public Entity teleportTo(ServerLevel worldserver, PositionImpl location) { // CraftBukkit end @@ -47,7 +47,7 @@ index d04c5cd4afd09fbe511811a198135c19ee99c036..52339e85607adb77c260744a48701d8d if (this.level instanceof ServerLevel && !this.isRemoved()) { this.level.getProfiler().push("changeDimension"); // CraftBukkit start -@@ -3140,6 +3147,11 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -3141,6 +3148,11 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { // CraftBukkit end this.level.getProfiler().popPush("reloading"); @@ -59,7 +59,7 @@ index d04c5cd4afd09fbe511811a198135c19ee99c036..52339e85607adb77c260744a48701d8d Entity entity = this.getType().create(worldserver); if (entity != null) { -@@ -3153,10 +3165,6 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -3154,10 +3166,6 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { // CraftBukkit start - Forward the CraftEntity to the new entity this.getBukkitEntity().setHandle(entity); entity.bukkitEntity = this.getBukkitEntity(); @@ -70,7 +70,7 @@ index d04c5cd4afd09fbe511811a198135c19ee99c036..52339e85607adb77c260744a48701d8d // CraftBukkit end } -@@ -3277,7 +3285,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -3278,7 +3286,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { } public boolean canChangeDimensions() { @@ -135,10 +135,10 @@ index dbb4bfb3d1f1ce2e435ca531be36ea448c0e3212..3be5ea477cb3dd3ce75f3feced8daf7c } } diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java -index e35f44571666d125bb2ce6c30037c6298e428c3f..81d1654ed3520df5cecb929b7089528893b2fd29 100644 +index cdf93e8751fa2520881290b2a7385f99ec4d0dc2..195f5ef5fcabcf021e429b2a51aa274e929c7322 100644 --- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java +++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java -@@ -825,6 +825,11 @@ public class CraftEventFactory { +@@ -827,6 +827,11 @@ public class CraftEventFactory { } public static EntityDeathEvent callEntityDeathEvent(net.minecraft.world.entity.LivingEntity victim, List drops) { @@ -150,7 +150,7 @@ index e35f44571666d125bb2ce6c30037c6298e428c3f..81d1654ed3520df5cecb929b70895288 CraftLivingEntity entity = (CraftLivingEntity) victim.getBukkitEntity(); EntityDeathEvent event = new EntityDeathEvent(entity, drops, victim.getExpReward()); populateFields(victim, event); // Paper - make cancellable -@@ -838,11 +843,13 @@ public class CraftEventFactory { +@@ -840,11 +845,13 @@ public class CraftEventFactory { playDeathSound(victim, event); // Paper end victim.expToDrop = event.getDroppedExp(); diff --git a/patches/server/0389-Villager-Restocks-API.patch b/patches/server/0389-Villager-Restocks-API.patch index 6d4323cd05..6aa68682f0 100644 --- a/patches/server/0389-Villager-Restocks-API.patch +++ b/patches/server/0389-Villager-Restocks-API.patch @@ -7,10 +7,10 @@ Subject: [PATCH] Villager Restocks API public net.minecraft.world.entity.npc.Villager numberOfRestocksToday diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftVillager.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftVillager.java -index e4f0770b0c9a00b813f3473298fb0d5e21e7c008..4f73b71fb39eab10c44da31617632a83e4f0b83f 100644 +index 7479a68d9c1025c8f2cd784b2607b549d40f3638..ae8c32c3497125fa2d1959e3a44b7c3013646762 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftVillager.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftVillager.java -@@ -91,6 +91,18 @@ public class CraftVillager extends CraftAbstractVillager implements Villager { +@@ -92,6 +92,18 @@ public class CraftVillager extends CraftAbstractVillager implements Villager { this.getHandle().setVillagerXp(experience); } diff --git a/patches/server/0390-Validate-PickItem-Packet-and-kick-for-invalid.patch b/patches/server/0390-Validate-PickItem-Packet-and-kick-for-invalid.patch index 27ca3fd900..82f1ef7c08 100644 --- a/patches/server/0390-Validate-PickItem-Packet-and-kick-for-invalid.patch +++ b/patches/server/0390-Validate-PickItem-Packet-and-kick-for-invalid.patch @@ -5,10 +5,10 @@ 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 e4d65aff300c276d0968b9786ddc20ba63caca41..2a35bedae3682126b365c6fd56b0db5febd7fccb 100644 +index 4ad848bd15a9bcb14a53e7f391938982a2f4c207..39dbdfe8c74b2bf3d57f59c073f882dd2eca79ab 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -958,7 +958,14 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -959,7 +959,14 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic @Override public void handlePickItem(ServerboundPickItemPacket packet) { PacketUtils.ensureRunningOnSameThread(packet, this, this.player.getLevel()); diff --git a/patches/server/0391-Expose-game-version.patch b/patches/server/0391-Expose-game-version.patch index 8a3b67204f..66090aa90e 100644 --- a/patches/server/0391-Expose-game-version.patch +++ b/patches/server/0391-Expose-game-version.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Expose game version diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 341b441f54b65302ecfbf050ae740e2b25492a6d..bb467c24daedeaef5509cd62ffed959eedcc0caa 100644 +index d6ed4cff5dba860f8ccd694052d68034426949be..c69b341774d2e1624344a62e52cdf9764195033a 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -569,6 +569,13 @@ public final class CraftServer implements Server { +@@ -570,6 +570,13 @@ public final class CraftServer implements Server { return this.bukkitVersion; } diff --git a/patches/server/0394-misc-debugging-dumps.patch b/patches/server/0394-misc-debugging-dumps.patch index adb9e87a39..a3e5aaa046 100644 --- a/patches/server/0394-misc-debugging-dumps.patch +++ b/patches/server/0394-misc-debugging-dumps.patch @@ -74,10 +74,10 @@ index 0c7f280bae81bbb492d5780a43e5ffda0f58756a..238a7bc87ab49da1f0fa3c733dd512fd this.connection.send(new ClientboundDisconnectPacket(ichatmutablecomponent)); this.connection.disconnect(ichatmutablecomponent); diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 530b22cbeca53755629d82ee64a795e569f2737e..e6c089f45d3b205eeaa1e52a15bc0aa055773a2d 100644 +index c69b341774d2e1624344a62e52cdf9764195033a..1f1f63a37fdbed26e7cc77ecc19d546c2ef12c36 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -992,6 +992,7 @@ public final class CraftServer implements Server { +@@ -993,6 +993,7 @@ public final class CraftServer implements Server { plugin.getDescription().getFullName(), "This plugin is not properly shutting down its async tasks when it is being reloaded. This may cause conflicts with the newly loaded version of the plugin" )); diff --git a/patches/server/0395-Prevent-teleporting-dead-entities.patch b/patches/server/0395-Prevent-teleporting-dead-entities.patch index d77878af20..d918d0e66d 100644 --- a/patches/server/0395-Prevent-teleporting-dead-entities.patch +++ b/patches/server/0395-Prevent-teleporting-dead-entities.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Prevent teleporting dead entities diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 2a35bedae3682126b365c6fd56b0db5febd7fccb..fb292133ca77305d91acdded78d11f5118b5f282 100644 +index 39dbdfe8c74b2bf3d57f59c073f882dd2eca79ab..f77abe31d6d56c11dba390cca4b8069bc535103a 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -1612,6 +1612,13 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -1613,6 +1613,13 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic } public void internalTeleport(double d0, double d1, double d2, float f, float f1, Set set) { // Paper diff --git a/patches/server/0397-Implement-Mob-Goal-API.patch b/patches/server/0397-Implement-Mob-Goal-API.patch index 3dec09cafd..cd55696f7c 100644 --- a/patches/server/0397-Implement-Mob-Goal-API.patch +++ b/patches/server/0397-Implement-Mob-Goal-API.patch @@ -792,10 +792,10 @@ index 4379b9948f1eecfe6fd7dea98e298ad5f761019a..3f081183521603824430709886a9cc31 LOOK, JUMP, diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index e6c089f45d3b205eeaa1e52a15bc0aa055773a2d..bec471a617780e4fa88d4c559c42175370687d7b 100644 +index 1f1f63a37fdbed26e7cc77ecc19d546c2ef12c36..d8ff8f02adbe532724d47fef5142fdf9b08de10d 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -2699,5 +2699,11 @@ public final class CraftServer implements Server { +@@ -2700,5 +2700,11 @@ public final class CraftServer implements Server { public boolean isStopping() { return net.minecraft.server.MinecraftServer.getServer().hasStopped(); } diff --git a/patches/server/0398-Add-villager-reputation-API.patch b/patches/server/0398-Add-villager-reputation-API.patch index 3d1a6efbc0..a745be8032 100644 --- a/patches/server/0398-Add-villager-reputation-API.patch +++ b/patches/server/0398-Add-villager-reputation-API.patch @@ -57,10 +57,10 @@ index a28f359202e6502c6ea5e9c918ec0b3e9a3fca61..76dffb2705e5207db96895f82f1c7c56 static record GossipEntry(UUID target, GossipType type, int value) { diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftVillager.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftVillager.java -index 4f73b71fb39eab10c44da31617632a83e4f0b83f..1fa8026ca63b7e38870daac59936a10b1950561e 100644 +index ae8c32c3497125fa2d1959e3a44b7c3013646762..a1705b0fae9574d4ce2bb815ea57a35f8551c3a6 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftVillager.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftVillager.java -@@ -17,6 +17,13 @@ import org.bukkit.entity.Villager; +@@ -18,6 +18,13 @@ import org.bukkit.entity.Villager; import org.bukkit.entity.ZombieVillager; import org.bukkit.event.entity.CreatureSpawnEvent; @@ -74,7 +74,7 @@ index 4f73b71fb39eab10c44da31617632a83e4f0b83f..1fa8026ca63b7e38870daac59936a10b public class CraftVillager extends CraftAbstractVillager implements Villager { public CraftVillager(CraftServer server, net.minecraft.world.entity.npc.Villager entity) { -@@ -146,4 +153,45 @@ public class CraftVillager extends CraftAbstractVillager implements Villager { +@@ -147,4 +154,45 @@ public class CraftVillager extends CraftAbstractVillager implements Villager { public static VillagerProfession bukkitToNmsProfession(Profession bukkit) { return BuiltInRegistries.VILLAGER_PROFESSION.get(CraftNamespacedKey.toMinecraft(bukkit.getKey())); } diff --git a/patches/server/0399-Option-for-maximum-exp-value-when-merging-orbs.patch b/patches/server/0399-Option-for-maximum-exp-value-when-merging-orbs.patch index c55717a469..466b49e0b3 100644 --- a/patches/server/0399-Option-for-maximum-exp-value-when-merging-orbs.patch +++ b/patches/server/0399-Option-for-maximum-exp-value-when-merging-orbs.patch @@ -5,10 +5,10 @@ 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 81d1654ed3520df5cecb929b7089528893b2fd29..5f61fe52c6fc15c3114a6ba44eea6d219228f26e 100644 +index 195f5ef5fcabcf021e429b2a51aa274e929c7322..52d4e6904601d680c89168d2b1e765868d57e798 100644 --- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java +++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java -@@ -646,16 +646,30 @@ public class CraftEventFactory { +@@ -648,16 +648,30 @@ public class CraftEventFactory { net.minecraft.world.entity.ExperienceOrb xp = (net.minecraft.world.entity.ExperienceOrb) entity; double radius = world.spigotConfig.expMerge; if (radius > 0) { diff --git a/patches/server/0400-ExperienceOrbMergeEvent.patch b/patches/server/0400-ExperienceOrbMergeEvent.patch index 33df908fa4..4a0c8ba371 100644 --- a/patches/server/0400-ExperienceOrbMergeEvent.patch +++ b/patches/server/0400-ExperienceOrbMergeEvent.patch @@ -9,10 +9,10 @@ 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 5f61fe52c6fc15c3114a6ba44eea6d219228f26e..6045ebda7250545c255c1e1c1eb614deff3dfc96 100644 +index 52d4e6904601d680c89168d2b1e765868d57e798..0ad0d6e15f57c16fb71f988ac7d0d2e243493801 100644 --- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java +++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java -@@ -656,7 +656,7 @@ public class CraftEventFactory { +@@ -658,7 +658,7 @@ public class CraftEventFactory { if (e instanceof net.minecraft.world.entity.ExperienceOrb) { net.minecraft.world.entity.ExperienceOrb loopItem = (net.minecraft.world.entity.ExperienceOrb) e; // Paper start diff --git a/patches/server/0403-Potential-bed-API.patch b/patches/server/0403-Potential-bed-API.patch index 9725646220..2d479f5c15 100644 --- a/patches/server/0403-Potential-bed-API.patch +++ b/patches/server/0403-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 b3307db9a0707dd0883d04637eb553995190ca1c..728fc30046de534748e2379e8cb371cc2e51f9d3 100644 +index 14984e791bd9309672b1fb404b8552849854d393..3f6e9214358c938b39106dd6c3eb652c8549c60b 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; @@ -19,7 +19,7 @@ index b3307db9a0707dd0883d04637eb553995190ca1c..728fc30046de534748e2379e8cb371cc import net.minecraft.server.level.ServerPlayer; import net.minecraft.world.MenuProvider; import net.minecraft.world.entity.Entity; -@@ -129,6 +130,22 @@ public class CraftHumanEntity extends CraftLivingEntity implements HumanEntity { +@@ -130,6 +131,22 @@ public class CraftHumanEntity extends CraftLivingEntity implements HumanEntity { return this.getHandle().sleepCounter; } diff --git a/patches/server/0404-Wait-for-Async-Tasks-during-shutdown.patch b/patches/server/0404-Wait-for-Async-Tasks-during-shutdown.patch index 2a117108e6..1b7d3410de 100644 --- a/patches/server/0404-Wait-for-Async-Tasks-during-shutdown.patch +++ b/patches/server/0404-Wait-for-Async-Tasks-during-shutdown.patch @@ -22,10 +22,10 @@ index e189de6d2aa94e9bbb20f1477ee2e34431adb324..4a58843f7ce2dd9e50f9daf3065d056a // CraftBukkit end if (this.getConnection() != null) { diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 4d51834b6e7bc9058579ce5c6b88f5e9e1c3155d..670ad9f79e2430e956ef204c7e7bf0c651810c06 100644 +index d8ff8f02adbe532724d47fef5142fdf9b08de10d..86acd4c9acc33197fb9d35381677152521168cf1 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -1002,6 +1002,31 @@ public final class CraftServer implements Server { +@@ -1003,6 +1003,31 @@ public final class CraftServer implements Server { org.spigotmc.WatchdogThread.hasStarted = true; // Paper - Disable watchdog early timeout on reload } diff --git a/patches/server/0406-Protect-Bedrock-and-End-Portal-Frames-from-being-des.patch b/patches/server/0406-Protect-Bedrock-and-End-Portal-Frames-from-being-des.patch index bb1d9519a4..8baaafa837 100644 --- a/patches/server/0406-Protect-Bedrock-and-End-Portal-Frames-from-being-des.patch +++ b/patches/server/0406-Protect-Bedrock-and-End-Portal-Frames-from-being-des.patch @@ -13,7 +13,7 @@ A config is provided if you rather let players use these exploits, and let them destroy the worlds End Portals and get on top of the nether easy. diff --git a/src/main/java/net/minecraft/world/level/Explosion.java b/src/main/java/net/minecraft/world/level/Explosion.java -index 83b2b56dbb6d74b58c43bf375ae7d1df9805037b..a85ca27817981552680c58ad49866997a875018d 100644 +index d2518db0dacbb1278b03da77a355fd23ff680b91..ec187a4969a84e50014f846f5af54b32c235d471 100644 --- a/src/main/java/net/minecraft/world/level/Explosion.java +++ b/src/main/java/net/minecraft/world/level/Explosion.java @@ -168,6 +168,7 @@ public class Explosion { @@ -24,9 +24,9 @@ index 83b2b56dbb6d74b58c43bf375ae7d1df9805037b..a85ca27817981552680c58ad49866997 FluidState fluid = iblockdata.getFluidState(); // Paper if (!this.level.isInWorldBounds(blockposition)) { -@@ -359,7 +360,7 @@ public class Explosion { - BlockState iblockdata = this.level.getBlockState(blockposition); - Block block = iblockdata.getBlock(); +@@ -369,7 +370,7 @@ public class Explosion { + } + // CraftBukkit end - if (!iblockdata.isAir()) { + if (!iblockdata.isAir() && iblockdata.isDestroyable()) { // Paper diff --git a/patches/server/0411-Optimize-anyPlayerCloseEnoughForSpawning-to-use-dist.patch b/patches/server/0411-Optimize-anyPlayerCloseEnoughForSpawning-to-use-dist.patch index 9a6057989a..14780f2fc1 100644 --- a/patches/server/0411-Optimize-anyPlayerCloseEnoughForSpawning-to-use-dist.patch +++ b/patches/server/0411-Optimize-anyPlayerCloseEnoughForSpawning-to-use-dist.patch @@ -333,10 +333,10 @@ index 665e088cb0b73f6a0c62f29c56da462bab7c927e..298e4468f7b5346733257f7117f76c66 } diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java -index e465e3e45eeeecc31dafc1f04505c04ea382615a..5be828ad63184ee01519ef937e98f621a4e83dee 100644 +index 35091999392e7c5e6763aee490020c675e19134b..245ac1e53bfcb1888e8f10d632b181cf31d6d030 100644 --- a/src/main/java/net/minecraft/server/level/ServerPlayer.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java -@@ -270,6 +270,7 @@ public class ServerPlayer extends Player { +@@ -272,6 +272,7 @@ public class ServerPlayer extends Player { public String kickLeaveMessage = null; // SPIGOT-3034: Forward leave message to PlayerQuitEvent // CraftBukkit end public boolean isRealPlayer; // Paper diff --git a/patches/server/0412-Use-distance-map-to-optimise-entity-tracker.patch b/patches/server/0412-Use-distance-map-to-optimise-entity-tracker.patch index f77d5cb393..05af350a50 100644 --- a/patches/server/0412-Use-distance-map-to-optimise-entity-tracker.patch +++ b/patches/server/0412-Use-distance-map-to-optimise-entity-tracker.patch @@ -287,7 +287,7 @@ index 4b7c39595302a738e6d4a1749473ef9c81f84fea..503a642165f6f1292c07e8a9e618218b 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 c69cc5dadac4bd81f08258f0420b7acd506cb04a..133a544274f4a80071c2a3306f5b0cd47cd6a270 100644 +index 04a388bd3a89a27f0b75134ef781b5e22da633de..2c9a829c3376e8767627fc94bb063486c7d0d81c 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; @@ -298,7 +298,7 @@ index c69cc5dadac4bd81f08258f0420b7acd506cb04a..133a544274f4a80071c2a3306f5b0cd4 import net.minecraft.server.MinecraftServer; import net.minecraft.server.level.ServerLevel; import net.minecraft.server.level.ServerPlayer; -@@ -476,6 +477,38 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -477,6 +478,38 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { public boolean updatingSectionStatus = false; // Paper end @@ -338,10 +338,10 @@ index c69cc5dadac4bd81f08258f0420b7acd506cb04a..133a544274f4a80071c2a3306f5b0cd4 public Entity(EntityType type, Level world) { this.id = Entity.ENTITY_COUNTER.incrementAndGet(); diff --git a/src/main/java/org/spigotmc/TrackingRange.java b/src/main/java/org/spigotmc/TrackingRange.java -index 55ce69b5fe097841d00ef5c241459dce9bb0d4db..e5bcbfe175a697e04886d04543e1278b7e83a184 100644 +index 71225959e1b17974374b1fb998de573ea55d85a4..6ac5de214d0da921d0d0c822e7063f6738788cac 100644 --- a/src/main/java/org/spigotmc/TrackingRange.java +++ b/src/main/java/org/spigotmc/TrackingRange.java -@@ -24,6 +24,7 @@ public class TrackingRange +@@ -25,6 +25,7 @@ public class TrackingRange { return defaultRange; } @@ -349,8 +349,8 @@ index 55ce69b5fe097841d00ef5c241459dce9bb0d4db..e5bcbfe175a697e04886d04543e1278b SpigotWorldConfig config = entity.level.spigotConfig; if ( entity instanceof ServerPlayer ) { -@@ -47,8 +48,48 @@ public class TrackingRange - return config.miscTrackingRange; +@@ -51,8 +52,48 @@ public class TrackingRange + return config.displayTrackingRange; } else { - if (entity instanceof net.minecraft.world.entity.boss.enderdragon.EnderDragon) return ((net.minecraft.server.level.ServerLevel)(entity.getCommandSenderWorld())).getChunkSource().chunkMap.getEffectiveViewDistance(); // Paper - enderdragon is exempt diff --git a/patches/server/0420-Prevent-position-desync-in-playerconnection-causing-.patch b/patches/server/0420-Prevent-position-desync-in-playerconnection-causing-.patch index 3b98149148..b0f884fd23 100644 --- a/patches/server/0420-Prevent-position-desync-in-playerconnection-causing-.patch +++ b/patches/server/0420-Prevent-position-desync-in-playerconnection-causing-.patch @@ -14,10 +14,10 @@ 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 fb292133ca77305d91acdded78d11f5118b5f282..8fbb4a73968e2a6694294997f99dfe40fd7a09b2 100644 +index f77abe31d6d56c11dba390cca4b8069bc535103a..16eaffffd78e60a79cdd6a15abab90c81affce78 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -1437,6 +1437,11 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -1438,6 +1438,11 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic this.player.move(MoverType.PLAYER, new Vec3(d7, d8, d9)); this.player.onGround = packet.isOnGround(); // CraftBukkit - SPIGOT-5810, SPIGOT-5835, SPIGOT-6828: reset by this.player.move diff --git a/patches/server/0423-Add-and-implement-PlayerRecipeBookClickEvent.patch b/patches/server/0423-Add-and-implement-PlayerRecipeBookClickEvent.patch index 70154b87a0..6045e95588 100644 --- a/patches/server/0423-Add-and-implement-PlayerRecipeBookClickEvent.patch +++ b/patches/server/0423-Add-and-implement-PlayerRecipeBookClickEvent.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Add and implement PlayerRecipeBookClickEvent diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 8fbb4a73968e2a6694294997f99dfe40fd7a09b2..29254fe0d4a4fef5062a21773afea707d48a5538 100644 +index 38ee1f5b16e60405947b171030fc7d828440aeb0..cf1034b252d95913a3888a04b1658644c0e8e374 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -3108,9 +3108,15 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -3115,9 +3115,15 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic if (!this.player.containerMenu.stillValid(this.player)) { ServerGamePacketListenerImpl.LOGGER.debug("Player {} interacted with invalid menu {}", this.player, this.player.containerMenu); } else { diff --git a/patches/server/0425-Add-permission-for-command-blocks.patch b/patches/server/0425-Add-permission-for-command-blocks.patch index fc38dc20f1..308fb39db3 100644 --- a/patches/server/0425-Add-permission-for-command-blocks.patch +++ b/patches/server/0425-Add-permission-for-command-blocks.patch @@ -18,10 +18,10 @@ index 051cbce8394c7a629a7ea8ac422308d96bbad6a6..52d71b08c8338254a0e50780363155da 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 29254fe0d4a4fef5062a21773afea707d48a5538..bd021ff4a5e3bd5dde2829718c0f57d9fc9aa93d 100644 +index 16baa852df509a3180dc38c8e1c262bf5602b539..cf065dc3a37080fd74c240271d4699ea278ac333 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -869,7 +869,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -870,7 +870,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic PacketUtils.ensureRunningOnSameThread(packet, this, this.player.getLevel()); if (!this.server.isCommandBlockEnabled()) { this.player.sendSystemMessage(Component.translatable("advMode.notEnabled")); @@ -30,7 +30,7 @@ index 29254fe0d4a4fef5062a21773afea707d48a5538..bd021ff4a5e3bd5dde2829718c0f57d9 this.player.sendSystemMessage(Component.translatable("advMode.notAllowed")); } else { BaseCommandBlock commandblocklistenerabstract = null; -@@ -936,7 +936,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -937,7 +937,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic PacketUtils.ensureRunningOnSameThread(packet, this, this.player.getLevel()); if (!this.server.isCommandBlockEnabled()) { this.player.sendSystemMessage(Component.translatable("advMode.notEnabled")); diff --git a/patches/server/0426-Ensure-Entity-AABB-s-are-never-invalid.patch b/patches/server/0426-Ensure-Entity-AABB-s-are-never-invalid.patch index 6a1af473d2..1435741fc5 100644 --- a/patches/server/0426-Ensure-Entity-AABB-s-are-never-invalid.patch +++ b/patches/server/0426-Ensure-Entity-AABB-s-are-never-invalid.patch @@ -5,10 +5,10 @@ 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 b95ef3e7c13cee1af59bdb8aa4cc01adb3ae7953..b69615eafcee963862cb3671888dcf8ec5114fe5 100644 +index 2c9a829c3376e8767627fc94bb063486c7d0d81c..24ba8dc2a5fc72ade003fa14d337f2c64a0e654e 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -714,8 +714,8 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -715,8 +715,8 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { } public void setPos(double x, double y, double z) { @@ -19,7 +19,7 @@ index b95ef3e7c13cee1af59bdb8aa4cc01adb3ae7953..b69615eafcee963862cb3671888dcf8e } protected AABB makeBoundingBox() { -@@ -4074,6 +4074,11 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -4075,6 +4075,11 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { } public final void setPosRaw(double x, double y, double z) { @@ -31,7 +31,7 @@ index b95ef3e7c13cee1af59bdb8aa4cc01adb3ae7953..b69615eafcee963862cb3671888dcf8e // Paper start - rewrite chunk system if (this.updatingSectionStatus) { LOGGER.error("Refusing to update position for entity " + this + " to position " + new Vec3(x, y, z) + " since it is processing a section status update", new Throwable()); -@@ -4097,6 +4102,12 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -4098,6 +4103,12 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { this.levelCallback.onMove(); } diff --git a/patches/server/0427-Fix-Per-World-Difficulty-Remembering-Difficulty.patch b/patches/server/0427-Fix-Per-World-Difficulty-Remembering-Difficulty.patch index d424f26780..e9be92ec6d 100644 --- a/patches/server/0427-Fix-Per-World-Difficulty-Remembering-Difficulty.patch +++ b/patches/server/0427-Fix-Per-World-Difficulty-Remembering-Difficulty.patch @@ -76,10 +76,10 @@ index 771677c0e1cd7bfe089b9a5bb9095650216ff588..520cd1a6b347687b2ec6d13f034be391 @Override diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java -index 5be828ad63184ee01519ef937e98f621a4e83dee..d560e5dee586bb3b501e9a78083b9aa961c48fc5 100644 +index 245ac1e53bfcb1888e8f10d632b181cf31d6d030..2c052d0a8c6d58ad8eae41c22c753327342e90f1 100644 --- a/src/main/java/net/minecraft/server/level/ServerPlayer.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java -@@ -1161,7 +1161,7 @@ public class ServerPlayer extends Player { +@@ -1163,7 +1163,7 @@ public class ServerPlayer extends Player { this.isChangingDimension = true; // CraftBukkit - Set teleport invulnerability only if player changing worlds this.connection.send(new ClientboundRespawnPacket(worldserver.dimensionTypeId(), worldserver.dimension(), BiomeManager.obfuscateSeed(worldserver.getSeed()), this.gameMode.getGameModeForPlayer(), this.gameMode.getPreviousGameModeForPlayer(), worldserver.isDebug(), worldserver.isFlat(), (byte) 3, this.getLastDeathLocation())); @@ -89,10 +89,10 @@ index 5be828ad63184ee01519ef937e98f621a4e83dee..d560e5dee586bb3b501e9a78083b9aa9 playerlist.sendPlayerPermissionLevel(this); diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index bd021ff4a5e3bd5dde2829718c0f57d9fc9aa93d..807cbeb8cc6700e5f740b554c7f1893ec9110714 100644 +index e9902fa67719c4b40fb9524bf77798357e9a97d9..b4f17b9c195081b54d79494d9afaf0da21f292c0 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -3383,7 +3383,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -3390,7 +3390,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic public void handleChangeDifficulty(ServerboundChangeDifficultyPacket packet) { PacketUtils.ensureRunningOnSameThread(packet, this, this.player.getLevel()); if (this.player.hasPermissions(2) || this.isSingleplayerOwner()) { @@ -102,10 +102,10 @@ index bd021ff4a5e3bd5dde2829718c0f57d9fc9aa93d..807cbeb8cc6700e5f740b554c7f1893e } diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index e2b5eb02f9d91128c702eb85ad85e47bd6080e02..a461cc5c20287d9dfd2b32323f41cff97b205d1d 100644 +index 86acd4c9acc33197fb9d35381677152521168cf1..d26c17cda10dd0a816175be9ab3a1fff30fcd9bd 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -941,8 +941,8 @@ public final class CraftServer implements Server { +@@ -942,8 +942,8 @@ public final class CraftServer implements Server { org.spigotmc.SpigotConfig.init((File) console.options.valueOf("spigot-settings")); // Spigot this.console.paperConfigurations.reloadConfigs(this.console); for (ServerLevel world : this.console.getAllLevels()) { @@ -117,10 +117,10 @@ index e2b5eb02f9d91128c702eb85ad85e47bd6080e02..a461cc5c20287d9dfd2b32323f41cff9 for (SpawnCategory spawnCategory : SpawnCategory.values()) { if (CraftSpawnCategory.isValidForLimits(spawnCategory)) { diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -index a17ae89a82958bdc3bfa0553440e2887585693c1..0084dceef60b23fa79fadc0a3c1a06c1a3b048cd 100644 +index dbc211b8d23d766ecff7aab1884c72dc7e568dfb..6c6408710bcb67295e5058631e4d56d7e7386ab8 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -@@ -1157,7 +1157,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -1143,7 +1143,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { @Override public void setDifficulty(Difficulty difficulty) { diff --git a/patches/server/0431-Add-Plugin-Tickets-to-API-Chunk-Methods.patch b/patches/server/0431-Add-Plugin-Tickets-to-API-Chunk-Methods.patch index 33a24749bf..34fc583afd 100644 --- a/patches/server/0431-Add-Plugin-Tickets-to-API-Chunk-Methods.patch +++ b/patches/server/0431-Add-Plugin-Tickets-to-API-Chunk-Methods.patch @@ -22,10 +22,10 @@ wants it to collect even faster, they can restore that setting back to 1 instead Not adding it to .getType() though to keep behavior consistent with vanilla for performance reasons. diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 777f114e9cb0cfa3633b9a89116be1c73d552065..4056ba7e9860c8eb8ccd265d9c5ca575c1cabd24 100644 +index d26c17cda10dd0a816175be9ab3a1fff30fcd9bd..64e59d5c545e6bc4e000e2ca779df427a67e5aae 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -369,7 +369,7 @@ public final class CraftServer implements Server { +@@ -370,7 +370,7 @@ public final class CraftServer implements Server { this.overrideSpawnLimits(); console.autosavePeriod = this.configuration.getInt("ticks-per.autosave"); this.warningState = WarningState.value(this.configuration.getString("settings.deprecated-verbose")); @@ -34,7 +34,7 @@ index 777f114e9cb0cfa3633b9a89116be1c73d552065..4056ba7e9860c8eb8ccd265d9c5ca575 this.minimumAPI = this.configuration.getString("settings.minimum-api"); this.loadIcon(); -@@ -921,7 +921,7 @@ public final class CraftServer implements Server { +@@ -922,7 +922,7 @@ public final class CraftServer implements Server { this.console.setMotd(config.motd); this.overrideSpawnLimits(); this.warningState = WarningState.value(this.configuration.getString("settings.deprecated-verbose")); @@ -44,10 +44,10 @@ index 777f114e9cb0cfa3633b9a89116be1c73d552065..4056ba7e9860c8eb8ccd265d9c5ca575 this.printSaveWarning = false; console.autosavePeriod = this.configuration.getInt("ticks-per.autosave"); diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -index 0084dceef60b23fa79fadc0a3c1a06c1a3b048cd..3cf399c2e698af057e8e3c7036d8967318e0c415 100644 +index 6c6408710bcb67295e5058631e4d56d7e7386ab8..51b88f432134e162dd63580ef2c086ad853d5ee9 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -@@ -282,7 +282,13 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -278,7 +278,13 @@ public class CraftWorld extends CraftRegionAccessor implements World { @Override public Chunk getChunkAt(int x, int z) { @@ -62,7 +62,7 @@ index 0084dceef60b23fa79fadc0a3c1a06c1a3b048cd..3cf399c2e698af057e8e3c7036d89673 return new CraftChunk(chunk); } -@@ -296,6 +302,12 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -292,6 +298,12 @@ public class CraftWorld extends CraftRegionAccessor implements World { return new CraftChunk(this.getHandle(), x, z); } @@ -75,7 +75,7 @@ index 0084dceef60b23fa79fadc0a3c1a06c1a3b048cd..3cf399c2e698af057e8e3c7036d89673 @Override public Chunk getChunkAt(Block block) { Preconditions.checkArgument(block != null, "null block"); -@@ -361,7 +373,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -357,7 +369,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { public boolean unloadChunkRequest(int x, int z) { org.spigotmc.AsyncCatcher.catchOp("chunk unload"); // Spigot if (this.isChunkLoaded(x, z)) { @@ -84,7 +84,7 @@ index 0084dceef60b23fa79fadc0a3c1a06c1a3b048cd..3cf399c2e698af057e8e3c7036d89673 } return true; -@@ -447,9 +459,12 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -443,9 +455,12 @@ public class CraftWorld extends CraftRegionAccessor implements World { org.spigotmc.AsyncCatcher.catchOp("chunk load"); // Spigot // Paper start - Optimize this method ChunkPos chunkPos = new ChunkPos(x, z); @@ -98,7 +98,7 @@ index 0084dceef60b23fa79fadc0a3c1a06c1a3b048cd..3cf399c2e698af057e8e3c7036d89673 if (immediate == null) { immediate = world.getChunkSource().chunkMap.getUnloadingChunk(x, z); } -@@ -457,7 +472,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -453,7 +468,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { if (!(immediate instanceof ImposterProtoChunk) && !(immediate instanceof net.minecraft.world.level.chunk.LevelChunk)) { return false; // not full status } @@ -107,7 +107,7 @@ index 0084dceef60b23fa79fadc0a3c1a06c1a3b048cd..3cf399c2e698af057e8e3c7036d89673 world.getChunk(x, z); // make sure we're at ticket level 32 or lower return true; } -@@ -483,7 +498,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -479,7 +494,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { // we do this so we do not re-read the chunk data on disk } @@ -116,7 +116,7 @@ index 0084dceef60b23fa79fadc0a3c1a06c1a3b048cd..3cf399c2e698af057e8e3c7036d89673 world.getChunkSource().getChunk(x, z, ChunkStatus.FULL, true); return true; // Paper end -@@ -2175,6 +2190,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -2161,6 +2176,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { io.papermc.paper.chunk.system.ChunkSystem.scheduleChunkLoad(this.getHandle(), x, z, gen, ChunkStatus.FULL, true, priority, (c) -> { net.minecraft.server.MinecraftServer.getServer().scheduleOnMain(() -> { net.minecraft.world.level.chunk.LevelChunk chunk = (net.minecraft.world.level.chunk.LevelChunk)c; diff --git a/patches/server/0432-incremental-chunk-and-player-saving.patch b/patches/server/0432-incremental-chunk-and-player-saving.patch index a35325e8ef..0218577c02 100644 --- a/patches/server/0432-incremental-chunk-and-player-saving.patch +++ b/patches/server/0432-incremental-chunk-and-player-saving.patch @@ -115,10 +115,10 @@ index 51e8070864ffc4a35377021a7ded9813a40c1a11..06d20e9fde26540d1575975345f3d694 // Paper start - rewrite chunk system - add close param this.save(progressListener, flush, savingDisabled, false); diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java -index d560e5dee586bb3b501e9a78083b9aa961c48fc5..ce6ae0ec4d104929f2c3fe03b0f44eafbfec1d9a 100644 +index 2c052d0a8c6d58ad8eae41c22c753327342e90f1..5b6ecebcb4585877a2761eb17f4810042320e681 100644 --- a/src/main/java/net/minecraft/server/level/ServerPlayer.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java -@@ -187,6 +187,7 @@ import org.bukkit.inventory.MainHand; +@@ -189,6 +189,7 @@ import org.bukkit.inventory.MainHand; public class ServerPlayer extends Player { private static final Logger LOGGER = LogUtils.getLogger(); @@ -127,10 +127,10 @@ index d560e5dee586bb3b501e9a78083b9aa961c48fc5..ce6ae0ec4d104929f2c3fe03b0f44eaf 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 a0832d8e8b9e91073c15e5a87953d6ccee544ae0..6837054dc812b249db0dc975dc8f5506437260f4 100644 +index 0e2a84148e721a8f799f0746e379c16a5f7f0dd3..44ead3a9831d913f7337a447b73a94e06fb0f06a 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -526,6 +526,7 @@ public abstract class PlayerList { +@@ -528,6 +528,7 @@ public abstract class PlayerList { protected void save(ServerPlayer player) { if (!player.getBukkitEntity().isPersistent()) return; // CraftBukkit @@ -138,7 +138,7 @@ index a0832d8e8b9e91073c15e5a87953d6ccee544ae0..6837054dc812b249db0dc975dc8f5506 this.playerIo.save(player); ServerStatsCounter serverstatisticmanager = (ServerStatsCounter) player.getStats(); // CraftBukkit -@@ -1116,10 +1117,22 @@ public abstract class PlayerList { +@@ -1118,10 +1119,22 @@ public abstract class PlayerList { } public void saveAll() { diff --git a/patches/server/0443-Spawn-player-in-correct-world-on-login.patch b/patches/server/0443-Spawn-player-in-correct-world-on-login.patch index 95b54f8c30..08b6e1b41f 100644 --- a/patches/server/0443-Spawn-player-in-correct-world-on-login.patch +++ b/patches/server/0443-Spawn-player-in-correct-world-on-login.patch @@ -5,10 +5,10 @@ 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 6837054dc812b249db0dc975dc8f5506437260f4..00551e6718d4e672f3d6758d1d7aabacc5b6239c 100644 +index 44ead3a9831d913f7337a447b73a94e06fb0f06a..ff5f15fef219b4ce5907b7eb8a489fc5c09d55ba 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -203,7 +203,18 @@ public abstract class PlayerList { +@@ -205,7 +205,18 @@ public abstract class PlayerList { } // CraftBukkit end diff --git a/patches/server/0444-Add-PrepareResultEvent.patch b/patches/server/0444-Add-PrepareResultEvent.patch index 37ab622773..19a4825ee0 100644 --- a/patches/server/0444-Add-PrepareResultEvent.patch +++ b/patches/server/0444-Add-PrepareResultEvent.patch @@ -94,10 +94,10 @@ index 665b01ff3579c8fd87074edfc6da6b7ef07693b2..24c31e96be460bcb5062a1fcf7f86c1a private void setupRecipeList(Container input, ItemStack stack) { diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java -index 6045ebda7250545c255c1e1c1eb614deff3dfc96..7d409becab302fdd5c3f3eaf7288cbda7de4722d 100644 +index 0ad0d6e15f57c16fb71f988ac7d0d2e243493801..a1948b59e5c6bcc4c85d175d3267e9dd091768a6 100644 --- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java +++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java -@@ -1615,26 +1615,53 @@ public class CraftEventFactory { +@@ -1624,26 +1624,53 @@ public class CraftEventFactory { return event; } diff --git a/patches/server/0449-Fix-SPIGOT-5989.patch b/patches/server/0449-Fix-SPIGOT-5989.patch index e99dded438..268acb81a9 100644 --- a/patches/server/0449-Fix-SPIGOT-5989.patch +++ b/patches/server/0449-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 00551e6718d4e672f3d6758d1d7aabacc5b6239c..19f525543e95a1b8de2ad3da45724969705e9c15 100644 +index ff5f15fef219b4ce5907b7eb8a489fc5c09d55ba..14d00939b9a8488eba040bf435e6837ecb424d65 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -785,6 +785,7 @@ public abstract class PlayerList { +@@ -787,6 +787,7 @@ public abstract class PlayerList { // Paper start boolean isBedSpawn = false; boolean isRespawn = false; @@ -21,7 +21,7 @@ index 00551e6718d4e672f3d6758d1d7aabacc5b6239c..19f525543e95a1b8de2ad3da45724969 // Paper end // CraftBukkit start - fire PlayerRespawnEvent -@@ -795,7 +796,7 @@ public abstract class PlayerList { +@@ -797,7 +798,7 @@ public abstract class PlayerList { Optional optional; if (blockposition != null) { @@ -30,7 +30,7 @@ index 00551e6718d4e672f3d6758d1d7aabacc5b6239c..19f525543e95a1b8de2ad3da45724969 } else { optional = Optional.empty(); } -@@ -839,7 +840,12 @@ public abstract class PlayerList { +@@ -841,7 +842,12 @@ public abstract class PlayerList { } // Spigot End @@ -44,7 +44,7 @@ index 00551e6718d4e672f3d6758d1d7aabacc5b6239c..19f525543e95a1b8de2ad3da45724969 if (!flag) entityplayer.reset(); // SPIGOT-4785 isRespawn = true; // Paper } else { -@@ -879,8 +885,14 @@ public abstract class PlayerList { +@@ -881,8 +887,14 @@ public abstract class PlayerList { } // entityplayer1.initInventoryMenu(); entityplayer1.setHealth(entityplayer1.getHealth()); diff --git a/patches/server/0456-Brand-support.patch b/patches/server/0456-Brand-support.patch index 3173c7bf9b..c10d35ece4 100644 --- a/patches/server/0456-Brand-support.patch +++ b/patches/server/0456-Brand-support.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Brand support diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 807cbeb8cc6700e5f740b554c7f1893ec9110714..f6733db4d81c8dda5650f067b56354ae4ed32626 100644 +index b4f17b9c195081b54d79494d9afaf0da21f292c0..139daac1cc7359be4eebf73b2a578e07c183c750 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -301,6 +301,8 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -302,6 +302,8 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic private static final long KEEPALIVE_LIMIT = Long.getLong("paper.playerconnection.keepalive", 30) * 1000; // Paper - provide property to set keepalive limit private static final int MAX_SIGN_LINE_LENGTH = Integer.getInteger("Paper.maxSignLength", 80); // Paper @@ -17,7 +17,7 @@ index 807cbeb8cc6700e5f740b554c7f1893ec9110714..f6733db4d81c8dda5650f067b56354ae public ServerGamePacketListenerImpl(MinecraftServer server, Connection connection, ServerPlayer player) { this.lastChatTimeStamp = new AtomicReference(Instant.EPOCH); this.lastSeenMessages = new LastSeenMessagesValidator(20); -@@ -3338,6 +3340,8 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -3345,6 +3347,8 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic private static final ResourceLocation CUSTOM_REGISTER = new ResourceLocation("register"); private static final ResourceLocation CUSTOM_UNREGISTER = new ResourceLocation("unregister"); @@ -26,7 +26,7 @@ index 807cbeb8cc6700e5f740b554c7f1893ec9110714..f6733db4d81c8dda5650f067b56354ae @Override public void handleCustomPayload(ServerboundCustomPayloadPacket packet) { PacketUtils.ensureRunningOnSameThread(packet, this, this.player.getLevel()); -@@ -3365,6 +3369,15 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -3372,6 +3376,15 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic try { byte[] data = new byte[packet.data.readableBytes()]; packet.data.readBytes(data); @@ -42,7 +42,7 @@ index 807cbeb8cc6700e5f740b554c7f1893ec9110714..f6733db4d81c8dda5650f067b56354ae this.cserver.getMessenger().dispatchIncomingMessage(this.player.getBukkitEntity(), packet.identifier.toString(), data); } catch (Exception ex) { ServerGamePacketListenerImpl.LOGGER.error("Couldn\'t dispatch custom payload", ex); -@@ -3374,6 +3387,12 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -3381,6 +3394,12 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic } @@ -56,10 +56,10 @@ index 807cbeb8cc6700e5f740b554c7f1893ec9110714..f6733db4d81c8dda5650f067b56354ae return (!this.player.joining && !this.connection.isConnected()) || this.processedDisconnect; // Paper } diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -index 16cc7cfd39158cfb4045375d8be664b91d4a57d4..1c29a51b66ae19ec208cc55fe94facff5f961c72 100644 +index a77858a6253a3195879aaa3bccccee6c0af5b00a..6cac6959133d90f5755ed5272f7edc261a94cb69 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -@@ -2983,6 +2983,13 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -2991,6 +2991,13 @@ public class CraftPlayer extends CraftHumanEntity implements Player { // Paper end }; diff --git a/patches/server/0457-Add-setMaxPlayers-API.patch b/patches/server/0457-Add-setMaxPlayers-API.patch index 18e0dabfbc..44cd861b9b 100644 --- a/patches/server/0457-Add-setMaxPlayers-API.patch +++ b/patches/server/0457-Add-setMaxPlayers-API.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Add #setMaxPlayers API diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java -index 19f525543e95a1b8de2ad3da45724969705e9c15..162b09cda517afe3b87321a4fe871c183db37621 100644 +index 14d00939b9a8488eba040bf435e6837ecb424d65..9b75cf08096689522b670ad48e73126ad4cfc9b5 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -153,7 +153,7 @@ public abstract class PlayerList { +@@ -155,7 +155,7 @@ public abstract class PlayerList { private boolean doWhiteList; private final LayeredRegistryAccess registries; private final RegistryAccess.Frozen synchronizedRegistries; @@ -18,10 +18,10 @@ index 19f525543e95a1b8de2ad3da45724969705e9c15..162b09cda517afe3b87321a4fe871c18 private int simulationDistance; private boolean allowCheatsForAllPlayers; diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index cc728b3ec69dcd92d5c4ed97805bcbd5bcd2d3e3..af0e06a47173688b950ed4d376b23dc71854fd7b 100644 +index 64e59d5c545e6bc4e000e2ca779df427a67e5aae..5891dc6a41a0043ff85d343b7da5024c96f9a77e 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -664,6 +664,13 @@ public final class CraftServer implements Server { +@@ -665,6 +665,13 @@ public final class CraftServer implements Server { return this.playerList.getMaxPlayers(); } diff --git a/patches/server/0460-Fix-SpawnChangeEvent-not-firing-for-all-use-cases.patch b/patches/server/0460-Fix-SpawnChangeEvent-not-firing-for-all-use-cases.patch index b854302b1d..aa231118b5 100644 --- a/patches/server/0460-Fix-SpawnChangeEvent-not-firing-for-all-use-cases.patch +++ b/patches/server/0460-Fix-SpawnChangeEvent-not-firing-for-all-use-cases.patch @@ -21,10 +21,10 @@ index 06d20e9fde26540d1575975345f3d69405f767d0..959a8a170363227bb8ca833d8399f0c4 // if this keepSpawnInMemory is false a plugin has already removed our tickets, do not re-add this.removeTicketsForSpawn(this.paperConfig().spawn.keepSpawnLoadedRange * 16, prevSpawn); diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -index 3cf399c2e698af057e8e3c7036d8967318e0c415..47d4a61934f07836d9275841fa566bf1d6851381 100644 +index 51b88f432134e162dd63580ef2c086ad853d5ee9..2f4bdf2128037b06a3d5e7b340f5f888c8777ca8 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -@@ -262,12 +262,14 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -258,12 +258,14 @@ public class CraftWorld extends CraftRegionAccessor implements World { @Override public boolean setSpawnLocation(int x, int y, int z, float angle) { try { diff --git a/patches/server/0461-Add-moon-phase-API.patch b/patches/server/0461-Add-moon-phase-API.patch index c93e44f82b..c51ac1afea 100644 --- a/patches/server/0461-Add-moon-phase-API.patch +++ b/patches/server/0461-Add-moon-phase-API.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Add moon phase API diff --git a/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java b/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java -index 2c0773fec42c7c6223e2c300086058939ec32a52..9db48bd6dcf0d24132123b86670341c1d8113840 100644 +index d9be32a5141d7b322f31b61c685ca712cdb45182..3ffea505826bbe4151268ed9cffa5f2ddea27b62 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java -@@ -963,4 +963,11 @@ public abstract class CraftRegionAccessor implements RegionAccessor { +@@ -984,4 +984,11 @@ public abstract class CraftRegionAccessor implements RegionAccessor { throw new IllegalArgumentException("Cannot spawn an entity for " + clazz.getName()); } diff --git a/patches/server/0463-Add-BellRingEvent.patch b/patches/server/0463-Add-BellRingEvent.patch index b03673d2e8..3c3ab5492d 100644 --- a/patches/server/0463-Add-BellRingEvent.patch +++ b/patches/server/0463-Add-BellRingEvent.patch @@ -7,10 +7,10 @@ Add a new event, BellRingEvent, to trigger whenever a player rings a village bell. Passes along the bell block and the player who rang it. diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java -index 7d409becab302fdd5c3f3eaf7288cbda7de4722d..d590d0d2a2a66fdf91aca6238268aa4be91dcf9a 100644 +index a1948b59e5c6bcc4c85d175d3267e9dd091768a6..79c542421199a5d9984f104204b275e050581db5 100644 --- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java +++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java -@@ -330,10 +330,11 @@ public class CraftEventFactory { +@@ -332,10 +332,11 @@ public class CraftEventFactory { return tradeSelectEvent; } diff --git a/patches/server/0468-PortalCreateEvent-needs-to-know-its-entity.patch b/patches/server/0468-PortalCreateEvent-needs-to-know-its-entity.patch index 075a43d9c8..dda96c41e6 100644 --- a/patches/server/0468-PortalCreateEvent-needs-to-know-its-entity.patch +++ b/patches/server/0468-PortalCreateEvent-needs-to-know-its-entity.patch @@ -5,7 +5,7 @@ Subject: [PATCH] PortalCreateEvent needs to know its entity diff --git a/src/main/java/net/minecraft/world/item/ItemStack.java b/src/main/java/net/minecraft/world/item/ItemStack.java -index 3cb83cfeb2709384ef4f7dd74694d47d55698c1f..36c560ea3b33ef854f2190d07209b7f36c6d7e6b 100644 +index 56101f87ef258159f77bc70625162e0473697eb9..4f9f5cc99e071fa562743ce6dc2bb2cc4ffc6340 100644 --- a/src/main/java/net/minecraft/world/item/ItemStack.java +++ b/src/main/java/net/minecraft/world/item/ItemStack.java @@ -443,7 +443,7 @@ public final class ItemStack { @@ -52,7 +52,7 @@ index 2bc31c28d0d5469476699b69efa6e07325f2a852..4066dd6a638cf2186c628905915f6353 } diff --git a/src/main/java/net/minecraft/world/level/block/FireBlock.java b/src/main/java/net/minecraft/world/level/block/FireBlock.java -index 9576f581bb61e6c71de427c52dcc3e56dc3ed81e..6ed2c13c8d22a936ae130cf8cf103451033a2cb7 100644 +index 7afaeab3daca40ea2db7961503090fad119ceb8a..69ec4de4d065481496f5363c8985d2f39cd0191d 100644 --- a/src/main/java/net/minecraft/world/level/block/FireBlock.java +++ b/src/main/java/net/minecraft/world/level/block/FireBlock.java @@ -13,6 +13,7 @@ import net.minecraft.server.level.ServerLevel; @@ -63,7 +63,7 @@ index 9576f581bb61e6c71de427c52dcc3e56dc3ed81e..6ed2c13c8d22a936ae130cf8cf103451 import net.minecraft.world.level.BlockGetter; import net.minecraft.world.level.GameRules; import net.minecraft.world.level.Level; -@@ -357,9 +358,11 @@ public class FireBlock extends BaseFireBlock { +@@ -361,9 +362,11 @@ public class FireBlock extends BaseFireBlock { } @Override diff --git a/patches/server/0471-Add-methods-to-get-translation-keys.patch b/patches/server/0471-Add-methods-to-get-translation-keys.patch index 7816dbd087..0e5dc0676b 100644 --- a/patches/server/0471-Add-methods-to-get-translation-keys.patch +++ b/patches/server/0471-Add-methods-to-get-translation-keys.patch @@ -10,10 +10,10 @@ public org.bukkit.craftbukkit.inventory.CraftMetaFirework getNBT(Lorg/bukkit/Fir Co-authored-by: MeFisto94 diff --git a/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java b/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java -index ac543a4c6bc21435de3c6721af37fd5f554e403e..1f780a326f4982d4be1855516fb1461b4d90bcc6 100644 +index 707ee755cb9ebf2a2b61a6079efbc54368beeed0..5ce19b2dcf9dd2844fe79991fc0260e6141f3394 100644 --- a/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java +++ b/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java -@@ -694,5 +694,10 @@ public class CraftBlock implements Block { +@@ -693,5 +693,10 @@ public class CraftBlock implements Block { public org.bukkit.SoundGroup getBlockSoundGroup() { return org.bukkit.craftbukkit.CraftSoundGroup.getSoundGroup(this.getNMS().getSoundType()); } diff --git a/patches/server/0473-Cache-block-data-strings.patch b/patches/server/0473-Cache-block-data-strings.patch index b63eb77502..f605908561 100644 --- a/patches/server/0473-Cache-block-data-strings.patch +++ b/patches/server/0473-Cache-block-data-strings.patch @@ -17,10 +17,10 @@ index 4fec26c84cb435756fe4b2dcdfc90716f342f9f1..e2ed1ab01ac95d18aa2d3553ccbc5aab if (this.isSameThread()) { diff --git a/src/main/java/org/bukkit/craftbukkit/block/data/CraftBlockData.java b/src/main/java/org/bukkit/craftbukkit/block/data/CraftBlockData.java -index ccd511f189a9ec57564b2372d7f662da15ef3bba..9b2b90453935b73a814255101f6d1bd3ff0a4362 100644 +index d4a204cdd035d1af2fc5a05036a3374ac89974c5..3252ef23ddc5dc839e8062f4c3ed565c990c7418 100644 --- a/src/main/java/org/bukkit/craftbukkit/block/data/CraftBlockData.java +++ b/src/main/java/org/bukkit/craftbukkit/block/data/CraftBlockData.java -@@ -520,9 +520,39 @@ public class CraftBlockData implements BlockData { +@@ -521,9 +521,39 @@ public class CraftBlockData implements BlockData { Preconditions.checkState(CraftBlockData.MAP.put(nms, bukkit) == null, "Duplicate mapping %s->%s", nms, bukkit); } diff --git a/patches/server/0474-Fix-Entity-Teleportation-and-cancel-velocity-if-tele.patch b/patches/server/0474-Fix-Entity-Teleportation-and-cancel-velocity-if-tele.patch index 2839d758fe..dfccba2247 100644 --- a/patches/server/0474-Fix-Entity-Teleportation-and-cancel-velocity-if-tele.patch +++ b/patches/server/0474-Fix-Entity-Teleportation-and-cancel-velocity-if-tele.patch @@ -9,10 +9,10 @@ as this is how Vanilla teleports entities. Cancel any pending motion when teleported. diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index f6733db4d81c8dda5650f067b56354ae4ed32626..791446f9b22d60bd7dbb632ca92442848d1c28e9 100644 +index 4d2adbf45387b63f60b4a8170906752555a19178..ef3771b178d8d966edb83773186dcfac0fda8e3e 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -751,7 +751,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -752,7 +752,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic return; } @@ -21,7 +21,7 @@ index f6733db4d81c8dda5650f067b56354ae4ed32626..791446f9b22d60bd7dbb632ca9244284 this.lastGoodX = this.awaitingPositionFromClient.x; this.lastGoodY = this.awaitingPositionFromClient.y; this.lastGoodZ = this.awaitingPositionFromClient.z; -@@ -1656,7 +1656,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -1657,7 +1657,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic // CraftBukkit end this.awaitingTeleportTime = this.tickCount; @@ -31,10 +31,10 @@ index f6733db4d81c8dda5650f067b56354ae4ed32626..791446f9b22d60bd7dbb632ca9244284 } diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index b69615eafcee963862cb3671888dcf8ec5114fe5..a3d547d9fed7e2c9f344aa467f287ba46c4cb338 100644 +index 24ba8dc2a5fc72ade003fa14d337f2c64a0e654e..f8f0be4ebb097c26461ea0fcbce7914ce84e87ed 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -158,6 +158,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -159,6 +159,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { // CraftBukkit start private static final int CURRENT_LEVEL = 2; @@ -42,7 +42,7 @@ index b69615eafcee963862cb3671888dcf8ec5114fe5..a3d547d9fed7e2c9f344aa467f287ba4 static boolean isLevelAtLeast(CompoundTag tag, int level) { return tag.contains("Bukkit.updateLevel") && tag.getInt("Bukkit.updateLevel") >= level; } -@@ -1736,6 +1737,13 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -1737,6 +1738,13 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { } public void moveTo(double x, double y, double z, float yaw, float pitch) { @@ -69,7 +69,7 @@ index 54a20433483d5b67a6668fcdbddc1654a246fee2..9bf1a37ea8436f3314b28914ae8b1516 if (entity instanceof Mob) { Mob entityinsentient = (Mob) entity; diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java -index b1697227b34858da01603abbf7a7476494ce59be..d1ff5c5d1286692504c39727d94bee341f7586fd 100644 +index 7dfa1884a7b4cdbfc83e62caf96acf8ca65a2a73..841e027722f277649ed1b97464f8fca1e290a809 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java @@ -574,7 +574,7 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity { diff --git a/patches/server/0475-Add-additional-open-container-api-to-HumanEntity.patch b/patches/server/0475-Add-additional-open-container-api-to-HumanEntity.patch index d4149ca464..013bfca190 100644 --- a/patches/server/0475-Add-additional-open-container-api-to-HumanEntity.patch +++ b/patches/server/0475-Add-additional-open-container-api-to-HumanEntity.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Add additional open container api to HumanEntity diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java -index 728fc30046de534748e2379e8cb371cc2e51f9d3..0117277db8402a1673c317673811c17d02edc4c9 100644 +index 3f6e9214358c938b39106dd6c3eb652c8549c60b..581d99e0dbf4b1a59389645f01f33aed7a340686 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java -@@ -462,6 +462,70 @@ public class CraftHumanEntity extends CraftLivingEntity implements HumanEntity { +@@ -463,6 +463,70 @@ public class CraftHumanEntity extends CraftLivingEntity implements HumanEntity { return this.getHandle().containerMenu.getBukkitView(); } diff --git a/patches/server/0478-Expose-the-Entity-Counter-to-allow-plugins-to-use-va.patch b/patches/server/0478-Expose-the-Entity-Counter-to-allow-plugins-to-use-va.patch index 78c12c5ee2..24f6d2beed 100644 --- a/patches/server/0478-Expose-the-Entity-Counter-to-allow-plugins-to-use-va.patch +++ b/patches/server/0478-Expose-the-Entity-Counter-to-allow-plugins-to-use-va.patch @@ -6,10 +6,10 @@ Subject: [PATCH] Expose the Entity Counter to allow plugins to use valid and diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index a3d547d9fed7e2c9f344aa467f287ba46c4cb338..af258b981a69b0af2787013837c044c798e5176f 100644 +index f8f0be4ebb097c26461ea0fcbce7914ce84e87ed..7fe47f6158ca78f522685762e1e990ff6e588b87 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -4307,4 +4307,10 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -4308,4 +4308,10 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { void accept(Entity entity, double x, double y, double z); } diff --git a/patches/server/0480-Entity-isTicking.patch b/patches/server/0480-Entity-isTicking.patch index 362e75b26d..df7f36c0fc 100644 --- a/patches/server/0480-Entity-isTicking.patch +++ b/patches/server/0480-Entity-isTicking.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Entity#isTicking diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index af258b981a69b0af2787013837c044c798e5176f..5f5f853a67518ddbfbc94b9a92b00cda1219b21a 100644 +index 7fe47f6158ca78f522685762e1e990ff6e588b87..3d9447b976fbaedb55b526efba7e5d9e7110ade7 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -4312,5 +4312,9 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -4313,5 +4313,9 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { public static int nextEntityId() { return ENTITY_COUNTER.incrementAndGet(); } @@ -19,7 +19,7 @@ index af258b981a69b0af2787013837c044c798e5176f..5f5f853a67518ddbfbc94b9a92b00cda // Paper end } diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java -index d1ff5c5d1286692504c39727d94bee341f7586fd..e67fb2f213fc174dba36f283ca4441fcf4596140 100644 +index 841e027722f277649ed1b97464f8fca1e290a809..7d27284e16d31b06f976ab7b9e04b9da7a6a6813 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java @@ -1343,5 +1343,10 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity { diff --git a/patches/server/0484-Fix-for-large-move-vectors-crashing-server.patch b/patches/server/0484-Fix-for-large-move-vectors-crashing-server.patch index aac2433b76..943e1de879 100644 --- a/patches/server/0484-Fix-for-large-move-vectors-crashing-server.patch +++ b/patches/server/0484-Fix-for-large-move-vectors-crashing-server.patch @@ -6,10 +6,10 @@ Subject: [PATCH] Fix for large move vectors crashing server Check movement distance also based on current position. diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 791446f9b22d60bd7dbb632ca92442848d1c28e9..0a06cdcccbdf503814386c27a8fb614da671c441 100644 +index ef3771b178d8d966edb83773186dcfac0fda8e3e..910f40b87eb574e77e991acac431a0f61f5b6bf3 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -566,9 +566,9 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -567,9 +567,9 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic if (entity != this.player && entity.getControllingPassenger() == this.player && entity == this.lastVehicle) { ServerLevel worldserver = this.player.getLevel(); @@ -22,7 +22,7 @@ index 791446f9b22d60bd7dbb632ca92442848d1c28e9..0a06cdcccbdf503814386c27a8fb614d double d3 = ServerGamePacketListenerImpl.clampHorizontal(packet.getX()); final double toX = d3; // Paper - OBFHELPER double d4 = ServerGamePacketListenerImpl.clampVertical(packet.getY()); final double toY = d4; // Paper - OBFHELPER double d5 = ServerGamePacketListenerImpl.clampHorizontal(packet.getZ()); final double toZ = d5; // Paper - OBFHELPER -@@ -578,8 +578,19 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -579,8 +579,19 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic double d7 = d4 - this.vehicleFirstGoodY; double d8 = d5 - this.vehicleFirstGoodZ; double d9 = entity.getDeltaMovement().lengthSqr(); @@ -44,7 +44,7 @@ index 791446f9b22d60bd7dbb632ca92442848d1c28e9..0a06cdcccbdf503814386c27a8fb614d // CraftBukkit start - handle custom speeds and skipped ticks this.allowedPlayerTicks += (System.currentTimeMillis() / 50) - this.lastTick; -@@ -625,9 +636,9 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -626,9 +637,9 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic boolean flag = worldserver.noCollision(entity, entity.getBoundingBox().deflate(0.0625D)); @@ -57,7 +57,7 @@ index 791446f9b22d60bd7dbb632ca92442848d1c28e9..0a06cdcccbdf503814386c27a8fb614d boolean flag1 = entity.verticalCollisionBelow; entity.move(MoverType.PLAYER, new Vec3(d6, d7, d8)); -@@ -1347,7 +1358,18 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -1348,7 +1359,18 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic double d8 = d1 - this.firstGoodY; double d9 = d2 - this.firstGoodZ; double d10 = this.player.getDeltaMovement().lengthSqr(); @@ -77,7 +77,7 @@ index 791446f9b22d60bd7dbb632ca92442848d1c28e9..0a06cdcccbdf503814386c27a8fb614d if (this.player.isSleeping()) { if (d11 > 1.0D) { -@@ -1399,9 +1421,9 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -1400,9 +1422,9 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic AABB axisalignedbb = this.player.getBoundingBox(); diff --git a/patches/server/0485-Optimise-getType-calls.patch b/patches/server/0485-Optimise-getType-calls.patch index 68429d2864..305a1e743e 100644 --- a/patches/server/0485-Optimise-getType-calls.patch +++ b/patches/server/0485-Optimise-getType-calls.patch @@ -41,10 +41,10 @@ index eebac2ea211f58c385b2ceb36ab911ac5e115296..d1aaca5de055fd5e3bf2c6d39ef397bb @Override diff --git a/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java b/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java -index 1f780a326f4982d4be1855516fb1461b4d90bcc6..998cb47c4d3d1c67467469e661f80d231d17c04a 100644 +index 5ce19b2dcf9dd2844fe79991fc0260e6141f3394..4167b665abdae0db1425f50ccf175bc35699abca 100644 --- a/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java +++ b/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java -@@ -226,7 +226,7 @@ public class CraftBlock implements Block { +@@ -225,7 +225,7 @@ public class CraftBlock implements Block { @Override public Material getType() { @@ -54,10 +54,10 @@ index 1f780a326f4982d4be1855516fb1461b4d90bcc6..998cb47c4d3d1c67467469e661f80d23 @Override diff --git a/src/main/java/org/bukkit/craftbukkit/block/CraftBlockState.java b/src/main/java/org/bukkit/craftbukkit/block/CraftBlockState.java -index 0a755f38fae9dc84440f43113920c5b4c6d8218b..7b9e943b391c061782fccd2b8d705ceec8db50fe 100644 +index 843a166e43f05fe987e62329593b23656c6a2abb..9068557ac50cfb26e7e3ec4ac64bac583baa582e 100644 --- a/src/main/java/org/bukkit/craftbukkit/block/CraftBlockState.java +++ b/src/main/java/org/bukkit/craftbukkit/block/CraftBlockState.java -@@ -166,7 +166,7 @@ public class CraftBlockState implements BlockState { +@@ -167,7 +167,7 @@ public class CraftBlockState implements BlockState { @Override public Material getType() { @@ -67,10 +67,10 @@ index 0a755f38fae9dc84440f43113920c5b4c6d8218b..7b9e943b391c061782fccd2b8d705cee public void setFlag(int flag) { diff --git a/src/main/java/org/bukkit/craftbukkit/block/data/CraftBlockData.java b/src/main/java/org/bukkit/craftbukkit/block/data/CraftBlockData.java -index 9b2b90453935b73a814255101f6d1bd3ff0a4362..a585deb47ceb721489e0da4a09a94922fef86a3f 100644 +index 3252ef23ddc5dc839e8062f4c3ed565c990c7418..9d09b3064fc0474170e6d584dd3ccb9899cfbd42 100644 --- a/src/main/java/org/bukkit/craftbukkit/block/data/CraftBlockData.java +++ b/src/main/java/org/bukkit/craftbukkit/block/data/CraftBlockData.java -@@ -56,7 +56,7 @@ public class CraftBlockData implements BlockData { +@@ -57,7 +57,7 @@ public class CraftBlockData implements BlockData { @Override public Material getMaterial() { diff --git a/patches/server/0490-Player-elytra-boost-API.patch b/patches/server/0490-Player-elytra-boost-API.patch index 401e417658..d3ebc81c4e 100644 --- a/patches/server/0490-Player-elytra-boost-API.patch +++ b/patches/server/0490-Player-elytra-boost-API.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Player elytra boost API diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -index 1c29a51b66ae19ec208cc55fe94facff5f961c72..bd36b43018f52bdfeca7b4cd49030dc46fb6eaf5 100644 +index 6cac6959133d90f5755ed5272f7edc261a94cb69..aa926c0647acfc98ab9075b826dd34f68a4189c1 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -@@ -644,6 +644,20 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -648,6 +648,20 @@ public class CraftPlayer extends CraftHumanEntity implements Player { } throw new RuntimeException("Unknown settings type"); } diff --git a/patches/server/0492-Avoid-error-bubbling-up-when-item-stack-is-empty-in-.patch b/patches/server/0492-Avoid-error-bubbling-up-when-item-stack-is-empty-in-.patch index 0d485f863d..4b7b7f82a4 100644 --- a/patches/server/0492-Avoid-error-bubbling-up-when-item-stack-is-empty-in-.patch +++ b/patches/server/0492-Avoid-error-bubbling-up-when-item-stack-is-empty-in-.patch @@ -8,10 +8,10 @@ This can realistically only happen if there's custom loot active on fishing which can return 0 items. This would disconnect the player who's fishing. diff --git a/src/main/java/net/minecraft/world/entity/projectile/FishingHook.java b/src/main/java/net/minecraft/world/entity/projectile/FishingHook.java -index 7d058efff8820727e2e8531bdd57f85059b5ca30..d77410588a1c10d8ac902f21a8bd7e35f74fecd2 100644 +index 082fa4318dc03defbdb76e99250b7d71aa6710f5..02eb61138ed8e977498bfb9c75b0d4759347154c 100644 --- a/src/main/java/net/minecraft/world/entity/projectile/FishingHook.java +++ b/src/main/java/net/minecraft/world/entity/projectile/FishingHook.java -@@ -495,9 +495,15 @@ public class FishingHook extends Projectile { +@@ -503,9 +503,15 @@ public class FishingHook extends Projectile { while (iterator.hasNext()) { ItemStack itemstack1 = (ItemStack) iterator.next(); @@ -29,7 +29,7 @@ index 7d058efff8820727e2e8531bdd57f85059b5ca30..d77410588a1c10d8ac902f21a8bd7e35 playerFishEvent.setExpToDrop(this.random.nextInt(6) + 1); this.level.getCraftServer().getPluginManager().callEvent(playerFishEvent); -@@ -510,8 +516,12 @@ public class FishingHook extends Projectile { +@@ -518,8 +524,12 @@ public class FishingHook extends Projectile { double d2 = entityhuman.getZ() - this.getZ(); double d3 = 0.1D; diff --git a/patches/server/0493-Add-getOfflinePlayerIfCached-String.patch b/patches/server/0493-Add-getOfflinePlayerIfCached-String.patch index 34947965d2..6a847fc835 100644 --- a/patches/server/0493-Add-getOfflinePlayerIfCached-String.patch +++ b/patches/server/0493-Add-getOfflinePlayerIfCached-String.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Add getOfflinePlayerIfCached(String) diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 24f0e19f0ce76d9efa2acae2d8514c97cd4415fa..689ee858c4c0635f03390d30f84f635be4758c49 100644 +index 5891dc6a41a0043ff85d343b7da5024c96f9a77e..1a745fbb6325d3dfb87714f54d7aa46ddf93ce04 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -1808,6 +1808,28 @@ public final class CraftServer implements Server { +@@ -1809,6 +1809,28 @@ public final class CraftServer implements Server { return result; } diff --git a/patches/server/0500-Add-API-for-quit-reason.patch b/patches/server/0500-Add-API-for-quit-reason.patch index 64bd874a12..df56d5e3ed 100644 --- a/patches/server/0500-Add-API-for-quit-reason.patch +++ b/patches/server/0500-Add-API-for-quit-reason.patch @@ -25,10 +25,10 @@ index ecc075d22b24f9e70cd3751c9ceea84b903020ae..90dd5a5c3ac94782483f99165bb3ddc8 Connection.LOGGER.debug("Failed to sent packet", throwable); ConnectionProtocol enumprotocol = this.getCurrentProtocol(); diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java -index ce6ae0ec4d104929f2c3fe03b0f44eafbfec1d9a..e746d6f303c5df3ec367963c4335304f15028146 100644 +index 5b6ecebcb4585877a2761eb17f4810042320e681..5c38036574951ef4080da5e3315ce516acb53484 100644 --- a/src/main/java/net/minecraft/server/level/ServerPlayer.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java -@@ -274,6 +274,7 @@ public class ServerPlayer extends Player { +@@ -276,6 +276,7 @@ public class ServerPlayer extends Player { public double lastEntitySpawnRadiusSquared; // Paper - optimise isOutsideRange, this field is in blocks public final com.destroystokyo.paper.util.misc.PooledLinkedHashSets.PooledObjectLinkedOpenHashSet cachedSingleHashSet; // Paper public PlayerNaturallySpawnCreaturesEvent playerNaturallySpawnedEvent; // Paper @@ -37,10 +37,10 @@ index ce6ae0ec4d104929f2c3fe03b0f44eafbfec1d9a..e746d6f303c5df3ec367963c4335304f public ServerPlayer(MinecraftServer server, ServerLevel world, GameProfile profile) { super(world, world.getSharedSpawnPos(), world.getSharedSpawnAngle(), profile); diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 0a06cdcccbdf503814386c27a8fb614da671c441..d68db0fc61be13b5970a3c3c8e4b870cd3b2a316 100644 +index 910f40b87eb574e77e991acac431a0f61f5b6bf3..afebb0d8f5846d4e0d29a495216d1debf30ac4f9 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -506,6 +506,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -507,6 +507,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic final Component ichatbasecomponent = PaperAdventure.asVanilla(event.reason()); // Paper - Adventure // CraftBukkit end @@ -49,10 +49,10 @@ index 0a06cdcccbdf503814386c27a8fb614da671c441..d68db0fc61be13b5970a3c3c8e4b870c 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 162b09cda517afe3b87321a4fe871c183db37621..0df62830f211f96e9341f618282c6cb5834d76aa 100644 +index 9b75cf08096689522b670ad48e73126ad4cfc9b5..1f739c0e9a6323967719a515bfce6c4885d8dae6 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -564,7 +564,7 @@ public abstract class PlayerList { +@@ -566,7 +566,7 @@ public abstract class PlayerList { entityplayer.closeContainer(org.bukkit.event.inventory.InventoryCloseEvent.Reason.DISCONNECT); // Paper } diff --git a/patches/server/0502-Expose-world-spawn-angle.patch b/patches/server/0502-Expose-world-spawn-angle.patch index 7167e0de7a..80374db33e 100644 --- a/patches/server/0502-Expose-world-spawn-angle.patch +++ b/patches/server/0502-Expose-world-spawn-angle.patch @@ -5,15 +5,15 @@ 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 0df62830f211f96e9341f618282c6cb5834d76aa..bdd87da66db5febfb4e1f69d8c5f75fd28c23ea1 100644 +index 1f739c0e9a6323967719a515bfce6c4885d8dae6..cd8e11b073f53c824965c91129d502f89ac2b465 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -828,7 +828,7 @@ public abstract class PlayerList { +@@ -830,7 +830,7 @@ public abstract class PlayerList { if (location == null) { worldserver1 = this.server.getLevel(Level.OVERWORLD); blockposition = entityplayer1.getSpawnPoint(worldserver1); -- location = new Location(worldserver1.getWorld(), (double) ((float) blockposition.getX() + 0.5F), (double) ((float) blockposition.getY() + 0.1F), (double) ((float) blockposition.getZ() + 0.5F)); -+ location = new Location(worldserver1.getWorld(), (double) ((float) blockposition.getX() + 0.5F), (double) ((float) blockposition.getY() + 0.1F), (double) ((float) blockposition.getZ() + 0.5F), worldserver1.levelData.getSpawnAngle(), 0.0F); // Paper - use world spawn angle +- location = CraftLocation.toBukkit(blockposition, worldserver1.getWorld()).add(0.5F, 0.1F, 0.5F); ++ location = CraftLocation.toBukkit(blockposition, worldserver1.getWorld(), worldserver1.levelData.getSpawnAngle(), 0.0F).add(0.5F, 0.1F, 0.5F); // Paper - use world spawn angle } Player respawnPlayer = entityplayer1.getBukkitEntity(); diff --git a/patches/server/0503-Add-Destroy-Speed-API.patch b/patches/server/0503-Add-Destroy-Speed-API.patch index 92681b95f5..94c411b8af 100644 --- a/patches/server/0503-Add-Destroy-Speed-API.patch +++ b/patches/server/0503-Add-Destroy-Speed-API.patch @@ -6,10 +6,10 @@ Subject: [PATCH] Add Destroy Speed API Co-authored-by: Jake Potrebic diff --git a/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java b/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java -index 998cb47c4d3d1c67467469e661f80d231d17c04a..c3ab1a60f60806e2b91b633bf89389cf434443ce 100644 +index 4167b665abdae0db1425f50ccf175bc35699abca..32fdb3cf74a2d0c27b9cb572e7c16c7eda400ea7 100644 --- a/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java +++ b/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java -@@ -699,5 +699,26 @@ public class CraftBlock implements Block { +@@ -698,5 +698,26 @@ public class CraftBlock implements Block { public String translationKey() { return this.getNMS().getBlock().getDescriptionId(); } diff --git a/patches/server/0504-Fix-Player-spawnParticle-x-y-z-precision-loss.patch b/patches/server/0504-Fix-Player-spawnParticle-x-y-z-precision-loss.patch index 0c252d029d..51ad47abb3 100644 --- a/patches/server/0504-Fix-Player-spawnParticle-x-y-z-precision-loss.patch +++ b/patches/server/0504-Fix-Player-spawnParticle-x-y-z-precision-loss.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Fix Player spawnParticle x/y/z precision loss diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -index bd36b43018f52bdfeca7b4cd49030dc46fb6eaf5..db183a5b2bcd25d66e3386f89598d2f943c7ffc0 100644 +index aa926c0647acfc98ab9075b826dd34f68a4189c1..c4b5267263fdf5b1a7d94ac3f5fd5212d026cefd 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -@@ -2505,7 +2505,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -2513,7 +2513,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player { if (data != null && !particle.getDataType().isInstance(data)) { throw new IllegalArgumentException("data should be " + particle.getDataType() + " got " + data.getClass()); } diff --git a/patches/server/0509-Climbing-should-not-bypass-cramming-gamerule.patch b/patches/server/0509-Climbing-should-not-bypass-cramming-gamerule.patch index dd527a0059..21cfdd6f72 100644 --- a/patches/server/0509-Climbing-should-not-bypass-cramming-gamerule.patch +++ b/patches/server/0509-Climbing-should-not-bypass-cramming-gamerule.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Climbing should not bypass cramming gamerule diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index f4cca3313b0a5ac69f5b47da727d9ea3e2b7ffc5..25e8dcca51dbefc027d985ba09b973fac17702f7 100644 +index 3d9447b976fbaedb55b526efba7e5d9e7110ade7..d5a5f499bbdc950b66de62370482f122e4a16511 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -1929,6 +1929,12 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -1930,6 +1930,12 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { } public boolean isPushable() { @@ -45,7 +45,7 @@ index 302676ef78ed5b3b7fc1b04851447ca72eed10c0..a00c3d96f2fc7131d1f4afa7af4e41ac } else if (entity.level.isClientSide && (!(entity1 instanceof Player) || !((Player) entity1).isLocalPlayer())) { return false; diff --git a/src/main/java/net/minecraft/world/entity/LivingEntity.java b/src/main/java/net/minecraft/world/entity/LivingEntity.java -index 164c22a70f4b916615da36819cae09d94cd88d39..c7209675ad3eeca881da75bfc0c3212204da898e 100644 +index 450d6c28dcf8969902ab75d4a7b06aa9c3013fb4..fcd670d1371dca3bb644dfea79f98670d75a68a4 100644 --- a/src/main/java/net/minecraft/world/entity/LivingEntity.java +++ b/src/main/java/net/minecraft/world/entity/LivingEntity.java @@ -3356,7 +3356,7 @@ public abstract class LivingEntity extends Entity implements Attackable { @@ -130,10 +130,10 @@ index 3be5ea477cb3dd3ce75f3feced8daf7cce7075cd..3677dd991ae73428984e62e4d6fb7573 } diff --git a/src/main/java/net/minecraft/world/entity/vehicle/AbstractMinecart.java b/src/main/java/net/minecraft/world/entity/vehicle/AbstractMinecart.java -index 1e39bdb3146bcc577abc77021d7b9c9dcce51f4c..aa474c7bc8bb8f1ecfefc49da987011da298fa67 100644 +index b66f06d0442ed65023f84ea15651ddfc72f056a5..a2e3b3a60ec31f2399f733ab1931c060ced7ae6d 100644 --- a/src/main/java/net/minecraft/world/entity/vehicle/AbstractMinecart.java +++ b/src/main/java/net/minecraft/world/entity/vehicle/AbstractMinecart.java -@@ -146,7 +146,7 @@ public abstract class AbstractMinecart extends Entity { +@@ -147,7 +147,7 @@ public abstract class AbstractMinecart extends Entity { } @Override @@ -143,10 +143,10 @@ index 1e39bdb3146bcc577abc77021d7b9c9dcce51f4c..aa474c7bc8bb8f1ecfefc49da987011d } diff --git a/src/main/java/net/minecraft/world/entity/vehicle/Boat.java b/src/main/java/net/minecraft/world/entity/vehicle/Boat.java -index f2a3e239ec812f717d0bb209b7894a6b5b9b950a..e8c201d45497e212cfeba125a9261d75198cadf7 100644 +index 8921c74ebf922c5af0db72793cd046b959543663..b2ecd45588d930f6847d11d3fb3c5fb02abd7737 100644 --- a/src/main/java/net/minecraft/world/entity/vehicle/Boat.java +++ b/src/main/java/net/minecraft/world/entity/vehicle/Boat.java -@@ -159,7 +159,7 @@ public class Boat extends Entity implements VariantHolder { +@@ -160,7 +160,7 @@ public class Boat extends Entity implements VariantHolder { } @Override diff --git a/patches/server/0513-Limit-recipe-packets.patch b/patches/server/0513-Limit-recipe-packets.patch index 5d490eac2c..c20f647e2a 100644 --- a/patches/server/0513-Limit-recipe-packets.patch +++ b/patches/server/0513-Limit-recipe-packets.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Limit recipe packets diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index d68db0fc61be13b5970a3c3c8e4b870cd3b2a316..1a7e3049bf7fa16e31748d5acbb14cdcee65379c 100644 +index 5f6cbead15aca14ad983bb49ab52fe1e71bb24ec..97e842e2268fa1084d46d2423e2212d97a3c6c05 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 +@@ -266,6 +266,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic // CraftBukkit start - multithreaded fields private final AtomicInteger chatSpamTickCount = new AtomicInteger(); private final java.util.concurrent.atomic.AtomicInteger tabSpamLimiter = new java.util.concurrent.atomic.AtomicInteger(); // Paper - configurable tab spam limits @@ -16,7 +16,7 @@ index d68db0fc61be13b5970a3c3c8e4b870cd3b2a316..1a7e3049bf7fa16e31748d5acbb14cdc // CraftBukkit end private int dropSpamTickCount; private double firstGoodX; -@@ -417,6 +418,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -418,6 +419,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic // CraftBukkit start for (int spam; (spam = this.chatSpamTickCount.get()) > 0 && !this.chatSpamTickCount.compareAndSet(spam, spam - 1); ) ; if (tabSpamLimiter.get() > 0) tabSpamLimiter.getAndDecrement(); // Paper - split to seperate variable @@ -24,7 +24,7 @@ index d68db0fc61be13b5970a3c3c8e4b870cd3b2a316..1a7e3049bf7fa16e31748d5acbb14cdc /* Use thread-safe field access instead if (this.chatSpamTickCount > 0) { --this.chatSpamTickCount; -@@ -3127,6 +3129,14 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -3134,6 +3136,14 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic @Override public void handlePlaceRecipe(ServerboundPlaceRecipePacket packet) { diff --git a/patches/server/0515-Player-Chunk-Load-Unload-Events.patch b/patches/server/0515-Player-Chunk-Load-Unload-Events.patch index 2a20a4343c..43fc686460 100644 --- a/patches/server/0515-Player-Chunk-Load-Unload-Events.patch +++ b/patches/server/0515-Player-Chunk-Load-Unload-Events.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Player Chunk Load/Unload Events diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java -index e746d6f303c5df3ec367963c4335304f15028146..1add3a672179d6a558ba64545b4e8e22bab4ea3d 100644 +index 5c38036574951ef4080da5e3315ce516acb53484..cd2d5dc3a51a4600699bd20630d32a7d0897900e 100644 --- a/src/main/java/net/minecraft/server/level/ServerPlayer.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java -@@ -2160,11 +2160,21 @@ public class ServerPlayer extends Player { +@@ -2188,11 +2188,21 @@ public class ServerPlayer extends Player { public void trackChunk(ChunkPos chunkPos, Packet chunkDataPacket) { this.connection.send(chunkDataPacket); diff --git a/patches/server/0517-Expose-LivingEntity-hurt-direction.patch b/patches/server/0517-Expose-LivingEntity-hurt-direction.patch index 738222a620..94cc2314e2 100644 --- a/patches/server/0517-Expose-LivingEntity-hurt-direction.patch +++ b/patches/server/0517-Expose-LivingEntity-hurt-direction.patch @@ -5,7 +5,7 @@ Subject: [PATCH] Expose LivingEntity hurt direction diff --git a/src/main/java/net/minecraft/world/entity/player/Player.java b/src/main/java/net/minecraft/world/entity/player/Player.java -index a7dc305297d1a17291ffff40fe6c3bd7b8cc6bdb..ddaeedbcce43f29cfc9f8a438a7304e8f0b2430e 100644 +index 1ada0736ce35c0299e40d4ce8fbe49f170ea0c6f..70ce47777793d416d5f0bbcbf087e2f0a28a7740 100644 --- a/src/main/java/net/minecraft/world/entity/player/Player.java +++ b/src/main/java/net/minecraft/world/entity/player/Player.java @@ -181,7 +181,7 @@ public abstract class Player extends LivingEntity { @@ -18,10 +18,10 @@ index a7dc305297d1a17291ffff40fe6c3bd7b8cc6bdb..ddaeedbcce43f29cfc9f8a438a7304e8 public boolean affectsSpawning = true; // Paper end diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java -index 0117277db8402a1673c317673811c17d02edc4c9..539708d5d806c757305bee754d9a4f0de49a742f 100644 +index 581d99e0dbf4b1a59389645f01f33aed7a340686..ffd07d9751deb87902213a3349bcb398ee281640 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java -@@ -125,6 +125,13 @@ public class CraftHumanEntity extends CraftLivingEntity implements HumanEntity { +@@ -126,6 +126,13 @@ public class CraftHumanEntity extends CraftLivingEntity implements HumanEntity { } } diff --git a/patches/server/0518-Add-OBSTRUCTED-reason-to-BedEnterResult.patch b/patches/server/0518-Add-OBSTRUCTED-reason-to-BedEnterResult.patch index 02c1ab2bf7..4cdcac5566 100644 --- a/patches/server/0518-Add-OBSTRUCTED-reason-to-BedEnterResult.patch +++ b/patches/server/0518-Add-OBSTRUCTED-reason-to-BedEnterResult.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Add OBSTRUCTED reason to BedEnterResult diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java -index d590d0d2a2a66fdf91aca6238268aa4be91dcf9a..47519c7eca8ed44ea17edb0f7256b000c0af7f9d 100644 +index 79c542421199a5d9984f104204b275e050581db5..080c6581ba120e223b5c765cbd9225ef57150176 100644 --- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java +++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java -@@ -265,6 +265,10 @@ public class CraftEventFactory { +@@ -267,6 +267,10 @@ public class CraftEventFactory { return BedEnterResult.TOO_FAR_AWAY; case NOT_SAFE: return BedEnterResult.NOT_SAFE; diff --git a/patches/server/0522-MC-4-Fix-item-position-desync.patch b/patches/server/0522-MC-4-Fix-item-position-desync.patch index 0fa4c1a5f1..d53981f218 100644 --- a/patches/server/0522-MC-4-Fix-item-position-desync.patch +++ b/patches/server/0522-MC-4-Fix-item-position-desync.patch @@ -28,10 +28,10 @@ index 5ca3ad7b3d7606accd0a58b3c708fadb349608f7..4b6e0fe2fabcc55007fd8979e81f66df public Vec3 decode(long x, long y, long z) { diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index 443bf4c32105a88efbb4df0b8b803cb39ee8b751..d1eb347b80fcee37f59012505dd0ae5787f95d7b 100644 +index d5a5f499bbdc950b66de62370482f122e4a16511..909d9da2e0b30d4bf187623a46695c86d67b2248 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -4099,6 +4099,16 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -4100,6 +4100,16 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { return; } // Paper end - rewrite chunk system diff --git a/patches/server/0523-Additional-Block-Material-API-s.patch b/patches/server/0523-Additional-Block-Material-API-s.patch index 3a8a041708..ca6196dbea 100644 --- a/patches/server/0523-Additional-Block-Material-API-s.patch +++ b/patches/server/0523-Additional-Block-Material-API-s.patch @@ -9,10 +9,10 @@ process to do this in the Bukkit API Adds API for buildable, replaceable, burnable too. diff --git a/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java b/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java -index c3ab1a60f60806e2b91b633bf89389cf434443ce..23a9469ff63f1be7ab0091b2c86a614eaeba9f55 100644 +index 32fdb3cf74a2d0c27b9cb572e7c16c7eda400ea7..83d961be2a3527402c2e22aa5809bc8a7029170b 100644 --- a/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java +++ b/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java -@@ -465,6 +465,25 @@ public class CraftBlock implements Block { +@@ -464,6 +464,25 @@ public class CraftBlock implements Block { return this.getNMS().getMaterial().isLiquid(); } diff --git a/patches/server/0530-Fix-interact-event-not-being-called-in-adventure.patch b/patches/server/0530-Fix-interact-event-not-being-called-in-adventure.patch index 8eb2dd015e..d6331655da 100644 --- a/patches/server/0530-Fix-interact-event-not-being-called-in-adventure.patch +++ b/patches/server/0530-Fix-interact-event-not-being-called-in-adventure.patch @@ -6,10 +6,10 @@ Subject: [PATCH] Fix interact event not being called in adventure Call PlayerInteractEvent when left-clicking on a block in adventure mode diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 1a7e3049bf7fa16e31748d5acbb14cdcee65379c..690b84fc73a6de4aa4d420c6790a5ee5864042cb 100644 +index 97e842e2268fa1084d46d2423e2212d97a3c6c05..c7776ccb1f11296a0f3e7b8dcba8169677085de8 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -1834,7 +1834,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -1835,7 +1835,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic MutableComponent ichatmutablecomponent = Component.translatable("build.tooHigh", i - 1).withStyle(ChatFormatting.RED); this.player.sendSystemMessage(ichatmutablecomponent, true); @@ -18,7 +18,7 @@ index 1a7e3049bf7fa16e31748d5acbb14cdcee65379c..690b84fc73a6de4aa4d420c6790a5ee5 this.player.swing(enumhand, true); } } -@@ -2464,7 +2464,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -2471,7 +2471,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic // SPIGOT-5607: Only call interact event if no block or entity is being clicked. Use bukkit ray trace method, because it handles blocks and entities at the same time org.bukkit.util.RayTraceResult result = this.player.level.getWorld().rayTrace(origin, origin.getDirection(), d3, org.bukkit.FluidCollisionMode.NEVER, false, 0.1, entity -> entity != this.player.getBukkitEntity() && this.player.getBukkitEntity().canSee(entity)); diff --git a/patches/server/0534-Added-WorldGameRuleChangeEvent.patch b/patches/server/0534-Added-WorldGameRuleChangeEvent.patch index f21ee6ffce..e461fe7e65 100644 --- a/patches/server/0534-Added-WorldGameRuleChangeEvent.patch +++ b/patches/server/0534-Added-WorldGameRuleChangeEvent.patch @@ -64,10 +64,10 @@ index 4a0321f56ef80aa4991e61f586ddd3f6b45e499b..de713f1ca1d61a6b1fca2b66de916255 public int get() { diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -index 47d4a61934f07836d9275841fa566bf1d6851381..d51999ddb1403d72e38c93e5f6ad9d41ab34a059 100644 +index 2f4bdf2128037b06a3d5e7b340f5f888c8777ca8..0e9b81e16e1da8e72b7871fb6c6563b8e181fea4 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -@@ -1818,8 +1818,13 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -1804,8 +1804,13 @@ public class CraftWorld extends CraftRegionAccessor implements World { if (!this.isGameRule(rule)) return false; @@ -82,7 +82,7 @@ index 47d4a61934f07836d9275841fa566bf1d6851381..d51999ddb1403d72e38c93e5f6ad9d41 handle.onChanged(this.getHandle().getServer()); return true; } -@@ -1854,8 +1859,12 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -1840,8 +1845,12 @@ public class CraftWorld extends CraftRegionAccessor implements World { if (!this.isGameRule(rule.getName())) return false; diff --git a/patches/server/0537-Implemented-BlockFailedDispenseEvent.patch b/patches/server/0537-Implemented-BlockFailedDispenseEvent.patch index ba143d3e1d..43c173c10c 100644 --- a/patches/server/0537-Implemented-BlockFailedDispenseEvent.patch +++ b/patches/server/0537-Implemented-BlockFailedDispenseEvent.patch @@ -32,12 +32,12 @@ index 1415ad60163f6584619cc7caa61f1848d6ebaa93..801c4c120e98584bcf218a4ef9bd66d7 } else { ItemStack itemstack = tileentitydispenser.getItem(i); diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java -index 47519c7eca8ed44ea17edb0f7256b000c0af7f9d..74c45f5451f9284e3c6b46941b65f535574deda6 100644 +index 080c6581ba120e223b5c765cbd9225ef57150176..bfa999abcf00a76c85a02e69dcb60b37247d5415 100644 --- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java +++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java -@@ -1899,4 +1899,12 @@ public class CraftEventFactory { - EntitiesUnloadEvent event = new EntitiesUnloadEvent(new CraftChunk((ServerLevel) world, coords.x, coords.z), bukkitEntities); - Bukkit.getPluginManager().callEvent(event); +@@ -1918,4 +1918,12 @@ public class CraftEventFactory { + + return !event.isCancelled(); } + + // Paper start diff --git a/patches/server/0542-Implement-API-to-expose-exact-interaction-point.patch b/patches/server/0542-Implement-API-to-expose-exact-interaction-point.patch index 40d8b11989..510a4d0e75 100644 --- a/patches/server/0542-Implement-API-to-expose-exact-interaction-point.patch +++ b/patches/server/0542-Implement-API-to-expose-exact-interaction-point.patch @@ -18,7 +18,7 @@ index 77eec518940ae41880e395b3dd051d89bd67c319..e6154cf74df39d0c87fc820027adc964 this.interactResult = event.useItemInHand() == Event.Result.DENY; this.interactPosition = blockposition.immutable(); diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java -index 74c45f5451f9284e3c6b46941b65f535574deda6..702a30fd7f3178ce30043283afd36a0ea6745cf9 100644 +index bfa999abcf00a76c85a02e69dcb60b37247d5415..df9c057391d28fb47b722d006aa0c828863ea6b2 100644 --- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java +++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java @@ -57,7 +57,9 @@ import net.minecraft.world.level.storage.loot.parameters.LootContextParams; @@ -31,7 +31,7 @@ index 74c45f5451f9284e3c6b46941b65f535574deda6..702a30fd7f3178ce30043283afd36a0e import org.bukkit.Material; import org.bukkit.NamespacedKey; import org.bukkit.Server; -@@ -490,7 +492,13 @@ public class CraftEventFactory { +@@ -492,7 +494,13 @@ public class CraftEventFactory { return CraftEventFactory.callPlayerInteractEvent(who, action, position, direction, itemstack, false, hand); } @@ -45,7 +45,7 @@ index 74c45f5451f9284e3c6b46941b65f535574deda6..702a30fd7f3178ce30043283afd36a0e Player player = (who == null) ? null : (Player) who.getBukkitEntity(); CraftItemStack itemInHand = CraftItemStack.asCraftMirror(itemstack); -@@ -516,7 +524,10 @@ public class CraftEventFactory { +@@ -518,7 +526,10 @@ public class CraftEventFactory { itemInHand = null; } diff --git a/patches/server/0544-Fix-villager-boat-exploit.patch b/patches/server/0544-Fix-villager-boat-exploit.patch index 69d365aedf..e8e565dcf7 100644 --- a/patches/server/0544-Fix-villager-boat-exploit.patch +++ b/patches/server/0544-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 bdd87da66db5febfb4e1f69d8c5f75fd28c23ea1..8184c987ecb91a11b260d89a4807ddfcb1f9aaf8 100644 +index cd8e11b073f53c824965c91129d502f89ac2b465..8b683ffd930155adf7b1cd1088322621d4e0a037 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -589,6 +589,14 @@ public abstract class PlayerList { +@@ -591,6 +591,14 @@ public abstract class PlayerList { PlayerList.LOGGER.debug("Removing player mount"); entityplayer.stopRiding(); entity.getPassengersAndSelf().forEach((entity1) -> { diff --git a/patches/server/0545-Add-sendOpLevel-API.patch b/patches/server/0545-Add-sendOpLevel-API.patch index 130c5b995c..6c3c461da8 100644 --- a/patches/server/0545-Add-sendOpLevel-API.patch +++ b/patches/server/0545-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 8184c987ecb91a11b260d89a4807ddfcb1f9aaf8..a6a58b9f9c3ae4acac374e4a29b41178aa0dec00 100644 +index 8b683ffd930155adf7b1cd1088322621d4e0a037..e287ed6e916e750ac8e87a5025b9f1503470d1cf 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -1077,6 +1077,11 @@ public abstract class PlayerList { +@@ -1079,6 +1079,11 @@ public abstract class PlayerList { } private void sendPlayerPermissionLevel(ServerPlayer player, int permissionLevel) { @@ -20,7 +20,7 @@ index 8184c987ecb91a11b260d89a4807ddfcb1f9aaf8..a6a58b9f9c3ae4acac374e4a29b41178 if (player.connection != null) { byte b0; -@@ -1091,8 +1096,10 @@ public abstract class PlayerList { +@@ -1093,8 +1098,10 @@ public abstract class PlayerList { player.connection.send(new ClientboundEntityEventPacket(player, b0)); } @@ -32,10 +32,10 @@ index 8184c987ecb91a11b260d89a4807ddfcb1f9aaf8..a6a58b9f9c3ae4acac374e4a29b41178 public boolean isWhiteListed(GameProfile profile) { diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -index db183a5b2bcd25d66e3386f89598d2f943c7ffc0..9b32c0d6a8e2a744957378acb562f4e321f0f0b7 100644 +index c4b5267263fdf5b1a7d94ac3f5fd5212d026cefd..48e6d04473a5c7c66f0d66b8aa119e8da755f321 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -@@ -658,6 +658,13 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -662,6 +662,13 @@ public class CraftPlayer extends CraftHumanEntity implements Player { ? (org.bukkit.entity.Firework) entity.getBukkitEntity() : null; } diff --git a/patches/server/0548-Collision-option-for-requiring-a-player-participant.patch b/patches/server/0548-Collision-option-for-requiring-a-player-participant.patch index 5479a1b399..0cb0acd11d 100644 --- a/patches/server/0548-Collision-option-for-requiring-a-player-participant.patch +++ b/patches/server/0548-Collision-option-for-requiring-a-player-participant.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Collision option for requiring a player participant diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index a8a955a66336e908fa685bb78c1a67ebedd07f5c..4e629c474b41e6342b8dffa6a601667ea12b319a 100644 +index 909d9da2e0b30d4bf187623a46695c86d67b2248..4dc8a8fcffddfc6673d5c161be1224d822ad3dab 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -1799,6 +1799,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -1800,6 +1800,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { public void push(Entity entity) { if (!this.isPassengerOfSameVehicle(entity)) { if (!entity.noPhysics && !this.noPhysics) { @@ -17,10 +17,10 @@ index a8a955a66336e908fa685bb78c1a67ebedd07f5c..4e629c474b41e6342b8dffa6a601667e double d1 = entity.getZ() - this.getZ(); double d2 = Mth.absMax(d0, d1); diff --git a/src/main/java/net/minecraft/world/entity/vehicle/AbstractMinecart.java b/src/main/java/net/minecraft/world/entity/vehicle/AbstractMinecart.java -index aa474c7bc8bb8f1ecfefc49da987011da298fa67..46c893fd33fdaf76d49af407112ff349e9579a12 100644 +index a2e3b3a60ec31f2399f733ab1931c060ced7ae6d..33dd6f9b3fde5bd19cfc6386dd9454df4a887489 100644 --- a/src/main/java/net/minecraft/world/entity/vehicle/AbstractMinecart.java +++ b/src/main/java/net/minecraft/world/entity/vehicle/AbstractMinecart.java -@@ -832,6 +832,7 @@ public abstract class AbstractMinecart extends Entity { +@@ -833,6 +833,7 @@ public abstract class AbstractMinecart extends Entity { public void push(Entity entity) { if (!this.level.isClientSide) { if (!entity.noPhysics && !this.noPhysics) { @@ -29,10 +29,10 @@ index aa474c7bc8bb8f1ecfefc49da987011da298fa67..46c893fd33fdaf76d49af407112ff349 // CraftBukkit start VehicleEntityCollisionEvent collisionEvent = new VehicleEntityCollisionEvent((Vehicle) this.getBukkitEntity(), entity.getBukkitEntity()); diff --git a/src/main/java/net/minecraft/world/entity/vehicle/Boat.java b/src/main/java/net/minecraft/world/entity/vehicle/Boat.java -index e8c201d45497e212cfeba125a9261d75198cadf7..765ba5b9b34f31d9b9dbdf2e2bf46554aaf612d9 100644 +index b2ecd45588d930f6847d11d3fb3c5fb02abd7737..8b562ca6cc92c31c764aebf05d511e347cff8a83 100644 --- a/src/main/java/net/minecraft/world/entity/vehicle/Boat.java +++ b/src/main/java/net/minecraft/world/entity/vehicle/Boat.java -@@ -245,6 +245,7 @@ public class Boat extends Entity implements VariantHolder { +@@ -246,6 +246,7 @@ public class Boat extends Entity implements VariantHolder { @Override public void push(Entity entity) { diff --git a/patches/server/0553-Implement-BlockPreDispenseEvent.patch b/patches/server/0553-Implement-BlockPreDispenseEvent.patch index e4be6588fa..e7a3c4af5f 100644 --- a/patches/server/0553-Implement-BlockPreDispenseEvent.patch +++ b/patches/server/0553-Implement-BlockPreDispenseEvent.patch @@ -17,10 +17,10 @@ index 85c5319837295bd2f85baebfe8d6660b267f1d5f..8f55d0753fa26924235c943595f0d1a0 tileentitydispenser.setItem(i, idispensebehavior.dispense(sourceblock, itemstack)); } diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java -index 702a30fd7f3178ce30043283afd36a0ea6745cf9..9aca4ca86176c18428440218715485f18ea6e069 100644 +index df9c057391d28fb47b722d006aa0c828863ea6b2..1e4d8cc53941ead119769d16cc82db1a7be1f6da 100644 --- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java +++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java -@@ -1917,5 +1917,11 @@ public class CraftEventFactory { +@@ -1936,5 +1936,11 @@ public class CraftEventFactory { io.papermc.paper.event.block.BlockFailedDispenseEvent event = new io.papermc.paper.event.block.BlockFailedDispenseEvent(block); return event.callEvent(); } diff --git a/patches/server/0557-Add-dropLeash-variable-to-EntityUnleashEvent.patch b/patches/server/0557-Add-dropLeash-variable-to-EntityUnleashEvent.patch index e1e8de21d0..4a3e11183b 100644 --- a/patches/server/0557-Add-dropLeash-variable-to-EntityUnleashEvent.patch +++ b/patches/server/0557-Add-dropLeash-variable-to-EntityUnleashEvent.patch @@ -122,10 +122,10 @@ index b5e35033e63da0e5f2c21fddf3b704d6730f0938..7a6cdae1b566f59508b180e720de4eff flag1 = true; } diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java -index 9aca4ca86176c18428440218715485f18ea6e069..9beed77bacf77ab480a5fffac8c542e834730eac 100644 +index 1e4d8cc53941ead119769d16cc82db1a7be1f6da..b20e4452b8cf5d7ed50db0de24f1167de6253a11 100644 --- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java +++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java -@@ -1549,8 +1549,10 @@ public class CraftEventFactory { +@@ -1558,8 +1558,10 @@ public class CraftEventFactory { return itemInHand; } diff --git a/patches/server/0558-Reset-shield-blocking-on-dimension-change.patch b/patches/server/0558-Reset-shield-blocking-on-dimension-change.patch index ab2f1bc7f7..15ebdb71cd 100644 --- a/patches/server/0558-Reset-shield-blocking-on-dimension-change.patch +++ b/patches/server/0558-Reset-shield-blocking-on-dimension-change.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Reset shield blocking on dimension change diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java -index 1add3a672179d6a558ba64545b4e8e22bab4ea3d..7062e2576f9158ac95f4c78255e210754ce90507 100644 +index cd2d5dc3a51a4600699bd20630d32a7d0897900e..ed9c6a4664b995fb62c97f86ce69a473b47f7efb 100644 --- a/src/main/java/net/minecraft/server/level/ServerPlayer.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java -@@ -1198,6 +1198,11 @@ public class ServerPlayer extends Player { +@@ -1200,6 +1200,11 @@ public class ServerPlayer extends Player { this.level.getCraftServer().getPluginManager().callEvent(changeEvent); // CraftBukkit end } diff --git a/patches/server/0563-Allow-adding-items-to-BlockDropItemEvent.patch b/patches/server/0563-Allow-adding-items-to-BlockDropItemEvent.patch index 0903afa181..a80491b6cb 100644 --- a/patches/server/0563-Allow-adding-items-to-BlockDropItemEvent.patch +++ b/patches/server/0563-Allow-adding-items-to-BlockDropItemEvent.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Allow adding items to BlockDropItemEvent diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java -index 9beed77bacf77ab480a5fffac8c542e834730eac..c00b2460f40c5c806e88645af63dfeb6f89ddd00 100644 +index b20e4452b8cf5d7ed50db0de24f1167de6253a11..0e8029a9beeb8bee245f1c94c8ee596ec0131177 100644 --- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java +++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java -@@ -416,13 +416,30 @@ public class CraftEventFactory { +@@ -418,13 +418,30 @@ public class CraftEventFactory { } public static void handleBlockDropItemEvent(Block block, BlockState state, ServerPlayer player, List items) { diff --git a/patches/server/0574-fix-converting-txt-to-json-file.patch b/patches/server/0574-fix-converting-txt-to-json-file.patch index 9515f522b3..aee0609038 100644 --- a/patches/server/0574-fix-converting-txt-to-json-file.patch +++ b/patches/server/0574-fix-converting-txt-to-json-file.patch @@ -48,10 +48,10 @@ index 520cd1a6b347687b2ec6d13f034be391d1a1af85..cc885fd0eb19516d3864a43c2e4ae785 if (!OldUsersConverter.serverReadyAfterUserconversion(this)) { return false; diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java -index a6a58b9f9c3ae4acac374e4a29b41178aa0dec00..b88f0c64d3509550c699f21505118312f88ff71d 100644 +index e287ed6e916e750ac8e87a5025b9f1503470d1cf..3ef97c793a85a9287b7fad66281e532285aaf5fc 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -184,6 +184,7 @@ public abstract class PlayerList { +@@ -186,6 +186,7 @@ public abstract class PlayerList { this.maxPlayers = maxPlayers; this.playerIo = saveHandler; } diff --git a/patches/server/0579-Add-Block-isValidTool.patch b/patches/server/0579-Add-Block-isValidTool.patch index eb96ef70ea..d8e9493ddc 100644 --- a/patches/server/0579-Add-Block-isValidTool.patch +++ b/patches/server/0579-Add-Block-isValidTool.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Add Block#isValidTool diff --git a/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java b/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java -index 23a9469ff63f1be7ab0091b2c86a614eaeba9f55..e8d96c1e5dde67436fba1bfc6585c3e4a5c1a63c 100644 +index 83d961be2a3527402c2e22aa5809bc8a7029170b..9e11a7967799c6f57e7461e22a3bb6f427af8418 100644 --- a/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java +++ b/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java -@@ -739,5 +739,9 @@ public class CraftBlock implements Block { +@@ -738,5 +738,9 @@ public class CraftBlock implements Block { } return speed; } diff --git a/patches/server/0580-Allow-using-signs-inside-spawn-protection.patch b/patches/server/0580-Allow-using-signs-inside-spawn-protection.patch index 4e24918114..59a2ffdf23 100644 --- a/patches/server/0580-Allow-using-signs-inside-spawn-protection.patch +++ b/patches/server/0580-Allow-using-signs-inside-spawn-protection.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Allow using signs inside spawn protection diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 690b84fc73a6de4aa4d420c6790a5ee5864042cb..1a256066b7836f6ad3fa33e5bb51222f3a69e50f 100644 +index ea910d24fe78aa972123414d9eb42e94c2c462f1..7bea2214ea3ffa93349a4675e1ba3b0e0430ee65 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -1826,7 +1826,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -1827,7 +1827,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic int i = this.player.level.getMaxBuildHeight(); if (blockposition.getY() < i) { diff --git a/patches/server/0581-Expand-world-key-API.patch b/patches/server/0581-Expand-world-key-API.patch index f21240c4eb..6f7bd70964 100644 --- a/patches/server/0581-Expand-world-key-API.patch +++ b/patches/server/0581-Expand-world-key-API.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Expand world key API diff --git a/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java b/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java -index 9db48bd6dcf0d24132123b86670341c1d8113840..d7ac103b82e9aac1e2f3b807d7b69fdfcf0dcb15 100644 +index 3ffea505826bbe4151268ed9cffa5f2ddea27b62..287dd68f1aa78bf5f1406f585e4a657563d6116c 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java -@@ -969,5 +969,10 @@ public abstract class CraftRegionAccessor implements RegionAccessor { +@@ -990,5 +990,10 @@ public abstract class CraftRegionAccessor implements RegionAccessor { public io.papermc.paper.world.MoonPhase getMoonPhase() { return io.papermc.paper.world.MoonPhase.getPhase(this.getHandle().dayTime() / 24000L); } @@ -20,10 +20,10 @@ index 9db48bd6dcf0d24132123b86670341c1d8113840..d7ac103b82e9aac1e2f3b807d7b69fdf // Paper end } diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 689ee858c4c0635f03390d30f84f635be4758c49..90230aec6707400fe07ab4431235b4f6383bdac0 100644 +index 1a745fbb6325d3dfb87714f54d7aa46ddf93ce04..79a0db289c837cc37e0d1caca91359bc3d96dbfe 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -1130,9 +1130,15 @@ public final class CraftServer implements Server { +@@ -1131,9 +1131,15 @@ public final class CraftServer implements Server { File folder = new File(this.getWorldContainer(), name); World world = this.getWorld(name); @@ -41,7 +41,7 @@ index 689ee858c4c0635f03390d30f84f635be4758c49..90230aec6707400fe07ab4431235b4f6 if ((folder.exists()) && (!folder.isDirectory())) { throw new IllegalArgumentException("File exists with the name '" + name + "' and isn't a folder"); -@@ -1221,7 +1227,7 @@ public final class CraftServer implements Server { +@@ -1222,7 +1228,7 @@ public final class CraftServer implements Server { } else if (name.equals(levelName + "_the_end")) { worldKey = net.minecraft.world.level.Level.END; } else { @@ -50,7 +50,7 @@ index 689ee858c4c0635f03390d30f84f635be4758c49..90230aec6707400fe07ab4431235b4f6 } ServerLevel internal = (ServerLevel) new ServerLevel(this.console, console.executor, worldSession, worlddata, worldKey, worlddimension, this.getServer().progressListenerFactory.create(11), -@@ -1313,6 +1319,15 @@ public final class CraftServer implements Server { +@@ -1314,6 +1320,15 @@ public final class CraftServer implements Server { return null; } diff --git a/patches/server/0585-Drop-carried-item-when-player-has-disconnected.patch b/patches/server/0585-Drop-carried-item-when-player-has-disconnected.patch index 01fc54e62f..5b671c35a4 100644 --- a/patches/server/0585-Drop-carried-item-when-player-has-disconnected.patch +++ b/patches/server/0585-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 b88f0c64d3509550c699f21505118312f88ff71d..fa195977aa53fcaea0e9873a484148efad51aefc 100644 +index 3ef97c793a85a9287b7fad66281e532285aaf5fc..481f2f5dc2e62ae0bbdb8bbac5e8c3c5e090def7 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -582,6 +582,14 @@ public abstract class PlayerList { +@@ -584,6 +584,14 @@ public abstract class PlayerList { } // Paper end diff --git a/patches/server/0587-Don-t-ignore-result-of-PlayerEditBookEvent.patch b/patches/server/0587-Don-t-ignore-result-of-PlayerEditBookEvent.patch index 96af2da429..2895dbdcea 100644 --- a/patches/server/0587-Don-t-ignore-result-of-PlayerEditBookEvent.patch +++ b/patches/server/0587-Don-t-ignore-result-of-PlayerEditBookEvent.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Don't ignore result of PlayerEditBookEvent diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 1a256066b7836f6ad3fa33e5bb51222f3a69e50f..9b25fe41cf4734ec677a69d1f41bcb2dad6f1fde 100644 +index 7bea2214ea3ffa93349a4675e1ba3b0e0430ee65..f851b24fb6ea9de4d6533f526f40a2dad338e0cc 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -1285,7 +1285,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -1286,7 +1286,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic } itemstack.addTagElement("pages", nbttaglist); diff --git a/patches/server/0593-Set-area-affect-cloud-rotation.patch b/patches/server/0593-Set-area-affect-cloud-rotation.patch index 9969cc639d..208c7c7e28 100644 --- a/patches/server/0593-Set-area-affect-cloud-rotation.patch +++ b/patches/server/0593-Set-area-affect-cloud-rotation.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Set area affect cloud rotation diff --git a/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java b/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java -index d7ac103b82e9aac1e2f3b807d7b69fdfcf0dcb15..2f35909b250584dd9def3c6e957d25ab33ca6e73 100644 +index 287dd68f1aa78bf5f1406f585e4a657563d6116c..f01c6f684da1438808f018fe9a814ecaceb49b2f 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java -@@ -935,6 +935,7 @@ public abstract class CraftRegionAccessor implements RegionAccessor { +@@ -956,6 +956,7 @@ public abstract class CraftRegionAccessor implements RegionAccessor { entity.moveTo(location.getX(), location.getY(), location.getZ()); } else if (AreaEffectCloud.class.isAssignableFrom(clazz)) { entity = new net.minecraft.world.entity.AreaEffectCloud(world, x, y, z); diff --git a/patches/server/0594-add-isDeeplySleeping-to-HumanEntity.patch b/patches/server/0594-add-isDeeplySleeping-to-HumanEntity.patch index a92e9872c2..4f6a4d704a 100644 --- a/patches/server/0594-add-isDeeplySleeping-to-HumanEntity.patch +++ b/patches/server/0594-add-isDeeplySleeping-to-HumanEntity.patch @@ -5,10 +5,10 @@ Subject: [PATCH] add isDeeplySleeping to HumanEntity diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java -index 539708d5d806c757305bee754d9a4f0de49a742f..b326654ef96cfd3f5cff476203844c2fb932b9b6 100644 +index ffd07d9751deb87902213a3349bcb398ee281640..86b5532b3be5484c68152a777b976bc44008b0df 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java -@@ -132,6 +132,13 @@ public class CraftHumanEntity extends CraftLivingEntity implements HumanEntity { +@@ -133,6 +133,13 @@ public class CraftHumanEntity extends CraftLivingEntity implements HumanEntity { } // Paper end diff --git a/patches/server/0598-fix-PlayerItemHeldEvent-firing-twice.patch b/patches/server/0598-fix-PlayerItemHeldEvent-firing-twice.patch index cec4a16aa5..a9d69c74c8 100644 --- a/patches/server/0598-fix-PlayerItemHeldEvent-firing-twice.patch +++ b/patches/server/0598-fix-PlayerItemHeldEvent-firing-twice.patch @@ -5,10 +5,10 @@ Subject: [PATCH] fix PlayerItemHeldEvent firing twice diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 9b25fe41cf4734ec677a69d1f41bcb2dad6f1fde..2ac2390b572c223e8c35a24e8f0978d39da148cc 100644 +index f851b24fb6ea9de4d6533f526f40a2dad338e0cc..ba923fe09602440846520153ae1be9bdea70bb8f 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -2040,6 +2040,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -2041,6 +2041,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic PacketUtils.ensureRunningOnSameThread(packet, this, this.player.getLevel()); if (this.player.isImmobile()) return; // CraftBukkit if (packet.getSlot() >= 0 && packet.getSlot() < Inventory.getSelectionSize()) { diff --git a/patches/server/0600-More-World-API.patch b/patches/server/0600-More-World-API.patch index 68cc74cd6c..b4f0dbb500 100644 --- a/patches/server/0600-More-World-API.patch +++ b/patches/server/0600-More-World-API.patch @@ -5,11 +5,11 @@ Subject: [PATCH] More World API diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -index d51999ddb1403d72e38c93e5f6ad9d41ab34a059..87fca10b6e37f01250bff14862215120763232d5 100644 +index 0e9b81e16e1da8e72b7871fb6c6563b8e181fea4..4e73e38dcec36b4ab0a03c6bd1b70811233f9a0a 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -@@ -2060,6 +2060,69 @@ public class CraftWorld extends CraftRegionAccessor implements World { - return new CraftStructureSearchResult(CraftStructure.minecraftToBukkit(found.getSecond().value(), this.getHandle().registryAccess()), new Location(this, found.getFirst().getX(), found.getFirst().getY(), found.getFirst().getZ())); +@@ -2046,6 +2046,69 @@ public class CraftWorld extends CraftRegionAccessor implements World { + return new CraftStructureSearchResult(CraftStructure.minecraftToBukkit(found.getSecond().value(), this.getHandle().registryAccess()), CraftLocation.toBukkit(found.getFirst(), this)); } + // Paper start diff --git a/patches/server/0603-Fix-anchor-respawn-acting-as-a-bed-respawn-from-the-.patch b/patches/server/0603-Fix-anchor-respawn-acting-as-a-bed-respawn-from-the-.patch index 8dfb327fc3..507ef8d1dc 100644 --- a/patches/server/0603-Fix-anchor-respawn-acting-as-a-bed-respawn-from-the-.patch +++ b/patches/server/0603-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 fa195977aa53fcaea0e9873a484148efad51aefc..116a52b29beefce65e875a35ddae6caf255b7b54 100644 +index 481f2f5dc2e62ae0bbdb8bbac5e8c3c5e090def7..71b2a7d1d09a4a9da8d9a2822ef1daa417d468d0 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -801,6 +801,7 @@ public abstract class PlayerList { +@@ -803,6 +803,7 @@ public abstract class PlayerList { // Paper start boolean isBedSpawn = false; @@ -17,7 +17,7 @@ index fa195977aa53fcaea0e9873a484148efad51aefc..116a52b29beefce65e875a35ddae6caf boolean isRespawn = false; boolean isLocAltered = false; // Paper - Fix SPIGOT-5989 // Paper end -@@ -821,6 +822,7 @@ public abstract class PlayerList { +@@ -823,6 +824,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 fa195977aa53fcaea0e9873a484148efad51aefc..116a52b29beefce65e875a35ddae6caf Vec3 vec3d = (Vec3) optional.get(); float f1; -@@ -849,7 +851,7 @@ public abstract class PlayerList { +@@ -851,7 +853,7 @@ public abstract class PlayerList { } Player respawnPlayer = entityplayer1.getBukkitEntity(); diff --git a/patches/server/0605-add-RespawnFlags-to-PlayerRespawnEvent.patch b/patches/server/0605-add-RespawnFlags-to-PlayerRespawnEvent.patch index b14ca34518..6511c0aae4 100644 --- a/patches/server/0605-add-RespawnFlags-to-PlayerRespawnEvent.patch +++ b/patches/server/0605-add-RespawnFlags-to-PlayerRespawnEvent.patch @@ -5,10 +5,10 @@ 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 2ac2390b572c223e8c35a24e8f0978d39da148cc..4df88bd988c2e4d0b6d4d09e6c897b1d1f4e6682 100644 +index 7167fefcc623b03d9936fd4e4c329f0a51a01537..e6cbeae6800d22017b1762eaf9465419fbbe925f 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -2774,7 +2774,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -2781,7 +2781,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic case PERFORM_RESPAWN: if (this.player.wonGame) { this.player.wonGame = false; @@ -18,10 +18,10 @@ index 2ac2390b572c223e8c35a24e8f0978d39da148cc..4df88bd988c2e4d0b6d4d09e6c897b1d } 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 116a52b29beefce65e875a35ddae6caf255b7b54..54ccfd45a4a8373a40e7153c569b654fe2110506 100644 +index 71b2a7d1d09a4a9da8d9a2822ef1daa417d468d0..8883a3a0b28377bf3290adfc0353d2e65c70b828 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -760,6 +760,12 @@ public abstract class PlayerList { +@@ -762,6 +762,12 @@ public abstract class PlayerList { } public ServerPlayer respawn(ServerPlayer entityplayer, ServerLevel worldserver, boolean flag, Location location, boolean avoidSuffocation, RespawnReason reason) { @@ -34,7 +34,7 @@ index 116a52b29beefce65e875a35ddae6caf255b7b54..54ccfd45a4a8373a40e7153c569b654f entityplayer.stopRiding(); // CraftBukkit this.players.remove(entityplayer); this.playersByName.remove(entityplayer.getScoreboardName().toLowerCase(java.util.Locale.ROOT)); // Spigot -@@ -851,7 +857,7 @@ public abstract class PlayerList { +@@ -853,7 +859,7 @@ public abstract class PlayerList { } Player respawnPlayer = entityplayer1.getBukkitEntity(); diff --git a/patches/server/0609-Add-EntityBlockStorage-clearEntities.patch b/patches/server/0609-Add-EntityBlockStorage-clearEntities.patch index 2bd0ddfa38..5b7203c33d 100644 --- a/patches/server/0609-Add-EntityBlockStorage-clearEntities.patch +++ b/patches/server/0609-Add-EntityBlockStorage-clearEntities.patch @@ -21,10 +21,10 @@ index ea63802f2644bc2b5b3b0c72d7d09813cb68139d..82ad97800cb115cc4830337a59cc4608 return (Integer) state.getValue(BeehiveBlock.HONEY_LEVEL); } diff --git a/src/main/java/org/bukkit/craftbukkit/block/CraftBeehive.java b/src/main/java/org/bukkit/craftbukkit/block/CraftBeehive.java -index ee4d7f5558ed76e8d8b56133da729a5303d1d823..e00210950cbf005b0e65aed68dfbb7c281aefd87 100644 +index e4333169c9b229208824f778ba65ac06654d36e0..380897c010521f368848a3e6986d307cf47ff319 100644 --- a/src/main/java/org/bukkit/craftbukkit/block/CraftBeehive.java +++ b/src/main/java/org/bukkit/craftbukkit/block/CraftBeehive.java -@@ -80,4 +80,10 @@ public class CraftBeehive extends CraftBlockEntityState impl +@@ -81,4 +81,10 @@ public class CraftBeehive extends CraftBlockEntityState impl getSnapshot().addOccupant(((CraftBee) entity).getHandle(), false); } diff --git a/patches/server/0615-Add-basic-Datapack-API.patch b/patches/server/0615-Add-basic-Datapack-API.patch index 9968ceade9..e00b32afd6 100644 --- a/patches/server/0615-Add-basic-Datapack-API.patch +++ b/patches/server/0615-Add-basic-Datapack-API.patch @@ -92,10 +92,10 @@ index 0000000000000000000000000000000000000000..cf4374493c11057451a62a655514415c + } +} diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 90230aec6707400fe07ab4431235b4f6383bdac0..d3256d726dda08da8f3e9facfd2cb242c2c08655 100644 +index 79a0db289c837cc37e0d1caca91359bc3d96dbfe..08e3da659371dc67db7ebea33ee2528f304a13ae 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -291,6 +291,7 @@ public final class CraftServer implements Server { +@@ -292,6 +292,7 @@ public final class CraftServer implements Server { public boolean ignoreVanillaPermissions = false; private final List playerView; public int reloadCount; @@ -103,7 +103,7 @@ index 90230aec6707400fe07ab4431235b4f6383bdac0..d3256d726dda08da8f3e9facfd2cb242 public static Exception excessiveVelEx; // Paper - Velocity warnings static { -@@ -377,6 +378,7 @@ public final class CraftServer implements Server { +@@ -378,6 +379,7 @@ public final class CraftServer implements Server { if (this.configuration.getBoolean("settings.use-map-color-cache")) { MapPalette.setMapColorCache(new CraftMapColorCache(this.logger)); } @@ -111,7 +111,7 @@ index 90230aec6707400fe07ab4431235b4f6383bdac0..d3256d726dda08da8f3e9facfd2cb242 } public boolean getCommandBlockOverride(String command) { -@@ -2774,5 +2776,11 @@ public final class CraftServer implements Server { +@@ -2775,5 +2777,11 @@ public final class CraftServer implements Server { public com.destroystokyo.paper.entity.ai.MobGoals getMobGoals() { return mobGoals; } diff --git a/patches/server/0617-additions-to-PlayerGameModeChangeEvent.patch b/patches/server/0617-additions-to-PlayerGameModeChangeEvent.patch index 215313fdb1..a8dc9d980d 100644 --- a/patches/server/0617-additions-to-PlayerGameModeChangeEvent.patch +++ b/patches/server/0617-additions-to-PlayerGameModeChangeEvent.patch @@ -45,10 +45,10 @@ index d47f3d255eddd652fedb4aa55286b756fe962995..27c0aaf123c3e945eb24e8a3892bd8ac } diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java -index 7062e2576f9158ac95f4c78255e210754ce90507..e4c6bff2a1e601266d889cc0532827d0c8885ece 100644 +index ed9c6a4664b995fb62c97f86ce69a473b47f7efb..47d2bf15871e50e46c0e5df725f2bbacfe12a869 100644 --- a/src/main/java/net/minecraft/server/level/ServerPlayer.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java -@@ -1839,8 +1839,15 @@ public class ServerPlayer extends Player { +@@ -1841,8 +1841,15 @@ public class ServerPlayer extends Player { } public boolean setGameMode(GameType gameMode) { @@ -66,7 +66,7 @@ index 7062e2576f9158ac95f4c78255e210754ce90507..e4c6bff2a1e601266d889cc0532827d0 } else { this.connection.send(new ClientboundGameEventPacket(ClientboundGameEventPacket.CHANGE_GAME_MODE, (float) gameMode.getId())); if (gameMode == GameType.SPECTATOR) { -@@ -1852,7 +1859,7 @@ public class ServerPlayer extends Player { +@@ -1854,7 +1861,7 @@ public class ServerPlayer extends Player { this.onUpdateAbilities(); this.updateEffectVisibility(); @@ -75,7 +75,7 @@ index 7062e2576f9158ac95f4c78255e210754ce90507..e4c6bff2a1e601266d889cc0532827d0 } } -@@ -2245,6 +2252,16 @@ public class ServerPlayer extends Player { +@@ -2273,6 +2280,16 @@ public class ServerPlayer extends Player { } public void loadGameTypes(@Nullable CompoundTag nbt) { @@ -129,10 +129,10 @@ index e6154cf74df39d0c87fc820027adc9641156f888..5461e6ff769be93054b3d8369a7aa286 } diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 4df88bd988c2e4d0b6d4d09e6c897b1d1f4e6682..454fb5def57fa2fbc62f530020d579d4ef0efc15 100644 +index e6cbeae6800d22017b1762eaf9465419fbbe925f..43f02b1de7176f335f88ca6080b6d88bdf6f3fae 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -2783,7 +2783,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -2790,7 +2790,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic this.player = this.server.getPlayerList().respawn(this.player, false, RespawnReason.DEATH); if (this.server.isHardcore()) { @@ -142,10 +142,10 @@ index 4df88bd988c2e4d0b6d4d09e6c897b1d1f4e6682..454fb5def57fa2fbc62f530020d579d4 } } diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -index 9b32c0d6a8e2a744957378acb562f4e321f0f0b7..66c61c0f59efe2c3f0ae2d07ef7f1dfcfd1e0e64 100644 +index 48e6d04473a5c7c66f0d66b8aa119e8da755f321..05c7a359ee18612eeda9672afb362754ca776b2d 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -@@ -1552,7 +1552,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -1560,7 +1560,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player { throw new IllegalArgumentException("Mode cannot be null"); } diff --git a/patches/server/0620-Move-range-check-for-block-placing-up.patch b/patches/server/0620-Move-range-check-for-block-placing-up.patch index dc366cdea4..2950420d2c 100644 --- a/patches/server/0620-Move-range-check-for-block-placing-up.patch +++ b/patches/server/0620-Move-range-check-for-block-placing-up.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Move range check for block placing up diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 454fb5def57fa2fbc62f530020d579d4ef0efc15..6289d1f681366ddbe2c83b08b76a76dbafcc29ea 100644 +index f71463e6ffaedbd52c3c38d5e5e99580a523c537..42235dd332a45d8112c14379f06072a2f4d46351 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -1812,6 +1812,11 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -1813,6 +1813,11 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic if (itemstack.isItemEnabled(worldserver.enabledFeatures())) { BlockHitResult movingobjectpositionblock = packet.getHitResult(); Vec3 vec3d = movingobjectpositionblock.getLocation(); diff --git a/patches/server/0621-Fix-and-optimise-world-force-upgrading.patch b/patches/server/0621-Fix-and-optimise-world-force-upgrading.patch index 70ac04c140..b89f668424 100644 --- a/patches/server/0621-Fix-and-optimise-world-force-upgrading.patch +++ b/patches/server/0621-Fix-and-optimise-world-force-upgrading.patch @@ -359,10 +359,10 @@ index b294ef87fb93e7f4651dc04128124f297575860d..65fd57609e45ccd49ebfc1ba80d25243 return this.regionCache.getAndMoveToFirst(ChunkPos.asLong(chunkcoordintpair.getRegionX(), chunkcoordintpair.getRegionZ())); } diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index d3256d726dda08da8f3e9facfd2cb242c2c08655..a469b39c47b1b9feba344672646ee14c11b42a81 100644 +index 08e3da659371dc67db7ebea33ee2528f304a13ae..a963c1e6aaba4fd55f5462be89e9afe8b20f082a 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -1206,12 +1206,7 @@ public final class CraftServer implements Server { +@@ -1207,12 +1207,7 @@ public final class CraftServer implements Server { worlddata.customDimensions = iregistry; worlddata.checkName(name); worlddata.setModdedInfo(this.console.getServerModName(), this.console.getModdedStatus().shouldReportAsModified()); @@ -376,7 +376,7 @@ index d3256d726dda08da8f3e9facfd2cb242c2c08655..a469b39c47b1b9feba344672646ee14c long j = BiomeManager.obfuscateSeed(creator.seed()); List list = ImmutableList.of(new PhantomSpawner(), new PatrolSpawner(), new CatSpawner(), new VillageSiege(), new WanderingTraderSpawner(worlddata)); -@@ -1222,6 +1217,13 @@ public final class CraftServer implements Server { +@@ -1223,6 +1218,13 @@ public final class CraftServer implements Server { biomeProvider = generator.getDefaultBiomeProvider(worldInfo); } diff --git a/patches/server/0623-Add-Unix-domain-socket-support.patch b/patches/server/0623-Add-Unix-domain-socket-support.patch index 16e4192278..0722771488 100644 --- a/patches/server/0623-Add-Unix-domain-socket-support.patch +++ b/patches/server/0623-Add-Unix-domain-socket-support.patch @@ -91,10 +91,10 @@ index 29a0a720f22f56ca3d844efef1ecde3980fb1c12..838244e3680ea6020701e10bafbde7f5 } diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 6289d1f681366ddbe2c83b08b76a76dbafcc29ea..ef670cf38d3ddbeff0f2b87a41cbed695116f270 100644 +index de25c0c55ef0089032e8c74befceba44543b8009..6fa63190a39343c50c2d49fe7fa09f7163db7101 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -2618,6 +2618,11 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -2625,6 +2625,11 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic // Spigot Start public SocketAddress getRawAddress() { diff --git a/patches/server/0626-Add-cause-to-Weather-ThunderChangeEvents.patch b/patches/server/0626-Add-cause-to-Weather-ThunderChangeEvents.patch index 42549abfa0..2b944db6c6 100644 --- a/patches/server/0626-Add-cause-to-Weather-ThunderChangeEvents.patch +++ b/patches/server/0626-Add-cause-to-Weather-ThunderChangeEvents.patch @@ -95,10 +95,10 @@ index 543d578eb87da6ff526cad7e65c8af76b1043e84..936b7f464097c30fe4dfbe4cee1c1490 if (weather.isCancelled()) { return; diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -index 87fca10b6e37f01250bff14862215120763232d5..c28f873cbc3c6f9180f051cf6277f75866415474 100644 +index 4e73e38dcec36b4ab0a03c6bd1b70811233f9a0a..fb4d76aa19033bdf62c45680d622764dbd9b419c 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -@@ -1193,7 +1193,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -1179,7 +1179,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { @Override public void setStorm(boolean hasStorm) { @@ -107,7 +107,7 @@ index 87fca10b6e37f01250bff14862215120763232d5..c28f873cbc3c6f9180f051cf6277f758 this.setWeatherDuration(0); // Reset weather duration (legacy behaviour) this.setClearWeatherDuration(0); // Reset clear weather duration (reset "/weather clear" commands) } -@@ -1215,7 +1215,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -1201,7 +1201,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { @Override public void setThundering(boolean thundering) { diff --git a/patches/server/0629-Add-PlayerKickEvent-causes.patch b/patches/server/0629-Add-PlayerKickEvent-causes.patch index 2a2312eb20..2411e963b5 100644 --- a/patches/server/0629-Add-PlayerKickEvent-causes.patch +++ b/patches/server/0629-Add-PlayerKickEvent-causes.patch @@ -88,10 +88,10 @@ 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 ef670cf38d3ddbeff0f2b87a41cbed695116f270..82ddc28c97bf8ecf2ca703b612d752c0319a6b0f 100644 +index 6fa63190a39343c50c2d49fe7fa09f7163db7101..18bf0ab7e897d4c75134359fee7e089ea641b81b 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -361,7 +361,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -362,7 +362,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic if (this.clientIsFloating && !this.player.isSleeping() && !this.player.isPassenger() && !this.player.isDeadOrDying()) { if (++this.aboveGroundTickCount > 80) { ServerGamePacketListenerImpl.LOGGER.warn("{} was kicked for floating too long!", this.player.getName().getString()); @@ -100,7 +100,7 @@ index ef670cf38d3ddbeff0f2b87a41cbed695116f270..82ddc28c97bf8ecf2ca703b612d752c0 return; } } else { -@@ -380,7 +380,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -381,7 +381,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic if (this.clientVehicleIsFloating && this.player.getRootVehicle().getControllingPassenger() == this.player) { if (++this.aboveGroundVehicleTickCount > 80) { ServerGamePacketListenerImpl.LOGGER.warn("{} was kicked for floating a vehicle too long!", this.player.getName().getString()); @@ -109,7 +109,7 @@ index ef670cf38d3ddbeff0f2b87a41cbed695116f270..82ddc28c97bf8ecf2ca703b612d752c0 return; } } else { -@@ -402,7 +402,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -403,7 +403,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic if (this.keepAlivePending) { if (!this.processedDisconnect && elapsedTime >= KEEPALIVE_LIMIT) { // check keepalive limit, don't fire if already disconnected ServerGamePacketListenerImpl.LOGGER.warn("{} was kicked due to keepalive timeout!", this.player.getScoreboardName()); // more info @@ -118,7 +118,7 @@ index ef670cf38d3ddbeff0f2b87a41cbed695116f270..82ddc28c97bf8ecf2ca703b612d752c0 } } else { if (elapsedTime >= 15000L) { // 15 seconds -@@ -432,7 +432,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -433,7 +433,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic if (this.player.getLastActionTime() > 0L && this.server.getPlayerIdleTimeout() > 0 && Util.getMillis() - this.player.getLastActionTime() > (long) (this.server.getPlayerIdleTimeout() * 1000 * 60)) { this.player.resetLastActionTime(); // CraftBukkit - SPIGOT-854 @@ -127,7 +127,7 @@ index ef670cf38d3ddbeff0f2b87a41cbed695116f270..82ddc28c97bf8ecf2ca703b612d752c0 } } -@@ -455,16 +455,26 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -456,16 +456,26 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic return this.server.isSingleplayerOwner(this.player.getGameProfile()); } @@ -157,7 +157,7 @@ index ef670cf38d3ddbeff0f2b87a41cbed695116f270..82ddc28c97bf8ecf2ca703b612d752c0 // Paper end // CraftBukkit start - fire PlayerKickEvent if (this.processedDisconnect) { -@@ -474,7 +484,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -475,7 +485,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic Waitable waitable = new Waitable() { @Override protected Object evaluate() { @@ -166,7 +166,7 @@ index ef670cf38d3ddbeff0f2b87a41cbed695116f270..82ddc28c97bf8ecf2ca703b612d752c0 return null; } }; -@@ -493,7 +503,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -494,7 +504,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic net.kyori.adventure.text.Component leaveMessage = net.kyori.adventure.text.Component.translatable("multiplayer.player.left", net.kyori.adventure.text.format.NamedTextColor.YELLOW, io.papermc.paper.configuration.GlobalConfiguration.get().messages.useDisplayNameInQuitMessage ? this.player.getBukkitEntity().displayName() : net.kyori.adventure.text.Component.text(this.player.getScoreboardName())); // Paper - Adventure @@ -175,7 +175,7 @@ index ef670cf38d3ddbeff0f2b87a41cbed695116f270..82ddc28c97bf8ecf2ca703b612d752c0 if (this.cserver.getServer().isRunning()) { this.cserver.getPluginManager().callEvent(event); -@@ -563,7 +573,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -564,7 +574,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic public void handleMoveVehicle(ServerboundMoveVehiclePacket packet) { PacketUtils.ensureRunningOnSameThread(packet, this, this.player.getLevel()); if (ServerGamePacketListenerImpl.containsInvalidValues(packet.getX(), packet.getY(), packet.getZ(), packet.getYRot(), packet.getXRot())) { @@ -184,7 +184,7 @@ index ef670cf38d3ddbeff0f2b87a41cbed695116f270..82ddc28c97bf8ecf2ca703b612d752c0 } else { Entity entity = this.player.getRootVehicle(); -@@ -761,7 +771,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -762,7 +772,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic PacketUtils.ensureRunningOnSameThread(packet, this, this.player.getLevel()); if (packet.getId() == this.awaitingTeleport) { if (this.awaitingPositionFromClient == null) { @@ -193,7 +193,7 @@ index ef670cf38d3ddbeff0f2b87a41cbed695116f270..82ddc28c97bf8ecf2ca703b612d752c0 return; } -@@ -818,13 +828,13 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -819,13 +829,13 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic // PacketUtils.ensureRunningOnSameThread(packet, this, this.player.getLevel()); // Paper - run this async // CraftBukkit start if (this.chatSpamTickCount.addAndGet(io.papermc.paper.configuration.GlobalConfiguration.get().spamLimiter.tabSpamIncrement) > io.papermc.paper.configuration.GlobalConfiguration.get().spamLimiter.tabSpamLimit && !this.server.getPlayerList().isOp(this.player.getGameProfile())) { // Paper start - split and make configurable @@ -209,7 +209,7 @@ index ef670cf38d3ddbeff0f2b87a41cbed695116f270..82ddc28c97bf8ecf2ca703b612d752c0 return; } // Paper end -@@ -977,7 +987,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -978,7 +988,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic // Paper start - validate pick item position if (!(packet.getSlot() >= 0 && packet.getSlot() < this.player.getInventory().items.size())) { ServerGamePacketListenerImpl.LOGGER.warn("{} tried to set an invalid carried item", this.player.getName().getString()); @@ -218,7 +218,7 @@ index ef670cf38d3ddbeff0f2b87a41cbed695116f270..82ddc28c97bf8ecf2ca703b612d752c0 return; } this.player.getInventory().pickSlot(packet.getSlot()); // Paper - Diff above if changed -@@ -1164,7 +1174,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -1165,7 +1175,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic int byteLength = testString.getBytes(java.nio.charset.StandardCharsets.UTF_8).length; if (byteLength > 256 * 4) { ServerGamePacketListenerImpl.LOGGER.warn(this.player.getScoreboardName() + " tried to send a book with with a page too large!"); @@ -227,7 +227,7 @@ index ef670cf38d3ddbeff0f2b87a41cbed695116f270..82ddc28c97bf8ecf2ca703b612d752c0 return; } byteTotal += byteLength; -@@ -1187,14 +1197,14 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -1188,14 +1198,14 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic if (byteTotal > byteAllowed) { ServerGamePacketListenerImpl.LOGGER.warn(this.player.getScoreboardName() + " tried to send too large of a book. Book Size: " + byteTotal + " - Allowed: "+ byteAllowed + " - Pages: " + pageList.size()); @@ -244,7 +244,7 @@ index ef670cf38d3ddbeff0f2b87a41cbed695116f270..82ddc28c97bf8ecf2ca703b612d752c0 return; } this.lastBookTick = MinecraftServer.currentTick; -@@ -1318,7 +1328,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -1319,7 +1329,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic public void handleMovePlayer(ServerboundMovePlayerPacket packet) { PacketUtils.ensureRunningOnSameThread(packet, this, this.player.getLevel()); if (ServerGamePacketListenerImpl.containsInvalidValues(packet.getX(0.0D), packet.getY(0.0D), packet.getZ(0.0D), packet.getYRot(0.0F), packet.getXRot(0.0F))) { @@ -253,7 +253,7 @@ index ef670cf38d3ddbeff0f2b87a41cbed695116f270..82ddc28c97bf8ecf2ca703b612d752c0 } else { ServerLevel worldserver = this.player.getLevel(); -@@ -1734,7 +1744,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -1735,7 +1745,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic this.dropCount++; if (this.dropCount >= 20) { ServerGamePacketListenerImpl.LOGGER.warn(this.player.getScoreboardName() + " dropped their items too quickly!"); @@ -262,7 +262,7 @@ index ef670cf38d3ddbeff0f2b87a41cbed695116f270..82ddc28c97bf8ecf2ca703b612d752c0 return; } } -@@ -1946,7 +1956,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -1947,7 +1957,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic PacketUtils.ensureRunningOnSameThread(packet, this, this.player.getLevel()); if (packet.getAction() == ServerboundResourcePackPacket.Action.DECLINED && this.server.isResourcePackRequired()) { ServerGamePacketListenerImpl.LOGGER.info("Disconnecting {} due to resource pack rejection", this.player.getName()); @@ -271,7 +271,7 @@ index ef670cf38d3ddbeff0f2b87a41cbed695116f270..82ddc28c97bf8ecf2ca703b612d752c0 } // Paper start PlayerResourcePackStatusEvent.Status packStatus = PlayerResourcePackStatusEvent.Status.values()[packet.action.ordinal()]; -@@ -2062,7 +2072,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -2063,7 +2073,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic this.player.resetLastActionTime(); } else { ServerGamePacketListenerImpl.LOGGER.warn("{} tried to set an invalid carried item", this.player.getName().getString()); @@ -280,7 +280,7 @@ index ef670cf38d3ddbeff0f2b87a41cbed695116f270..82ddc28c97bf8ecf2ca703b612d752c0 } } -@@ -2075,7 +2085,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -2076,7 +2086,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic } // CraftBukkit end if (ServerGamePacketListenerImpl.isChatMessageIllegal(packet.message())) { @@ -289,7 +289,7 @@ index ef670cf38d3ddbeff0f2b87a41cbed695116f270..82ddc28c97bf8ecf2ca703b612d752c0 } else { Optional optional = this.tryHandleChat(packet.message(), packet.timeStamp(), packet.lastSeenMessages()); -@@ -2109,7 +2119,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -2110,7 +2120,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic @Override public void handleChatCommand(ServerboundChatCommandPacket packet) { if (ServerGamePacketListenerImpl.isChatMessageIllegal(packet.command())) { @@ -298,7 +298,7 @@ index ef670cf38d3ddbeff0f2b87a41cbed695116f270..82ddc28c97bf8ecf2ca703b612d752c0 } else { Optional optional = this.tryHandleChat(packet.command(), packet.timeStamp(), packet.lastSeenMessages()); -@@ -2158,7 +2168,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -2165,7 +2175,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic private void handleMessageDecodeFailure(SignedMessageChain.DecodeException exception) { if (exception.shouldDisconnect()) { @@ -307,7 +307,7 @@ index ef670cf38d3ddbeff0f2b87a41cbed695116f270..82ddc28c97bf8ecf2ca703b612d752c0 } else { this.player.sendSystemMessage(exception.getComponent().copy().withStyle(ChatFormatting.RED)); } -@@ -2189,7 +2199,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -2196,7 +2206,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic private Optional tryHandleChat(String message, Instant timestamp, LastSeenMessages.Update acknowledgment) { if (!this.updateChatOrder(timestamp)) { ServerGamePacketListenerImpl.LOGGER.warn("{} sent out-of-order chat: '{}'", this.player.getName().getString(), message); @@ -316,7 +316,7 @@ index ef670cf38d3ddbeff0f2b87a41cbed695116f270..82ddc28c97bf8ecf2ca703b612d752c0 return Optional.empty(); } else { Optional optional = this.unpackAndApplyLastSeen(acknowledgment); -@@ -2212,7 +2222,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -2219,7 +2229,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic if (optional.isEmpty()) { ServerGamePacketListenerImpl.LOGGER.warn("Failed to validate message acknowledgements from {}", this.player.getName().getString()); @@ -325,7 +325,7 @@ index ef670cf38d3ddbeff0f2b87a41cbed695116f270..82ddc28c97bf8ecf2ca703b612d752c0 } return optional; -@@ -2435,7 +2445,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -2442,7 +2452,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic // this.chatSpamTickCount += 20; if (this.chatSpamTickCount.addAndGet(20) > 200 && !this.server.getPlayerList().isOp(this.player.getGameProfile())) { // CraftBukkit end @@ -334,7 +334,7 @@ index ef670cf38d3ddbeff0f2b87a41cbed695116f270..82ddc28c97bf8ecf2ca703b612d752c0 } } -@@ -2447,7 +2457,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -2454,7 +2464,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic synchronized (this.lastSeenMessages) { if (!this.lastSeenMessages.applyOffset(packet.offset())) { ServerGamePacketListenerImpl.LOGGER.warn("Failed to validate message acknowledgements from {}", this.player.getName().getString()); @@ -343,7 +343,7 @@ index ef670cf38d3ddbeff0f2b87a41cbed695116f270..82ddc28c97bf8ecf2ca703b612d752c0 } } -@@ -2590,7 +2600,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -2597,7 +2607,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic } if (i > 4096) { @@ -352,7 +352,7 @@ index ef670cf38d3ddbeff0f2b87a41cbed695116f270..82ddc28c97bf8ecf2ca703b612d752c0 } } -@@ -2636,7 +2646,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -2643,7 +2653,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic // Spigot Start if ( entity == this.player && !this.player.isSpectator() ) { @@ -361,7 +361,7 @@ index ef670cf38d3ddbeff0f2b87a41cbed695116f270..82ddc28c97bf8ecf2ca703b612d752c0 return; } // Spigot End -@@ -2735,7 +2745,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -2742,7 +2752,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic // CraftBukkit end } } else { @@ -370,7 +370,7 @@ index ef670cf38d3ddbeff0f2b87a41cbed695116f270..82ddc28c97bf8ecf2ca703b612d752c0 ServerGamePacketListenerImpl.LOGGER.warn("Player {} tried to attack an invalid entity", ServerGamePacketListenerImpl.this.player.getName().getString()); } } -@@ -3143,7 +3153,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -3150,7 +3160,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic // Paper start if (!org.bukkit.Bukkit.isPrimaryThread()) { if (recipeSpamPackets.addAndGet(io.papermc.paper.configuration.GlobalConfiguration.get().spamLimiter.recipeSpamIncrement) > io.papermc.paper.configuration.GlobalConfiguration.get().spamLimiter.recipeSpamLimit) { @@ -379,7 +379,7 @@ index ef670cf38d3ddbeff0f2b87a41cbed695116f270..82ddc28c97bf8ecf2ca703b612d752c0 return; } } -@@ -3351,7 +3361,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -3358,7 +3368,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic } else if (!this.isSingleplayerOwner()) { // Paper start - This needs to be handled on the main thread for plugins server.submit(() -> { @@ -388,7 +388,7 @@ index ef670cf38d3ddbeff0f2b87a41cbed695116f270..82ddc28c97bf8ecf2ca703b612d752c0 }); // Paper end } -@@ -3397,7 +3407,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -3404,7 +3414,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic } } catch (Exception ex) { ServerGamePacketListenerImpl.LOGGER.error("Couldn\'t register custom payload", ex); @@ -397,7 +397,7 @@ index ef670cf38d3ddbeff0f2b87a41cbed695116f270..82ddc28c97bf8ecf2ca703b612d752c0 } } else if (packet.identifier.equals(CUSTOM_UNREGISTER)) { try { -@@ -3407,7 +3417,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -3414,7 +3424,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic } } catch (Exception ex) { ServerGamePacketListenerImpl.LOGGER.error("Couldn\'t unregister custom payload", ex); @@ -406,7 +406,7 @@ index ef670cf38d3ddbeff0f2b87a41cbed695116f270..82ddc28c97bf8ecf2ca703b612d752c0 } } else { try { -@@ -3425,7 +3435,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -3432,7 +3442,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic this.cserver.getMessenger().dispatchIncomingMessage(this.player.getBukkitEntity(), packet.identifier.toString(), data); } catch (Exception ex) { ServerGamePacketListenerImpl.LOGGER.error("Couldn\'t dispatch custom payload", ex); @@ -415,7 +415,7 @@ index ef670cf38d3ddbeff0f2b87a41cbed695116f270..82ddc28c97bf8ecf2ca703b612d752c0 } } -@@ -3467,7 +3477,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -3474,7 +3484,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic if (!Objects.equals(profilepublickey_a, profilepublickey_a1)) { if (profilepublickey_a != null && profilepublickey_a1.expiresAt().isBefore(profilepublickey_a.expiresAt())) { @@ -424,7 +424,7 @@ index ef670cf38d3ddbeff0f2b87a41cbed695116f270..82ddc28c97bf8ecf2ca703b612d752c0 } else { try { SignatureValidator signaturevalidator = this.server.getServiceSignatureValidator(); -@@ -3475,7 +3485,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -3482,7 +3492,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic this.resetPlayerChatState(remotechatsession_a.validate(this.player.getGameProfile(), signaturevalidator, Duration.ZERO)); } catch (ProfilePublicKey.ValidationException profilepublickey_b) { ServerGamePacketListenerImpl.LOGGER.error("Failed to validate profile key: {}", profilepublickey_b.getMessage()); @@ -434,10 +434,10 @@ index ef670cf38d3ddbeff0f2b87a41cbed695116f270..82ddc28c97bf8ecf2ca703b612d752c0 } diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java -index 54ccfd45a4a8373a40e7153c569b654fe2110506..dae66865e84352527f5115e37586f729d32c55cd 100644 +index 8883a3a0b28377bf3290adfc0353d2e65c70b828..c3e0fa27c34132a99f6cc9c0eb7d9544a9873eed 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -669,7 +669,7 @@ public abstract class PlayerList { +@@ -671,7 +671,7 @@ public abstract class PlayerList { while (iterator.hasNext()) { entityplayer = (ServerPlayer) iterator.next(); this.save(entityplayer); // CraftBukkit - Force the player's inventory to be saved @@ -446,7 +446,7 @@ index 54ccfd45a4a8373a40e7153c569b654fe2110506..dae66865e84352527f5115e37586f729 } // Instead of kicking then returning, we need to store the kick reason -@@ -1305,8 +1305,8 @@ public abstract class PlayerList { +@@ -1307,8 +1307,8 @@ public abstract class PlayerList { // Paper end // CraftBukkit start - disconnect safely for (ServerPlayer player : this.players) { @@ -491,10 +491,10 @@ index a24e7a66d52eddbdad8db71cf5e45f1a458c389f..e1c13ac7b11fb0080435fc34502208c8 } } diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -index 66c61c0f59efe2c3f0ae2d07ef7f1dfcfd1e0e64..ba3a7ad955c44c1f89d03fd7e45a407d524e9105 100644 +index 05c7a359ee18612eeda9672afb362754ca776b2d..6c8649749b3e66d6ab473321be6c48a0ddebc9f0 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -@@ -604,7 +604,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -608,7 +608,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player { org.spigotmc.AsyncCatcher.catchOp("player kick"); // Spigot if (this.getHandle().connection == null) return; @@ -503,7 +503,7 @@ index 66c61c0f59efe2c3f0ae2d07ef7f1dfcfd1e0e64..ba3a7ad955c44c1f89d03fd7e45a407d } // Paper start -@@ -616,10 +616,15 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -620,10 +620,15 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @Override public void kick(final net.kyori.adventure.text.Component message) { diff --git a/patches/server/0637-Fix-dangerous-end-portal-logic.patch b/patches/server/0637-Fix-dangerous-end-portal-logic.patch index 9d577c8a5f..a61f1a1d44 100644 --- a/patches/server/0637-Fix-dangerous-end-portal-logic.patch +++ b/patches/server/0637-Fix-dangerous-end-portal-logic.patch @@ -11,10 +11,10 @@ Move the tick logic into the post tick, where portaling was designed to happen in the first place. diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index 4e629c474b41e6342b8dffa6a601667ea12b319a..79bf4320b04acdb3999dcd47f2b6ceef198e5923 100644 +index 4dc8a8fcffddfc6673d5c161be1224d822ad3dab..f646e2230dbf1dd6bfb1a43545d95a4d9895c3d6 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -510,6 +510,36 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -511,6 +511,36 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { return chunkMap.playerEntityTrackerTrackMaps[type.ordinal()].getObjectsInRange(MCUtil.getCoordinateKey(this)); } // Paper end - optimise entity tracking @@ -51,7 +51,7 @@ index 4e629c474b41e6342b8dffa6a601667ea12b319a..79bf4320b04acdb3999dcd47f2b6ceef public Entity(EntityType type, Level world) { this.id = Entity.ENTITY_COUNTER.incrementAndGet(); -@@ -2730,6 +2760,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -2731,6 +2761,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { } this.processPortalCooldown(); diff --git a/patches/server/0640-Line-Of-Sight-Changes.patch b/patches/server/0640-Line-Of-Sight-Changes.patch index 31f6bcb2af..d16cceff4b 100644 --- a/patches/server/0640-Line-Of-Sight-Changes.patch +++ b/patches/server/0640-Line-Of-Sight-Changes.patch @@ -5,7 +5,7 @@ Subject: [PATCH] Line Of Sight Changes diff --git a/src/main/java/net/minecraft/world/entity/LivingEntity.java b/src/main/java/net/minecraft/world/entity/LivingEntity.java -index 3613422aeb87b83d04fde7341a01d4994a0a3b07..2c4d6294e1c5a0baa76d20fa5d6f95a06e73152b 100644 +index a99130c736ab17442d708e44434bdb426a3fee91..5cbe700d5620164690ea4a596ec996b6906b473b 100644 --- a/src/main/java/net/minecraft/world/entity/LivingEntity.java +++ b/src/main/java/net/minecraft/world/entity/LivingEntity.java @@ -3506,7 +3506,8 @@ public abstract class LivingEntity extends Entity implements Attackable { @@ -19,10 +19,10 @@ index 3613422aeb87b83d04fde7341a01d4994a0a3b07..2c4d6294e1c5a0baa76d20fa5d6f95a0 } diff --git a/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java b/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java -index 2f35909b250584dd9def3c6e957d25ab33ca6e73..5cef05789bf04db1cc6c10bb79c7875c114f72b5 100644 +index f01c6f684da1438808f018fe9a814ecaceb49b2f..505ce1ae7df56be0e70faf359ae1e5ebcc06255e 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java -@@ -975,5 +975,16 @@ public abstract class CraftRegionAccessor implements RegionAccessor { +@@ -996,5 +996,16 @@ public abstract class CraftRegionAccessor implements RegionAccessor { public org.bukkit.NamespacedKey getKey() { return org.bukkit.craftbukkit.util.CraftNamespacedKey.fromMinecraft(this.getHandle().getLevel().dimension().location()); } @@ -40,7 +40,7 @@ index 2f35909b250584dd9def3c6e957d25ab33ca6e73..5cef05789bf04db1cc6c10bb79c7875c // Paper end } diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java -index d896d7089baa9c7975fc8785093e9ffd43beae39..0f6239cf279ca1a45dd9f48179cee8f66a05ef8d 100644 +index b38d72e921c4705cae72eb65113b36c87e4250fd..f217df2d3c7a53b72418fab63cef06dbc107fe0d 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java @@ -29,6 +29,9 @@ import net.minecraft.world.entity.projectile.ThrownEgg; diff --git a/patches/server/0641-add-per-world-spawn-limits.patch b/patches/server/0641-add-per-world-spawn-limits.patch index dfee9deab0..250b6a01a1 100644 --- a/patches/server/0641-add-per-world-spawn-limits.patch +++ b/patches/server/0641-add-per-world-spawn-limits.patch @@ -6,10 +6,10 @@ Subject: [PATCH] add per world spawn limits Taken from #2982. Credit to Chasewhip8 diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -index c28f873cbc3c6f9180f051cf6277f75866415474..39412e69ac3bc5ff15162741d7f418bd32196745 100644 +index 7faaeea9fed2360ca36c28b66eef76b2aa7464ee..eddd86de37290b15e367ae6b4dc4c4514b1157e0 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -@@ -210,6 +210,13 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -211,6 +211,13 @@ public class CraftWorld extends CraftRegionAccessor implements World { this.biomeProvider = biomeProvider; this.environment = env; diff --git a/patches/server/0643-Add-more-LimitedRegion-API.patch b/patches/server/0643-Add-more-LimitedRegion-API.patch index e9e7611f99..0701fb43d1 100644 --- a/patches/server/0643-Add-more-LimitedRegion-API.patch +++ b/patches/server/0643-Add-more-LimitedRegion-API.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Add more LimitedRegion API diff --git a/src/main/java/org/bukkit/craftbukkit/generator/CraftLimitedRegion.java b/src/main/java/org/bukkit/craftbukkit/generator/CraftLimitedRegion.java -index 992fc24a040c147596e6fe9f27936b4820ebc4b3..392701b0022e05d0fd03ee5836fd18f00502f028 100644 +index 10fb28aabf8c9f764cdd614edbeec4523f8ab431..0ea1586bab74983fca19dcc5415fbc7a044fe186 100644 --- a/src/main/java/org/bukkit/craftbukkit/generator/CraftLimitedRegion.java +++ b/src/main/java/org/bukkit/craftbukkit/generator/CraftLimitedRegion.java -@@ -226,4 +226,45 @@ public class CraftLimitedRegion extends CraftRegionAccessor implements LimitedRe +@@ -251,4 +251,45 @@ public class CraftLimitedRegion extends CraftRegionAccessor implements LimitedRe public void addEntityToWorld(net.minecraft.world.entity.Entity entity, CreatureSpawnEvent.SpawnReason reason) { this.entities.add(entity); } diff --git a/patches/server/0644-Fix-PlayerDropItemEvent-using-wrong-item.patch b/patches/server/0644-Fix-PlayerDropItemEvent-using-wrong-item.patch index 12e0fa613a..fb16371dda 100644 --- a/patches/server/0644-Fix-PlayerDropItemEvent-using-wrong-item.patch +++ b/patches/server/0644-Fix-PlayerDropItemEvent-using-wrong-item.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Fix PlayerDropItemEvent using wrong item diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java -index e4c6bff2a1e601266d889cc0532827d0c8885ece..d9cacc372e1d40e6b2b5d83c88a01121b7f3f101 100644 +index 47d2bf15871e50e46c0e5df725f2bbacfe12a869..4b4bb21149a102a8cbf46ee104417dadb49999df 100644 --- a/src/main/java/net/minecraft/server/level/ServerPlayer.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java -@@ -2221,7 +2221,7 @@ public class ServerPlayer extends Player { +@@ -2249,7 +2249,7 @@ public class ServerPlayer extends Player { if (retainOwnership) { if (!itemstack1.isEmpty()) { diff --git a/patches/server/0645-Missing-Entity-Behavior-API.patch b/patches/server/0645-Missing-Entity-Behavior-API.patch index b6c842141b..554fac3e32 100644 --- a/patches/server/0645-Missing-Entity-Behavior-API.patch +++ b/patches/server/0645-Missing-Entity-Behavior-API.patch @@ -357,10 +357,10 @@ index 36bab0afb7dff206f76779f1c1bc619ac306d4d7..db151bf624095014c99d78b4f6748d2c @Override protected EntityHitResult findHitEntity(Vec3 currentPosition, Vec3 nextPosition) { diff --git a/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java b/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java -index 5cef05789bf04db1cc6c10bb79c7875c114f72b5..a92d43c0c4793a594b3e17b5e03f7e944b781a55 100644 +index 505ce1ae7df56be0e70faf359ae1e5ebcc06255e..cc3a90a3337b7d59e4377a1e2448f17a23604e57 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java -@@ -811,14 +811,19 @@ public abstract class CraftRegionAccessor implements RegionAccessor { +@@ -832,14 +832,19 @@ public abstract class CraftRegionAccessor implements RegionAccessor { } else if (Phantom.class.isAssignableFrom(clazz)) { entity = net.minecraft.world.entity.EntityType.PHANTOM.create(world); } else if (Fish.class.isAssignableFrom(clazz)) { @@ -458,10 +458,10 @@ index 3b960a832df1fe496ea036962083f1ac507a7db7..8f25bb253c2b22e1964afeae705901e9 + // Paper end } diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftBee.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftBee.java -index 8ada3dfbe89c8b55d85c31c71e365af0cbf66d19..1ae8d6e819cd9d195e1bd31ccf55d2893ba00e2a 100644 +index 099c2422d03ebb6ee36f5c93f4cfad5acd2fdeeb..e222a6ab6afbc43a3d358a79855a818b0e481fdb 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftBee.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftBee.java -@@ -91,4 +91,42 @@ public class CraftBee extends CraftAnimals implements Bee { +@@ -92,4 +92,42 @@ public class CraftBee extends CraftAnimals implements Bee { public void setCannotEnterHiveTicks(int ticks) { this.getHandle().setStayOutOfHiveCountdown(ticks); } @@ -631,7 +631,7 @@ index 04976616da8c85b1278dad33ff05554aa74a6b33..75c7645fb5732c43d1da15181cf5c7ee + // Paper end } diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java -index 04bb6b608201f20eecfc5cb3a8367f58cebe1d2b..38165a364dfeca6d0fb35e7b3ada92d728ec295b 100644 +index 5fc33fcde4d60934f03b681d65aa6e7f2d0f6202..f5b199b3cdccbe7d8a3331555469c622c853fd03 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java @@ -227,10 +227,16 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity { @@ -960,10 +960,10 @@ index 3bdcc754a5afb6506178bd5c0d4f9c6e02bc24da..3cb4860fea30bfaf2147b4f29a34336b + // Paper end } diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftRaider.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftRaider.java -index b10bcbc19362f0f8596ebcf3f3e1060486cfc74f..e24eec79402843105a13de2bb8554260908057cc 100644 +index 2c1537889cacba666549c1595a4e1a07a28dff31..ad10ba1dbaf81e767441aa8e1babed1d3e654121 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftRaider.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftRaider.java -@@ -65,4 +65,16 @@ public abstract class CraftRaider extends CraftMonster implements Raider { +@@ -63,4 +63,16 @@ public abstract class CraftRaider extends CraftMonster implements Raider { public Sound getCelebrationSound() { return CraftSound.getBukkit(this.getHandle().getCelebrateSound()); } @@ -1099,10 +1099,10 @@ index ee84a90772381f7cfe864642c860880b827d25ea..4352af0a76ce4a4cd4afbea96f4851ef public CraftTropicalFish(CraftServer server, net.minecraft.world.entity.animal.TropicalFish entity) { super(server, entity); diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftVex.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftVex.java -index 2ba16e33dd21c3c72cb12244aa78c59bf53e76d1..634a5099fb6faea03615783f57e643ad0083fa30 100644 +index 50b07045cd17a7576a436c64662ad039d4aa2132..bcfca66c7b99b9d514fe850d6cc6abd7e36ccaf7 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftVex.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftVex.java -@@ -29,6 +29,26 @@ public class CraftVex extends CraftMonster implements Vex { +@@ -30,6 +30,26 @@ public class CraftVex extends CraftMonster implements Vex { public void setSummoner(org.bukkit.entity.Mob summoner) { getHandle().setOwner(summoner == null ? null : ((CraftMob) summoner).getHandle()); } @@ -1204,12 +1204,12 @@ index 08c55cb00c8ff3c39dd99c64227d5d60abee2a51..6ecdc4bf1f6b8f0363e667135ba46343 public void increaseAnger(Entity entity, int increase) { Preconditions.checkArgument(entity != null, "Entity cannot be null"); diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftWither.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftWither.java -index e92355fa2042c4cf15354a11b7058cacbe996f0d..4cf3a374c9ee7c7bcf82e778aa094eb4f8463595 100644 +index 8c32f70ec0defa5c67f2d02d13116e27de5de76d..dab37db550a33a18f02d2404a4d6f44db7d1322b 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftWither.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftWither.java -@@ -61,4 +61,31 @@ public class CraftWither extends CraftMonster implements Wither, com.destroystok - Entity target = this.getHandle().getLevel().getEntity(entityId); - return (target != null) ? (LivingEntity) target.getBukkitEntity() : null; +@@ -73,4 +73,31 @@ public class CraftWither extends CraftMonster implements Wither, com.destroystok + + this.getHandle().setInvulnerableTicks(ticks); } + + // Paper start diff --git a/patches/server/0646-Ensure-disconnect-for-book-edit-is-called-on-main.patch b/patches/server/0646-Ensure-disconnect-for-book-edit-is-called-on-main.patch index 80c103310e..57b24a35b3 100644 --- a/patches/server/0646-Ensure-disconnect-for-book-edit-is-called-on-main.patch +++ b/patches/server/0646-Ensure-disconnect-for-book-edit-is-called-on-main.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Ensure disconnect for book edit is called on main diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 82ddc28c97bf8ecf2ca703b612d752c0319a6b0f..d96f2cdc93ffcdb39b78d179423d85d7761cedf9 100644 +index 2663576ec20dbeda9ca131a57ea3cee02680e4be..caa8455611046ddd33d07cc61891bb632cbfdb5e 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -1204,7 +1204,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -1205,7 +1205,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic // Paper end // CraftBukkit start if (this.lastBookTick + 20 > MinecraftServer.currentTick) { diff --git a/patches/server/0647-Fix-return-value-of-Block-applyBoneMeal-always-being.patch b/patches/server/0647-Fix-return-value-of-Block-applyBoneMeal-always-being.patch index 3a42add191..d9f55c0ce8 100644 --- a/patches/server/0647-Fix-return-value-of-Block-applyBoneMeal-always-being.patch +++ b/patches/server/0647-Fix-return-value-of-Block-applyBoneMeal-always-being.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Fix return value of Block#applyBoneMeal always being false diff --git a/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java b/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java -index e8d96c1e5dde67436fba1bfc6585c3e4a5c1a63c..4cfefcd6dc1ccdc9ecc52c9965fef5a3e339f862 100644 +index 9e11a7967799c6f57e7461e22a3bb6f427af8418..0499699f0a211d83eb3353c00f63baf87147ee7b 100644 --- a/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java +++ b/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java -@@ -583,7 +583,7 @@ public class CraftBlock implements Block { +@@ -582,7 +582,7 @@ public class CraftBlock implements Block { } } diff --git a/patches/server/0650-Adds-PlayerArmSwingEvent.patch b/patches/server/0650-Adds-PlayerArmSwingEvent.patch index 0cc21e13f8..b60c9d8af4 100644 --- a/patches/server/0650-Adds-PlayerArmSwingEvent.patch +++ b/patches/server/0650-Adds-PlayerArmSwingEvent.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Adds PlayerArmSwingEvent diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index d96f2cdc93ffcdb39b78d179423d85d7761cedf9..d11d2dc10a8add75812f24234b8bf9c97fcb635c 100644 +index de3aff55fd3d72e350b97a5a59ff7707cade3660..da575295905ba67b6f8c44dc4a27fd16cc550c7b 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -2485,7 +2485,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -2492,7 +2492,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic } // Arm swing animation diff --git a/patches/server/0651-Fixes-kick-event-leave-message-not-being-sent.patch b/patches/server/0651-Fixes-kick-event-leave-message-not-being-sent.patch index a2f0c36508..0182db0014 100644 --- a/patches/server/0651-Fixes-kick-event-leave-message-not-being-sent.patch +++ b/patches/server/0651-Fixes-kick-event-leave-message-not-being-sent.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Fixes kick event leave message not being sent diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java -index d9cacc372e1d40e6b2b5d83c88a01121b7f3f101..72f9f443fb69603d986d41f0776e6b9b30228431 100644 +index 4b4bb21149a102a8cbf46ee104417dadb49999df..44cf1f81ed53f72b87530cee006e54014a2798bf 100644 --- a/src/main/java/net/minecraft/server/level/ServerPlayer.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java -@@ -268,7 +268,6 @@ public class ServerPlayer extends Player { +@@ -270,7 +270,6 @@ public class ServerPlayer extends Player { public boolean sentListPacket = false; public boolean supressTrackerForLogin = false; // Paper public Integer clientViewDistance; @@ -17,10 +17,10 @@ index d9cacc372e1d40e6b2b5d83c88a01121b7f3f101..72f9f443fb69603d986d41f0776e6b9b public boolean isRealPlayer; // Paper public double lastEntitySpawnRadiusSquared; // Paper - optimise isOutsideRange, this field is in blocks diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index d11d2dc10a8add75812f24234b8bf9c97fcb635c..7d257a0461739f0a4a59f9c17b237c44fde7c44d 100644 +index da9efc8be6bcaec4f0144a3c51896ce37b539f11..435006230d4fc81dc72c79e6110e91f33a687a77 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -513,7 +513,6 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -514,7 +514,6 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic // Do not kick the player return; } @@ -28,7 +28,7 @@ index d11d2dc10a8add75812f24234b8bf9c97fcb635c..7d257a0461739f0a4a59f9c17b237c44 // Send the possibly modified leave message final Component ichatbasecomponent = PaperAdventure.asVanilla(event.reason()); // Paper - Adventure // CraftBukkit end -@@ -522,7 +521,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -523,7 +522,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic this.connection.send(new ClientboundDisconnectPacket(ichatbasecomponent), PacketSendListener.thenRun(() -> { this.connection.disconnect(ichatbasecomponent); })); @@ -37,7 +37,7 @@ index d11d2dc10a8add75812f24234b8bf9c97fcb635c..7d257a0461739f0a4a59f9c17b237c44 this.connection.setReadOnly(); MinecraftServer minecraftserver = this.server; Connection networkmanager = this.connection; -@@ -1983,6 +1982,11 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -1984,6 +1983,11 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic @Override public void onDisconnect(Component reason) { @@ -49,7 +49,7 @@ index d11d2dc10a8add75812f24234b8bf9c97fcb635c..7d257a0461739f0a4a59f9c17b237c44 // CraftBukkit start - Rarely it would send a disconnect line twice if (this.processedDisconnect) { return; -@@ -2000,7 +2004,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -2001,7 +2005,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic this.player.disconnect(); // Paper start - Adventure @@ -59,10 +59,10 @@ index d11d2dc10a8add75812f24234b8bf9c97fcb635c..7d257a0461739f0a4a59f9c17b237c44 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 dae66865e84352527f5115e37586f729d32c55cd..5db5e6b59ff996012f5b2d546f54d1f3b7442ce0 100644 +index c3e0fa27c34132a99f6cc9c0eb7d9544a9873eed..0e314e2b85ed17bef7b9cc75573b0dc6c13b46b1 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -555,6 +555,11 @@ public abstract class PlayerList { +@@ -557,6 +557,11 @@ public abstract class PlayerList { } public net.kyori.adventure.text.Component remove(ServerPlayer entityplayer) { // Paper - return Component @@ -74,7 +74,7 @@ index dae66865e84352527f5115e37586f729d32c55cd..5db5e6b59ff996012f5b2d546f54d1f3 ServerLevel worldserver = entityplayer.getLevel(); entityplayer.awardStat(Stats.LEAVE_GAME); -@@ -565,7 +570,7 @@ public abstract class PlayerList { +@@ -567,7 +572,7 @@ public abstract class PlayerList { entityplayer.closeContainer(org.bukkit.event.inventory.InventoryCloseEvent.Reason.DISCONNECT); // Paper } diff --git a/patches/server/0654-Don-t-apply-cramming-damage-to-players.patch b/patches/server/0654-Don-t-apply-cramming-damage-to-players.patch index 6a895c4605..9754dbca44 100644 --- a/patches/server/0654-Don-t-apply-cramming-damage-to-players.patch +++ b/patches/server/0654-Don-t-apply-cramming-damage-to-players.patch @@ -11,7 +11,7 @@ It does not make a lot of sense to damage players if they get crammed, For those who really want it a config option is provided. diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java -index 72f9f443fb69603d986d41f0776e6b9b30228431..af8af6bb44b84c74553068b6cd64f4e3941d4ae1 100644 +index 44cf1f81ed53f72b87530cee006e54014a2798bf..a649d1baa727dd16cb8e786bdf510021e2d16d26 100644 --- a/src/main/java/net/minecraft/server/level/ServerPlayer.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java @@ -100,6 +100,7 @@ import net.minecraft.util.Mth; @@ -22,7 +22,7 @@ index 72f9f443fb69603d986d41f0776e6b9b30228431..af8af6bb44b84c74553068b6cd64f4e3 import net.minecraft.world.effect.MobEffectInstance; import net.minecraft.world.effect.MobEffects; import net.minecraft.world.entity.Entity; -@@ -1430,7 +1431,7 @@ public class ServerPlayer extends Player { +@@ -1432,7 +1433,7 @@ public class ServerPlayer extends Player { @Override public boolean isInvulnerableTo(DamageSource damageSource) { diff --git a/patches/server/0658-Fix-incosistency-issue-with-empty-map-items-in-CB.patch b/patches/server/0658-Fix-incosistency-issue-with-empty-map-items-in-CB.patch index 5ee54b974b..f7fd82f28b 100644 --- a/patches/server/0658-Fix-incosistency-issue-with-empty-map-items-in-CB.patch +++ b/patches/server/0658-Fix-incosistency-issue-with-empty-map-items-in-CB.patch @@ -18,10 +18,10 @@ index f883e1bc4150bc074f1d8363a95b4eae16f3828e..586852e347cfeb6e52d16e51b3f193e8 public static int createNewSavedData(Level world, int x, int z, int scale, boolean showIcons, boolean unlimitedTracking, ResourceKey dimension) { diff --git a/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaMap.java b/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaMap.java -index 6f16f12b4cb9b53878416f1cea532548c418f518..e802623e2ef5fb8c423429335ee7dbabc45a1b74 100644 +index 70b365afc40f11d4da3aea2b5d6b2467f517deac..a74ea06e3a190916527ab2c85d13f1e34c08d50a 100644 --- a/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaMap.java +++ b/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaMap.java -@@ -138,6 +138,7 @@ class CraftMetaMap extends CraftMetaItem implements MapMeta { +@@ -133,6 +133,7 @@ class CraftMetaMap extends CraftMetaItem implements MapMeta { @Override public int getMapId() { diff --git a/patches/server/0659-Add-System.out-err-catcher.patch b/patches/server/0659-Add-System.out-err-catcher.patch index 5523c05602..b62b0b372b 100644 --- a/patches/server/0659-Add-System.out-err-catcher.patch +++ b/patches/server/0659-Add-System.out-err-catcher.patch @@ -105,10 +105,10 @@ index 0000000000000000000000000000000000000000..a8e813ca89b033f061e695288b3383bd + } +} diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 8e07aadd4225df5a7f5ac95de6a91309ed036ffa..e90ddf2f2039a954971f23a6dc28d460ab6f18b2 100644 +index a963c1e6aaba4fd55f5462be89e9afe8b20f082a..8e8e0cc2f60c11ddd1ac2d232a698b3f4286426c 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -293,6 +293,7 @@ public final class CraftServer implements Server { +@@ -294,6 +294,7 @@ public final class CraftServer implements Server { public int reloadCount; private final io.papermc.paper.datapack.PaperDatapackManager datapackManager; // Paper public static Exception excessiveVelEx; // Paper - Velocity warnings diff --git a/patches/server/0662-Improve-boat-collision-performance.patch b/patches/server/0662-Improve-boat-collision-performance.patch index 3c0b853f1d..fa3f290859 100644 --- a/patches/server/0662-Improve-boat-collision-performance.patch +++ b/patches/server/0662-Improve-boat-collision-performance.patch @@ -17,7 +17,7 @@ index d5b37301d4e860c019105445001ed7a9a6f849bd..f4935f7fc3cbd6ba8f079def43bd7353 }; diff --git a/src/main/java/net/minecraft/world/entity/LivingEntity.java b/src/main/java/net/minecraft/world/entity/LivingEntity.java -index db69a26a019615df9d6b0f3ab8f3069d25445f07..f1cb4aa51edd1500b3ddd1f2457b905db8802900 100644 +index 2b40508750c2f70d1988f324f87e599fc62329f3..a7046e42c1935e9a4e529726072d9f88caaa703a 100644 --- a/src/main/java/net/minecraft/world/entity/LivingEntity.java +++ b/src/main/java/net/minecraft/world/entity/LivingEntity.java @@ -1334,7 +1334,7 @@ public abstract class LivingEntity extends Entity implements Attackable { @@ -54,10 +54,10 @@ index db69a26a019615df9d6b0f3ab8f3069d25445f07..f1cb4aa51edd1500b3ddd1f2457b905d } } diff --git a/src/main/java/net/minecraft/world/entity/vehicle/Boat.java b/src/main/java/net/minecraft/world/entity/vehicle/Boat.java -index 765ba5b9b34f31d9b9dbdf2e2bf46554aaf612d9..5095e47b4910167235afdd8f1a7e9c45124ecadb 100644 +index 8b562ca6cc92c31c764aebf05d511e347cff8a83..12e3209c5246ede89daaf8455fe70b4a517e12f6 100644 --- a/src/main/java/net/minecraft/world/entity/vehicle/Boat.java +++ b/src/main/java/net/minecraft/world/entity/vehicle/Boat.java -@@ -708,8 +708,8 @@ public class Boat extends Entity implements VariantHolder { +@@ -709,8 +709,8 @@ public class Boat extends Entity implements VariantHolder { this.invFriction = 0.05F; if (this.oldStatus == Boat.Status.IN_AIR && this.status != Boat.Status.IN_AIR && this.status != Boat.Status.ON_LAND) { this.waterLevel = this.getY(1.0D); diff --git a/patches/server/0663-Prevent-AFK-kick-while-watching-end-credits.patch b/patches/server/0663-Prevent-AFK-kick-while-watching-end-credits.patch index c118efca29..51f1f4e1fc 100644 --- a/patches/server/0663-Prevent-AFK-kick-while-watching-end-credits.patch +++ b/patches/server/0663-Prevent-AFK-kick-while-watching-end-credits.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Prevent AFK kick while watching end credits. diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 7d257a0461739f0a4a59f9c17b237c44fde7c44d..f0688aba315ddea393fea88fc82752d9b46fec6a 100644 +index 435006230d4fc81dc72c79e6110e91f33a687a77..adffa10ad47d1c2a9479ca91073a12e61538a608 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -430,7 +430,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -431,7 +431,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic --this.dropSpamTickCount; } diff --git a/patches/server/0665-Add-PlayerSetSpawnEvent.patch b/patches/server/0665-Add-PlayerSetSpawnEvent.patch index b61b927a28..a22382afb4 100644 --- a/patches/server/0665-Add-PlayerSetSpawnEvent.patch +++ b/patches/server/0665-Add-PlayerSetSpawnEvent.patch @@ -5,19 +5,21 @@ Subject: [PATCH] Add PlayerSetSpawnEvent diff --git a/src/main/java/net/minecraft/server/commands/SetSpawnCommand.java b/src/main/java/net/minecraft/server/commands/SetSpawnCommand.java -index 7679d6b8b1eb8e849ce7e63cf293598db7eb4588..b0ed00b95b273f0916cbade0e3bac47aa464d3fd 100644 +index 3072f513c22904f8066e0c37f345df4fdb451f8a..aa701e68ed81562861eba559e61e522b934d5851 100644 --- a/src/main/java/net/minecraft/server/commands/SetSpawnCommand.java +++ b/src/main/java/net/minecraft/server/commands/SetSpawnCommand.java -@@ -32,9 +32,21 @@ public class SetSpawnCommand { - private static int setSpawn(CommandSourceStack source, Collection targets, BlockPos pos, float angle) { - ResourceKey resourceKey = source.getLevel().dimension(); +@@ -38,11 +38,23 @@ public class SetSpawnCommand { + ResourceKey resourcekey = source.getLevel().dimension(); + Iterator iterator = targets.iterator(); + final Collection actualTargets = new java.util.ArrayList<>(); // Paper - for(ServerPlayer serverPlayer : targets) { -- serverPlayer.setRespawnPosition(resourceKey, pos, angle, true, false); + while (iterator.hasNext()) { + ServerPlayer entityplayer = (ServerPlayer) iterator.next(); + +- entityplayer.setRespawnPosition(resourcekey, pos, angle, true, false, org.bukkit.event.player.PlayerSpawnChangeEvent.Cause.COMMAND); // CraftBukkit + // Paper start - PlayerSetSpawnEvent -+ if (serverPlayer.setRespawnPosition(resourceKey, pos, angle, true, false, com.destroystokyo.paper.event.player.PlayerSetSpawnEvent.Cause.COMMAND)) { -+ actualTargets.add(serverPlayer); ++ if (entityplayer.setRespawnPosition(resourcekey, pos, angle, true, false, com.destroystokyo.paper.event.player.PlayerSetSpawnEvent.Cause.COMMAND)) { ++ actualTargets.add(entityplayer); + } + // Paper end } @@ -29,58 +31,106 @@ index 7679d6b8b1eb8e849ce7e63cf293598db7eb4588..b0ed00b95b273f0916cbade0e3bac47a + } + // Paper end - String string = resourceKey.location().toString(); - if (targets.size() == 1) { + String s = resourcekey.location().toString(); + diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java -index af8af6bb44b84c74553068b6cd64f4e3941d4ae1..bc6ddf50bcd2f38be8c8fa064b49a7363643b9bd 100644 +index a649d1baa727dd16cb8e786bdf510021e2d16d26..cdf85898d6ca9f1159b175dbc2760522abd8eb95 100644 --- a/src/main/java/net/minecraft/server/level/ServerPlayer.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java -@@ -1307,7 +1307,7 @@ public class ServerPlayer extends Player { +@@ -1309,7 +1309,7 @@ public class ServerPlayer extends Player { } else if (this.bedBlocked(blockposition, enumdirection)) { return Either.left(Player.BedSleepingProblem.OBSTRUCTED); } else { -- this.setRespawnPosition(this.level.dimension(), blockposition, this.getYRot(), false, true); +- this.setRespawnPosition(this.level.dimension(), blockposition, this.getYRot(), false, true, PlayerSpawnChangeEvent.Cause.BED); // CraftBukkit + this.setRespawnPosition(this.level.dimension(), blockposition, this.getYRot(), false, true, com.destroystokyo.paper.event.player.PlayerSetSpawnEvent.Cause.BED); // Paper - PlayerSetSpawnEvent if (this.level.isDay()) { return Either.left(Player.BedSleepingProblem.NOT_POSSIBLE_NOW); } else { -@@ -2149,12 +2149,33 @@ public class ServerPlayer extends Player { +@@ -2151,44 +2151,50 @@ public class ServerPlayer extends Player { return this.respawnForced; } + @Deprecated // Paper public void setRespawnPosition(ResourceKey dimension, @Nullable BlockPos pos, float angle, boolean forced, boolean sendMessage) { +- // CraftBukkit start +- this.setRespawnPosition(dimension, pos, angle, forced, sendMessage, PlayerSpawnChangeEvent.Cause.UNKNOWN); +- } +- +- public void setRespawnPosition(ResourceKey resourcekey, @Nullable BlockPos blockposition, float f, boolean flag, boolean flag1, PlayerSpawnChangeEvent.Cause cause) { +- ServerLevel newWorld = this.server.getLevel(resourcekey); +- Location newSpawn = (blockposition != null) ? CraftLocation.toBukkit(blockposition, newWorld.getWorld(), f, 0) : null; +- +- PlayerSpawnChangeEvent event = new PlayerSpawnChangeEvent(this.getBukkitEntity(), newSpawn, flag, cause); +- Bukkit.getServer().getPluginManager().callEvent(event); +- if (event.isCancelled()) { +- return; +- } +- newSpawn = event.getNewSpawn(); +- flag = event.isForced(); +- +- if (newSpawn != null) { +- resourcekey = ((CraftWorld) newSpawn.getWorld()).getHandle().dimension(); +- blockposition = BlockPos.containing(newSpawn.getX(), newSpawn.getY(), newSpawn.getZ()); +- f = newSpawn.getYaw(); +- } else { +- resourcekey = Level.OVERWORLD; +- blockposition = null; +- f = 0.0F; + // Paper start + this.setRespawnPosition(dimension, pos, angle, forced, sendMessage, com.destroystokyo.paper.event.player.PlayerSetSpawnEvent.Cause.UNKNOWN); + } ++ @Deprecated ++ public boolean setRespawnPosition(ResourceKey dimension, @Nullable BlockPos pos, float angle, boolean forced, boolean sendMessage, PlayerSpawnChangeEvent.Cause cause) { ++ return this.setRespawnPosition(dimension, pos, angle, forced, sendMessage, cause == PlayerSpawnChangeEvent.Cause.RESET ? ++ com.destroystokyo.paper.event.player.PlayerSetSpawnEvent.Cause.PLAYER_RESPAWN : com.destroystokyo.paper.event.player.PlayerSetSpawnEvent.Cause.valueOf(cause.name())); ++ } + public boolean setRespawnPosition(ResourceKey dimension, @Nullable BlockPos pos, float angle, boolean forced, boolean sendMessage, com.destroystokyo.paper.event.player.PlayerSetSpawnEvent.Cause cause) { + Location spawnLoc = null; + boolean willNotify = false; - if (pos != null) { - boolean flag2 = pos.equals(this.respawnPosition) && dimension.equals(this.respawnDimension); ++ if (pos != null) { ++ boolean flag2 = pos.equals(this.respawnPosition) && dimension.equals(this.respawnDimension); + spawnLoc = io.papermc.paper.util.MCUtil.toLocation(this.getServer().getLevel(dimension), pos); + spawnLoc.setYaw(angle); + willNotify = sendMessage && !flag2; + } -+ com.destroystokyo.paper.event.player.PlayerSetSpawnEvent event = new com.destroystokyo.paper.event.player.PlayerSetSpawnEvent(this.getBukkitEntity(), cause, spawnLoc, forced, willNotify, willNotify ? net.kyori.adventure.text.Component.translatable("block.minecraft.set_spawn") : null); ++ ++ PlayerSpawnChangeEvent dumbEvent = new PlayerSpawnChangeEvent(this.getBukkitEntity(), spawnLoc, forced, ++ cause == com.destroystokyo.paper.event.player.PlayerSetSpawnEvent.Cause.PLAYER_RESPAWN ? PlayerSpawnChangeEvent.Cause.RESET : PlayerSpawnChangeEvent.Cause.valueOf(cause.name())); ++ dumbEvent.callEvent(); ++ ++ com.destroystokyo.paper.event.player.PlayerSetSpawnEvent event = new com.destroystokyo.paper.event.player.PlayerSetSpawnEvent(this.getBukkitEntity(), cause, dumbEvent.getNewSpawn(), dumbEvent.isForced(), willNotify, willNotify ? net.kyori.adventure.text.Component.translatable("block.minecraft.set_spawn") : null); ++ event.setCancelled(dumbEvent.isCancelled()); + if (!event.callEvent()) { + return false; -+ } + } +- // CraftBukkit end +- if (blockposition != null) { +- boolean flag2 = blockposition.equals(this.respawnPosition) && resourcekey.equals(this.respawnDimension); + if (event.getLocation() != null) { + dimension = event.getLocation().getWorld() != null ? ((CraftWorld) event.getLocation().getWorld()).getHandle().dimension() : dimension; + pos = io.papermc.paper.util.MCUtil.toBlockPosition(event.getLocation()); -+ angle = (float) event.getLocation().getYaw(); ++ angle = event.getLocation().getYaw(); + forced = event.isForced(); + // Paper end -- if (sendMessage && !flag2) { +- if (flag1 && !flag2) { - this.sendSystemMessage(Component.translatable("block.minecraft.set_spawn")); + if (event.willNotifyPlayer() && event.getNotification() != null) { // Paper + this.sendSystemMessage(PaperAdventure.asVanilla(event.getNotification())); // Paper } - this.respawnPosition = pos; -@@ -2168,6 +2189,7 @@ public class ServerPlayer extends Player { +- this.respawnPosition = blockposition; +- this.respawnDimension = resourcekey; +- this.respawnAngle = f; +- this.respawnForced = flag; ++ this.respawnPosition = pos; ++ this.respawnDimension = dimension; ++ this.respawnAngle = angle; ++ this.respawnForced = forced; + } else { + this.respawnPosition = null; + this.respawnDimension = Level.OVERWORLD; +@@ -2196,6 +2202,7 @@ public class ServerPlayer extends Player { this.respawnForced = false; } @@ -89,36 +139,29 @@ index af8af6bb44b84c74553068b6cd64f4e3941d4ae1..bc6ddf50bcd2f38be8c8fa064b49a736 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 5db5e6b59ff996012f5b2d546f54d1f3b7442ce0..79aac02a4c702797c72970a40a17bdf4115fa644 100644 +index 0e314e2b85ed17bef7b9cc75573b0dc6c13b46b1..9386d0836ed6dad232aa24219bdbbaeafffc49c0 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -845,13 +845,13 @@ public abstract class PlayerList { - f1 = (float) Mth.wrapDegrees(Mth.atan2(vec3d1.z, vec3d1.x) * 57.2957763671875D - 90.0D); - } - -- entityplayer1.setRespawnPosition(worldserver1.dimension(), blockposition, f, flag1, false); -+ entityplayer1.setRespawnPosition(worldserver1.dimension(), blockposition, f, flag1, false, com.destroystokyo.paper.event.player.PlayerSetSpawnEvent.Cause.PLAYER_RESPAWN); // Paper - PlayerSetSpawnEvent - flag2 = !flag && flag3; - isBedSpawn = true; - location = new Location(worldserver1.getWorld(), vec3d.x, vec3d.y, vec3d.z, f1, 0.0F); +@@ -853,7 +853,7 @@ public abstract class PlayerList { + location = CraftLocation.toBukkit(vec3d, worldserver1.getWorld(), f1, 0.0F); } else if (blockposition != null) { entityplayer1.connection.send(new ClientboundGameEventPacket(ClientboundGameEventPacket.NO_RESPAWN_BLOCK_AVAILABLE, 0.0F)); -- entityplayer1.setRespawnPosition(null, null, 0f, false, false); // CraftBukkit - SPIGOT-5988: Clear respawn location when obstructed +- entityplayer1.setRespawnPosition(null, null, 0f, false, false, PlayerSpawnChangeEvent.Cause.RESET); // CraftBukkit - SPIGOT-5988: Clear respawn location when obstructed + entityplayer1.setRespawnPosition(null, null, 0f, false, false, com.destroystokyo.paper.event.player.PlayerSetSpawnEvent.Cause.PLAYER_RESPAWN); // CraftBukkit - SPIGOT-5988: Clear respawn location when obstructed // Paper - PlayerSetSpawnEvent } } diff --git a/src/main/java/net/minecraft/world/level/block/RespawnAnchorBlock.java b/src/main/java/net/minecraft/world/level/block/RespawnAnchorBlock.java -index a64cd3b54840af9a9c946b3e4e4f91d1c5f4bc97..16f23ecffa52925904d585f3fed76aa61bac5f9d 100644 +index 1a27b7faa22e6b3dc5fce329ed06425de56c4315..b9903c29bdea8d1e3b6fce0e97be6bd9493cfdf4 100644 --- a/src/main/java/net/minecraft/world/level/block/RespawnAnchorBlock.java +++ b/src/main/java/net/minecraft/world/level/block/RespawnAnchorBlock.java -@@ -73,9 +73,14 @@ public class RespawnAnchorBlock extends Block { - if (!world.isClientSide) { - ServerPlayer serverPlayer = (ServerPlayer)player; - if (serverPlayer.getRespawnDimension() != world.dimension() || !pos.equals(serverPlayer.getRespawnPosition())) { -- serverPlayer.setRespawnPosition(world.dimension(), pos, 0.0F, false, true); -+ if (serverPlayer.setRespawnPosition(world.dimension(), pos, 0.0F, false, true, com.destroystokyo.paper.event.player.PlayerSetSpawnEvent.Cause.RESPAWN_ANCHOR)) { // Paper - PlayerSetSpawnEvent - world.playSound((Player)null, (double)pos.getX() + 0.5D, (double)pos.getY() + 0.5D, (double)pos.getZ() + 0.5D, SoundEvents.RESPAWN_ANCHOR_SET_SPAWN, SoundSource.BLOCKS, 1.0F, 1.0F); +@@ -80,9 +80,14 @@ public class RespawnAnchorBlock extends Block { + ServerPlayer entityplayer = (ServerPlayer) player; + + if (entityplayer.getRespawnDimension() != world.dimension() || !pos.equals(entityplayer.getRespawnPosition())) { +- entityplayer.setRespawnPosition(world.dimension(), pos, 0.0F, false, true, org.bukkit.event.player.PlayerSpawnChangeEvent.Cause.RESPAWN_ANCHOR); // CraftBukkit ++ if (entityplayer.setRespawnPosition(world.dimension(), pos, 0.0F, false, true, com.destroystokyo.paper.event.player.PlayerSetSpawnEvent.Cause.RESPAWN_ANCHOR)) { // Paper - PlayerSetSpawnEvent + world.playSound((Player) null, (double) pos.getX() + 0.5D, (double) pos.getY() + 0.5D, (double) pos.getZ() + 0.5D, SoundEvents.RESPAWN_ANCHOR_SET_SPAWN, SoundSource.BLOCKS, 1.0F, 1.0F); return InteractionResult.SUCCESS; + // Paper start - handle failed set spawn + } else { @@ -129,18 +172,18 @@ index a64cd3b54840af9a9c946b3e4e4f91d1c5f4bc97..16f23ecffa52925904d585f3fed76aa6 } diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -index ba3a7ad955c44c1f89d03fd7e45a407d524e9105..855b20e198983470b83ebbb38ebe5cba580cecd6 100644 +index 6c8649749b3e66d6ab473321be6c48a0ddebc9f0..e826a9e405c0ea985f8a742f4bc81b38c9d98bba 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -@@ -1372,9 +1372,9 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -1370,9 +1370,9 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @Override public void setBedSpawnLocation(Location location, boolean override) { if (location == null) { -- this.getHandle().setRespawnPosition(null, null, 0.0F, override, false); +- this.getHandle().setRespawnPosition(null, null, 0.0F, override, false, PlayerSpawnChangeEvent.Cause.PLUGIN); + this.getHandle().setRespawnPosition(null, null, 0.0F, override, false, com.destroystokyo.paper.event.player.PlayerSetSpawnEvent.Cause.PLUGIN); // Paper - PlayerSetSpawnEvent } else { -- this.getHandle().setRespawnPosition(((CraftWorld) location.getWorld()).getHandle().dimension(), new BlockPos(location.getBlockX(), location.getBlockY(), location.getBlockZ()), location.getYaw(), override, false); -+ this.getHandle().setRespawnPosition(((CraftWorld) location.getWorld()).getHandle().dimension(), new BlockPos(location.getBlockX(), location.getBlockY(), location.getBlockZ()), location.getYaw(), override, false, com.destroystokyo.paper.event.player.PlayerSetSpawnEvent.Cause.PLUGIN); // Paper - PlayerSetSpawnEvent +- this.getHandle().setRespawnPosition(((CraftWorld) location.getWorld()).getHandle().dimension(), CraftLocation.toBlockPosition(location), location.getYaw(), override, false, PlayerSpawnChangeEvent.Cause.PLUGIN); ++ this.getHandle().setRespawnPosition(((CraftWorld) location.getWorld()).getHandle().dimension(), CraftLocation.toBlockPosition(location), location.getYaw(), override, false, com.destroystokyo.paper.event.player.PlayerSetSpawnEvent.Cause.PLUGIN); // Paper - PlayerSetSpawnEvent } } diff --git a/patches/server/0670-Optimize-indirect-passenger-iteration.patch b/patches/server/0670-Optimize-indirect-passenger-iteration.patch index 991da3bafd..a68e70596f 100644 --- a/patches/server/0670-Optimize-indirect-passenger-iteration.patch +++ b/patches/server/0670-Optimize-indirect-passenger-iteration.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Optimize indirect passenger iteration diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index a0cc38632f387d9c789704040b76181220dd20ee..d55528a8b2e5939942582fd2d40a786ba64af7ac 100644 +index f646e2230dbf1dd6bfb1a43545d95a4d9895c3d6..d69352cc86f1a40bf696e30f11a3a84fac3b20c5 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -3764,20 +3764,34 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -3765,20 +3765,34 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { } private Stream getIndirectPassengersStream() { @@ -43,7 +43,7 @@ index a0cc38632f387d9c789704040b76181220dd20ee..d55528a8b2e5939942582fd2d40a786b return () -> { return this.getIndirectPassengersStream().iterator(); }; -@@ -3794,6 +3808,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -3795,6 +3809,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { // Paper end - rewrite chunk system public boolean hasExactlyOnePlayerPassenger() { diff --git a/patches/server/0673-Clear-bucket-NBT-after-dispense.patch b/patches/server/0673-Clear-bucket-NBT-after-dispense.patch index 16d0a6b785..d729313893 100644 --- a/patches/server/0673-Clear-bucket-NBT-after-dispense.patch +++ b/patches/server/0673-Clear-bucket-NBT-after-dispense.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Clear bucket NBT after dispense diff --git a/src/main/java/net/minecraft/core/dispenser/DispenseItemBehavior.java b/src/main/java/net/minecraft/core/dispenser/DispenseItemBehavior.java -index 429b9729188fe340b62a3305e6436fabbb1a7caf..1023f91b6a23fc974ba709ec09834d9faae8003a 100644 +index abd20f9495c315e73c1eb6572b8fc47db27450d7..9b56f742443ad98994acc34630f1cef75a00ca8a 100644 --- a/src/main/java/net/minecraft/core/dispenser/DispenseItemBehavior.java +++ b/src/main/java/net/minecraft/core/dispenser/DispenseItemBehavior.java -@@ -651,8 +651,7 @@ public interface DispenseItemBehavior { +@@ -652,8 +652,7 @@ public interface DispenseItemBehavior { Item item = Items.BUCKET; stack.shrink(1); if (stack.isEmpty()) { diff --git a/patches/server/0674-Change-EnderEye-target-without-changing-other-things.patch b/patches/server/0674-Change-EnderEye-target-without-changing-other-things.patch index 578dfb3d5e..1ed1548ad8 100644 --- a/patches/server/0674-Change-EnderEye-target-without-changing-other-things.patch +++ b/patches/server/0674-Change-EnderEye-target-without-changing-other-things.patch @@ -32,7 +32,7 @@ index f1582be22ffdd916eaab8998e3f367f2aac29d51..855e85e8d0d1f15304b0a42b46ef8453 @Override diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftEnderSignal.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftEnderSignal.java -index 18bd4b49a00f8223319ff39ba9fc83d0472dcb4f..86a5b59c2987a4faa5d29eebd978b4fb0b6cd424 100644 +index e45c1bfb1b8e0cd8f7b9ab5b655d33dd4da1b151..e3688e941d9b63b5319faf9370b8f75e0e5828ae 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftEnderSignal.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftEnderSignal.java @@ -38,8 +38,15 @@ public class CraftEnderSignal extends CraftEntity implements EnderSignal { @@ -47,8 +47,8 @@ index 18bd4b49a00f8223319ff39ba9fc83d0472dcb4f..86a5b59c2987a4faa5d29eebd978b4fb + public void setTargetLocation(Location location, boolean update) { + // Paper end Preconditions.checkArgument(getWorld().equals(location.getWorld()), "Cannot target EnderSignal across worlds"); -- this.getHandle().signalTo(BlockPos.containing(location.getX(), location.getY(), location.getZ())); -+ this.getHandle().signalTo(BlockPos.containing(location.getX(), location.getY(), location.getZ()), update); // Paper +- this.getHandle().signalTo(CraftLocation.toBlockPosition(location)); ++ this.getHandle().signalTo(CraftLocation.toBlockPosition(location), update); // Paper } @Override diff --git a/patches/server/0679-Add-back-EntityPortalExitEvent.patch b/patches/server/0679-Add-back-EntityPortalExitEvent.patch index 7038afc090..0f789c0462 100644 --- a/patches/server/0679-Add-back-EntityPortalExitEvent.patch +++ b/patches/server/0679-Add-back-EntityPortalExitEvent.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Add back EntityPortalExitEvent diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index 1105aa0293df750e70627efe951fd8604bde3e1b..de50f1aa6b7cebf877e18bc3e2ae3ba707edcd4c 100644 +index d69352cc86f1a40bf696e30f11a3a84fac3b20c5..d2f93f6cf5ff5a0ee5de18d4e593c1423e191d14 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -3216,6 +3216,23 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -3217,6 +3217,23 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { } else { // CraftBukkit start worldserver = shapedetectorshape.world; @@ -32,7 +32,7 @@ index 1105aa0293df750e70627efe951fd8604bde3e1b..de50f1aa6b7cebf877e18bc3e2ae3ba7 if (worldserver == this.level) { // SPIGOT-6782: Just move the entity if a plugin changed the world to the one the entity is already in this.moveTo(shapedetectorshape.pos.x, shapedetectorshape.pos.y, shapedetectorshape.pos.z, shapedetectorshape.yRot, shapedetectorshape.xRot); -@@ -3235,8 +3252,8 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -3236,8 +3253,8 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { if (entity != null) { entity.restoreFrom(this); diff --git a/patches/server/0680-Add-methods-to-find-targets-for-lightning-strikes.patch b/patches/server/0680-Add-methods-to-find-targets-for-lightning-strikes.patch index 1b04de8c43..c5471d12cc 100644 --- a/patches/server/0680-Add-methods-to-find-targets-for-lightning-strikes.patch +++ b/patches/server/0680-Add-methods-to-find-targets-for-lightning-strikes.patch @@ -31,10 +31,10 @@ index 16b73f0498936a8413f6adedd7f92bab07a4a108..f12d844d422ca4175d4cb2b8e3112b59 blockposition1 = blockposition1.above(2); } diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -index 39412e69ac3bc5ff15162741d7f418bd32196745..cf0892b4d4e5d3759ce743de9a0e36bb8924c7cd 100644 +index bf494076f310fb55e42df92acc556db30b8e4808..60ad39ba1cde4d4d1231f43902af4441a944556f 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -@@ -695,6 +695,23 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -691,6 +691,23 @@ public class CraftWorld extends CraftRegionAccessor implements World { return (LightningStrike) lightning.getBukkitEntity(); } diff --git a/patches/server/0685-Add-critical-damage-API.patch b/patches/server/0685-Add-critical-damage-API.patch index bc2c94d4c5..84d754b4d3 100644 --- a/patches/server/0685-Add-critical-damage-API.patch +++ b/patches/server/0685-Add-critical-damage-API.patch @@ -71,10 +71,10 @@ index 6486fa86e4bf3c90c09c0425d825bab568a68757..8257563afc3fe04c9e821da363b1f3f6 int k = entity.getRemainingFireTicks(); diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java -index c00b2460f40c5c806e88645af63dfeb6f89ddd00..d2c0461bcc8e4c08bf375f76fad0c10086c40fd4 100644 +index 0e8029a9beeb8bee245f1c94c8ee596ec0131177..4c957ccae26fcad437234051481e2a1824d17f76 100644 --- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java +++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java -@@ -986,7 +986,7 @@ public class CraftEventFactory { +@@ -988,7 +988,7 @@ public class CraftEventFactory { } else { damageCause = DamageCause.ENTITY_EXPLOSION; } @@ -83,7 +83,7 @@ index c00b2460f40c5c806e88645af63dfeb6f89ddd00..d2c0461bcc8e4c08bf375f76fad0c100 } event.setCancelled(cancelled); -@@ -1018,7 +1018,7 @@ public class CraftEventFactory { +@@ -1020,7 +1020,7 @@ public class CraftEventFactory { cause = DamageCause.SONIC_BOOM; } @@ -92,7 +92,7 @@ index c00b2460f40c5c806e88645af63dfeb6f89ddd00..d2c0461bcc8e4c08bf375f76fad0c100 } else if (source.is(DamageTypes.OUT_OF_WORLD)) { EntityDamageEvent event = new EntityDamageByBlockEvent(null, entity.getBukkitEntity(), DamageCause.VOID, modifiers, modifierFunctions); event.setCancelled(cancelled); -@@ -1088,7 +1088,7 @@ public class CraftEventFactory { +@@ -1090,7 +1090,7 @@ public class CraftEventFactory { } else { throw new IllegalStateException(String.format("Unhandled damage of %s by %s from %s", entity, damager.getHandle(), source.getMsgId())); } @@ -101,7 +101,7 @@ index c00b2460f40c5c806e88645af63dfeb6f89ddd00..d2c0461bcc8e4c08bf375f76fad0c100 event.setCancelled(cancelled); CraftEventFactory.callEvent(event); if (!event.isCancelled()) { -@@ -1133,20 +1133,28 @@ public class CraftEventFactory { +@@ -1135,20 +1135,28 @@ public class CraftEventFactory { } if (cause != null) { diff --git a/patches/server/0687-Add-isCollidable-methods-to-various-places.patch b/patches/server/0687-Add-isCollidable-methods-to-various-places.patch index 06975f7deb..46a25cd714 100644 --- a/patches/server/0687-Add-isCollidable-methods-to-various-places.patch +++ b/patches/server/0687-Add-isCollidable-methods-to-various-places.patch @@ -7,10 +7,10 @@ Subject: [PATCH] Add isCollidable methods to various places public net.minecraft.world.level.block.state.BlockBehaviour hasCollision diff --git a/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java b/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java -index 4cfefcd6dc1ccdc9ecc52c9965fef5a3e339f862..5343ae3cdda55d7e0b41747c7eccb52e6828f6c9 100644 +index 0499699f0a211d83eb3353c00f63baf87147ee7b..84911c7c6d038aadd3d84ac4797feaa91a556c3e 100644 --- a/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java +++ b/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java -@@ -482,6 +482,11 @@ public class CraftBlock implements Block { +@@ -481,6 +481,11 @@ public class CraftBlock implements Block { public boolean isSolid() { return getNMS().getMaterial().blocksMotion(); } @@ -23,10 +23,10 @@ index 4cfefcd6dc1ccdc9ecc52c9965fef5a3e339f862..5343ae3cdda55d7e0b41747c7eccb52e @Override diff --git a/src/main/java/org/bukkit/craftbukkit/block/CraftBlockState.java b/src/main/java/org/bukkit/craftbukkit/block/CraftBlockState.java -index 7b9e943b391c061782fccd2b8d705ceec8db50fe..966ac60daebb7bb211ab8096fc0c5f33db67320a 100644 +index 9068557ac50cfb26e7e3ec4ac64bac583baa582e..3e1d36a8c65e6567ac3b78903a25d5828ab74ea5 100644 --- a/src/main/java/org/bukkit/craftbukkit/block/CraftBlockState.java +++ b/src/main/java/org/bukkit/craftbukkit/block/CraftBlockState.java -@@ -324,4 +324,11 @@ public class CraftBlockState implements BlockState { +@@ -325,4 +325,11 @@ public class CraftBlockState implements BlockState { throw new IllegalStateException("The blockState must be placed to call this method"); } } diff --git a/patches/server/0690-Add-Raw-Byte-Entity-Serialization.patch b/patches/server/0690-Add-Raw-Byte-Entity-Serialization.patch index 45d3795391..243e1a51a8 100644 --- a/patches/server/0690-Add-Raw-Byte-Entity-Serialization.patch +++ b/patches/server/0690-Add-Raw-Byte-Entity-Serialization.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Add Raw Byte Entity Serialization diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index de50f1aa6b7cebf877e18bc3e2ae3ba707edcd4c..3a388ead677be73b0ae4425a05a45cd34e95d586 100644 +index d2f93f6cf5ff5a0ee5de18d4e593c1423e191d14..c79f7de53d8d61044a756b2a973f71bb5af74bfc 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -2018,6 +2018,15 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -2019,6 +2019,15 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { } } @@ -25,7 +25,7 @@ index de50f1aa6b7cebf877e18bc3e2ae3ba707edcd4c..3a388ead677be73b0ae4425a05a45cd3 return this.isPassenger() ? false : this.saveAsPassenger(nbt); } diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java -index 38165a364dfeca6d0fb35e7b3ada92d728ec295b..0c65652866de257d2a9019f910506a6f01757422 100644 +index f5b199b3cdccbe7d8a3331555469c622c853fd03..b1a578f23a21303f79f443107e7a9bea903310f4 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java @@ -1367,5 +1367,15 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity { diff --git a/patches/server/0692-Do-not-run-close-logic-for-inventories-on-chunk-unlo.patch b/patches/server/0692-Do-not-run-close-logic-for-inventories-on-chunk-unlo.patch index 4290025732..28c6089581 100644 --- a/patches/server/0692-Do-not-run-close-logic-for-inventories-on-chunk-unlo.patch +++ b/patches/server/0692-Do-not-run-close-logic-for-inventories-on-chunk-unlo.patch @@ -28,10 +28,10 @@ index f12d844d422ca4175d4cb2b8e3112b590a207a16..834e5d2ef6045ef703321852f988db3f } // Spigot End diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java -index bc6ddf50bcd2f38be8c8fa064b49a7363643b9bd..aac412ebb2af3c63a2a6fda1dd647fbdee35ec1b 100644 +index c966f3f2e3176b47063dec03e7aaa4e809fd4de3..e9e30baefc1feec81fbe866cf5b6e5133c848112 100644 --- a/src/main/java/net/minecraft/server/level/ServerPlayer.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java -@@ -1573,6 +1573,18 @@ public class ServerPlayer extends Player { +@@ -1575,6 +1575,18 @@ public class ServerPlayer extends Player { this.connection.send(new ClientboundContainerClosePacket(this.containerMenu.containerId)); this.doCloseContainer(); } diff --git a/patches/server/0694-Improve-and-expand-AsyncCatcher.patch b/patches/server/0694-Improve-and-expand-AsyncCatcher.patch index 5f2d4e09dd..9bf935c48a 100644 --- a/patches/server/0694-Improve-and-expand-AsyncCatcher.patch +++ b/patches/server/0694-Improve-and-expand-AsyncCatcher.patch @@ -17,10 +17,10 @@ Async catch modifications to critical entity state Co-authored-by: Jake Potrebic diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index f0688aba315ddea393fea88fc82752d9b46fec6a..df3bbf6c95068ac6d8b000d2ef13de1c6a5204e1 100644 +index adffa10ad47d1c2a9479ca91073a12e61538a608..f41c376b0f6d858fabe46834fff5049da48c732e 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -1653,6 +1653,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -1654,6 +1654,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic } public void internalTeleport(double d0, double d1, double d2, float f, float f1, Set set) { // Paper diff --git a/patches/server/0695-Add-paper-mobcaps-and-paper-playermobcaps.patch b/patches/server/0695-Add-paper-mobcaps-and-paper-playermobcaps.patch index 69e649f259..a132936fa4 100644 --- a/patches/server/0695-Add-paper-mobcaps-and-paper-playermobcaps.patch +++ b/patches/server/0695-Add-paper-mobcaps-and-paper-playermobcaps.patch @@ -278,10 +278,10 @@ index a1770e5ae4b3014c3538b52d4912c60864e186a8..906def91bba96bab7c7aea9b87d9ec56 // Paper start - add parameters and int ret type spawnCategoryForChunk(group, world, chunk, checker, runner, Integer.MAX_VALUE, null); diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 4fcfad88374430b03e6ea8aa4a45e110f644a36b..5c4221f8ea476ea218a6222904c6af3841bdb1dc 100644 +index 8e8e0cc2f60c11ddd1ac2d232a698b3f4286426c..ce968a5f44282095cec4d44f43bdfe953bce069c 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -2161,6 +2161,11 @@ public final class CraftServer implements Server { +@@ -2162,6 +2162,11 @@ public final class CraftServer implements Server { @Override public int getSpawnLimit(SpawnCategory spawnCategory) { @@ -294,10 +294,10 @@ index 4fcfad88374430b03e6ea8aa4a45e110f644a36b..5c4221f8ea476ea218a6222904c6af38 } diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -index cf0892b4d4e5d3759ce743de9a0e36bb8924c7cd..dc9e6042e6c8deb997f609e10455f7947faa479e 100644 +index 60ad39ba1cde4d4d1231f43902af4441a944556f..6e7aba92fd3f6c02680d9902c974bc2af0428fb1 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -@@ -1710,9 +1710,14 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -1696,9 +1696,14 @@ public class CraftWorld extends CraftRegionAccessor implements World { Validate.notNull(spawnCategory, "SpawnCategory cannot be null"); Validate.isTrue(CraftSpawnCategory.isValidForLimits(spawnCategory), "SpawnCategory." + spawnCategory + " are not supported."); diff --git a/patches/server/0703-Detail-more-information-in-watchdog-dumps.patch b/patches/server/0703-Detail-more-information-in-watchdog-dumps.patch index ba485df6d7..32af3d6ac4 100644 --- a/patches/server/0703-Detail-more-information-in-watchdog-dumps.patch +++ b/patches/server/0703-Detail-more-information-in-watchdog-dumps.patch @@ -122,10 +122,10 @@ index 8faf55969232d44b999231b219a208e049a72755..1f683d734b9e272c8f4c48d922f3dcd1 private void tickPassenger(Entity vehicle, Entity passenger) { diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index b172f0733491ca6cde6b962f03e15e6e949ebf52..d87e9e252056d9dea6748f54847434468a0111df 100644 +index c79f7de53d8d61044a756b2a973f71bb5af74bfc..6da3b1d6e09f5c8c09234b4da0aeaba5ab632dd7 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -972,7 +972,42 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -973,7 +973,42 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { return this.onGround; } @@ -168,7 +168,7 @@ index b172f0733491ca6cde6b962f03e15e6e949ebf52..d87e9e252056d9dea6748f5484743446 if (this.noPhysics) { this.setPos(this.getX() + movement.x, this.getY() + movement.y, this.getZ() + movement.z); } else { -@@ -1145,6 +1180,13 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -1146,6 +1181,13 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { this.level.getProfiler().pop(); } } @@ -182,7 +182,7 @@ index b172f0733491ca6cde6b962f03e15e6e949ebf52..d87e9e252056d9dea6748f5484743446 } protected boolean isHorizontalCollisionMinor(Vec3 adjustedMovement) { -@@ -4097,7 +4139,9 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -4098,7 +4140,9 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { } public void setDeltaMovement(Vec3 velocity) { @@ -192,7 +192,7 @@ index b172f0733491ca6cde6b962f03e15e6e949ebf52..d87e9e252056d9dea6748f5484743446 } public void addDeltaMovement(Vec3 velocity) { -@@ -4183,7 +4227,9 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -4184,7 +4228,9 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { } // Paper end - fix MC-4 if (this.position.x != x || this.position.y != y || this.position.z != z) { diff --git a/patches/server/0726-Don-t-respond-to-ServerboundCommandSuggestionPacket-.patch b/patches/server/0726-Don-t-respond-to-ServerboundCommandSuggestionPacket-.patch index baff99b672..5a56b50632 100644 --- a/patches/server/0726-Don-t-respond-to-ServerboundCommandSuggestionPacket-.patch +++ b/patches/server/0726-Don-t-respond-to-ServerboundCommandSuggestionPacket-.patch @@ -6,10 +6,10 @@ Subject: [PATCH] Don't respond to ServerboundCommandSuggestionPacket when diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index df3bbf6c95068ac6d8b000d2ef13de1c6a5204e1..8321ab10cae1a8ea7c7e585d45668f5ef70fd941 100644 +index f41c376b0f6d858fabe46834fff5049da48c732e..a980f5aacba4dbf64b75663b75e69a88528876f1 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -838,6 +838,11 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -839,6 +839,11 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic } // Paper end // CraftBukkit end diff --git a/patches/server/0728-Ensure-valid-vehicle-status.patch b/patches/server/0728-Ensure-valid-vehicle-status.patch index 395044e7a8..1f6079df5e 100644 --- a/patches/server/0728-Ensure-valid-vehicle-status.patch +++ b/patches/server/0728-Ensure-valid-vehicle-status.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Ensure valid vehicle status diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java -index aac412ebb2af3c63a2a6fda1dd647fbdee35ec1b..d9719e544261b9d2dc85fa9936ae23ea8e8dd08c 100644 +index e9e30baefc1feec81fbe866cf5b6e5133c848112..a3f6a5477b264ec13d9f8ab863798b20faace226 100644 --- a/src/main/java/net/minecraft/server/level/ServerPlayer.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java -@@ -525,7 +525,7 @@ public class ServerPlayer extends Player { +@@ -527,7 +527,7 @@ public class ServerPlayer extends Player { } } diff --git a/patches/server/0734-Update-head-rotation-in-missing-places.patch b/patches/server/0734-Update-head-rotation-in-missing-places.patch index d4cc481e2c..2c04245058 100644 --- a/patches/server/0734-Update-head-rotation-in-missing-places.patch +++ b/patches/server/0734-Update-head-rotation-in-missing-places.patch @@ -8,10 +8,10 @@ This is because bukkit uses a separate head rotation field for yaw. This issue only applies to players. diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index d87e9e252056d9dea6748f54847434468a0111df..5e0a7aa0e9fb1350964d17e3f5904c4ec3922ff9 100644 +index 6da3b1d6e09f5c8c09234b4da0aeaba5ab632dd7..1a71fe0113a1109da7b0f11a879b33a7e694b783 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -1783,6 +1783,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -1784,6 +1784,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { this.setXRot(Mth.clamp(pitch, -90.0F, 90.0F) % 360.0F); this.yRotO = this.getYRot(); this.xRotO = this.getXRot(); @@ -19,7 +19,7 @@ index d87e9e252056d9dea6748f54847434468a0111df..5e0a7aa0e9fb1350964d17e3f5904c4e } public void absMoveTo(double x, double y, double z) { -@@ -1821,6 +1822,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -1822,6 +1823,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { this.setXRot(pitch); this.setOldPosAndRot(); this.reapplyPosition(); diff --git a/patches/server/0738-Add-config-option-for-logging-player-ip-addresses.patch b/patches/server/0738-Add-config-option-for-logging-player-ip-addresses.patch index 065f8be13d..7a7c8465cd 100644 --- a/patches/server/0738-Add-config-option-for-logging-player-ip-addresses.patch +++ b/patches/server/0738-Add-config-option-for-logging-player-ip-addresses.patch @@ -47,10 +47,10 @@ index 595779cfd0ee1c405d7936f00a7cae1706125e7f..ed3af916dfa875dd0a5f1e730d20d11e @Override diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java -index 79aac02a4c702797c72970a40a17bdf4115fa644..0b3b926e6d9a0afbd2f4674517e39b3addd8acf5 100644 +index 9386d0836ed6dad232aa24219bdbbaeafffc49c0..feed51dba189ab35d5c7e6cc458cc865cf65c87f 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -246,7 +246,7 @@ public abstract class PlayerList { +@@ -248,7 +248,7 @@ public abstract class PlayerList { String s1 = "local"; if (connection.getRemoteAddress() != null) { diff --git a/patches/server/0743-don-t-attempt-to-teleport-dead-entities.patch b/patches/server/0743-don-t-attempt-to-teleport-dead-entities.patch index 62d8916cc8..ac636acb3e 100644 --- a/patches/server/0743-don-t-attempt-to-teleport-dead-entities.patch +++ b/patches/server/0743-don-t-attempt-to-teleport-dead-entities.patch @@ -5,10 +5,10 @@ Subject: [PATCH] don't attempt to teleport dead entities diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index 5e0a7aa0e9fb1350964d17e3f5904c4ec3922ff9..45eeef03ab3c885b4fbc332287089e9cc5d85afa 100644 +index 1a71fe0113a1109da7b0f11a879b33a7e694b783..10ef56a2847450c3294802e2f84e105fccdc4721 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -780,7 +780,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -781,7 +781,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { // CraftBukkit start public void postTick() { // No clean way to break out of ticking once the entity has been copied to a new world, so instead we move the portalling later in the tick cycle diff --git a/patches/server/0749-Hide-unnecessary-itemmeta-from-clients.patch b/patches/server/0749-Hide-unnecessary-itemmeta-from-clients.patch index 9bb5bad7e0..1c34af5e3f 100644 --- a/patches/server/0749-Hide-unnecessary-itemmeta-from-clients.patch +++ b/patches/server/0749-Hide-unnecessary-itemmeta-from-clients.patch @@ -18,10 +18,10 @@ index 3e8255898e8afdd1127eea79338d5cc54502be76..fc187be6b3fb7bc9fa97d1ebcbe92294 } } diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 8321ab10cae1a8ea7c7e585d45668f5ef70fd941..e9e7b06e6dd074da4f6821f1117c6a29dff78a7c 100644 +index 4711986fb38c4c941ce253df05ff7b70dbb0d47f..0ed72d306088f31cf891f1508fe00451b799f682 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -2699,8 +2699,8 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -2706,8 +2706,8 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic // Refresh the current entity metadata entity.getEntityData().refresh(player); // SPIGOT-7136 - Allays diff --git a/patches/server/0753-Add-player-health-update-API.patch b/patches/server/0753-Add-player-health-update-API.patch index f9eb37137d..01b414fc4d 100644 --- a/patches/server/0753-Add-player-health-update-API.patch +++ b/patches/server/0753-Add-player-health-update-API.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Add player health update API diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -index 855b20e198983470b83ebbb38ebe5cba580cecd6..9329bd7ace628fef7734fbae263a9bc1a4faa8c4 100644 +index e826a9e405c0ea985f8a742f4bc81b38c9d98bba..207ae9c07d4646686bc79156d7b72ade71084ce2 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -@@ -2384,9 +2384,11 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -2392,9 +2392,11 @@ public class CraftPlayer extends CraftHumanEntity implements Player { this.getHandle().maxHealthCache = getMaxHealth(); } @@ -22,7 +22,7 @@ index 855b20e198983470b83ebbb38ebe5cba580cecd6..9329bd7ace628fef7734fbae263a9bc1 if (this.getHandle().queueHealthUpdatePacket) { this.getHandle().queuedHealthUpdatePacket = packet; } else { -@@ -2395,6 +2397,12 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -2403,6 +2405,12 @@ public class CraftPlayer extends CraftHumanEntity implements Player { // Paper end } diff --git a/patches/server/0755-Allow-delegation-to-vanilla-chunk-gen.patch b/patches/server/0755-Allow-delegation-to-vanilla-chunk-gen.patch index 698c325b77..054292f6f5 100644 --- a/patches/server/0755-Allow-delegation-to-vanilla-chunk-gen.patch +++ b/patches/server/0755-Allow-delegation-to-vanilla-chunk-gen.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Allow delegation to vanilla chunk gen diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 5c4221f8ea476ea218a6222904c6af3841bdb1dc..4a37cfddbf152dad5bd315c20d1546e584e62e1a 100644 +index ce968a5f44282095cec4d44f43bdfe953bce069c..05605d7a6384349f7ff13950d81d4f08a243b4eb 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -2333,6 +2333,90 @@ public final class CraftServer implements Server { +@@ -2334,6 +2334,90 @@ public final class CraftServer implements Server { return new OldCraftChunkData(world.getMinHeight(), world.getMaxHeight(), handle.registryAccess().registryOrThrow(Registries.BIOME), world); // Paper - Anti-Xray - Add parameters } diff --git a/patches/server/0756-Highly-optimise-single-and-multi-AABB-VoxelShapes-an.patch b/patches/server/0756-Highly-optimise-single-and-multi-AABB-VoxelShapes-an.patch index 1e6284915b..4c9bde2586 100644 --- a/patches/server/0756-Highly-optimise-single-and-multi-AABB-VoxelShapes-an.patch +++ b/patches/server/0756-Highly-optimise-single-and-multi-AABB-VoxelShapes-an.patch @@ -1180,10 +1180,10 @@ index 0000000000000000000000000000000000000000..d67a40e7be030142443680c89e1763fc + } +} diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java -index d9719e544261b9d2dc85fa9936ae23ea8e8dd08c..5afb17ccc16e614e91ff3cad2f714b4ab40fb979 100644 +index a3f6a5477b264ec13d9f8ab863798b20faace226..88d5866b67fd4617eabf1333b22843e9d64fdb39 100644 --- a/src/main/java/net/minecraft/server/level/ServerPlayer.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java -@@ -418,7 +418,7 @@ public class ServerPlayer extends Player { +@@ -420,7 +420,7 @@ public class ServerPlayer extends Player { if (blockposition1 != null) { this.moveTo(blockposition1, 0.0F, 0.0F); @@ -1192,7 +1192,7 @@ index d9719e544261b9d2dc85fa9936ae23ea8e8dd08c..5afb17ccc16e614e91ff3cad2f714b4a break; } } -@@ -426,7 +426,7 @@ public class ServerPlayer extends Player { +@@ -428,7 +428,7 @@ public class ServerPlayer extends Player { } else { this.moveTo(blockposition, 0.0F, 0.0F); @@ -1202,10 +1202,10 @@ index d9719e544261b9d2dc85fa9936ae23ea8e8dd08c..5afb17ccc16e614e91ff3cad2f714b4a } } diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java -index 0b3b926e6d9a0afbd2f4674517e39b3addd8acf5..3c3e110f7caaf42783638aac74ef5e69513d1fff 100644 +index feed51dba189ab35d5c7e6cc458cc865cf65c87f..6fa5d2552935e8e733cbbefb2db11239a26291dc 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -886,7 +886,7 @@ public abstract class PlayerList { +@@ -888,7 +888,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 @@ -1215,10 +1215,10 @@ index 0b3b926e6d9a0afbd2f4674517e39b3addd8acf5..3c3e110f7caaf42783638aac74ef5e69 } diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index 45eeef03ab3c885b4fbc332287089e9cc5d85afa..63802f5304f23a6e1e469e383692376d1f4d8f0d 100644 +index 10ef56a2847450c3294802e2f84e105fccdc4721..1a8b5b3250f8e047f35612a6762d47cf963b74fd 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -1161,9 +1161,44 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -1162,9 +1162,44 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { float f2 = this.getBlockSpeedFactor(); this.setDeltaMovement(this.getDeltaMovement().multiply((double) f2, 1.0D, (double) f2)); @@ -1266,7 +1266,7 @@ index 45eeef03ab3c885b4fbc332287089e9cc5d85afa..63802f5304f23a6e1e469e383692376d if (this.remainingFireTicks <= 0) { this.setRemainingFireTicks(-this.getFireImmuneTicks()); } -@@ -1315,32 +1350,78 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -1316,32 +1351,78 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { } private Vec3 collide(Vec3 movement) { @@ -1366,7 +1366,7 @@ index 45eeef03ab3c885b4fbc332287089e9cc5d85afa..63802f5304f23a6e1e469e383692376d } public static Vec3 collideBoundingBox(@Nullable Entity entity, Vec3 movement, AABB entityBoundingBox, Level world, List collisions) { -@@ -2491,11 +2572,30 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -2492,11 +2573,30 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { float f = this.dimensions.width * 0.8F; AABB axisalignedbb = AABB.ofSize(this.getEyePosition(), (double) f, 1.0E-6D, (double) f); diff --git a/patches/server/0757-Optimise-collision-checking-in-player-move-packet-ha.patch b/patches/server/0757-Optimise-collision-checking-in-player-move-packet-ha.patch index 7ec825faf0..3ff5acb132 100644 --- a/patches/server/0757-Optimise-collision-checking-in-player-move-packet-ha.patch +++ b/patches/server/0757-Optimise-collision-checking-in-player-move-packet-ha.patch @@ -6,10 +6,10 @@ Subject: [PATCH] Optimise collision checking in player move packet handling Move collision logic to just the hasNewCollision call instead of getCubes + hasNewCollision diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index e9e7b06e6dd074da4f6821f1117c6a29dff78a7c..8552f230b4ec64a6e056198d3edb04395138608a 100644 +index ed7818150b0e3cfde1509081b7afcbd82826e09b..71cb4ba6c2b8eeccfe2472d33953627bd74dbb62 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -646,7 +646,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -647,7 +647,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic return; } @@ -18,7 +18,7 @@ index e9e7b06e6dd074da4f6821f1117c6a29dff78a7c..8552f230b4ec64a6e056198d3edb0439 d6 = d3 - this.vehicleLastGoodX; // Paper - diff on change, used for checking large move vectors above d7 = d4 - this.vehicleLastGoodY - 1.0E-6D; // Paper - diff on change, used for checking large move vectors above -@@ -654,6 +654,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -655,6 +655,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic boolean flag1 = entity.verticalCollisionBelow; entity.move(MoverType.PLAYER, new Vec3(d6, d7, d8)); @@ -26,7 +26,7 @@ index e9e7b06e6dd074da4f6821f1117c6a29dff78a7c..8552f230b4ec64a6e056198d3edb0439 double d11 = d7; d6 = d3 - entity.getX(); -@@ -667,16 +668,24 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -668,16 +669,24 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic boolean flag2 = false; if (d10 > org.spigotmc.SpigotConfig.movedWronglyThreshold) { // Spigot @@ -54,7 +54,7 @@ index e9e7b06e6dd074da4f6821f1117c6a29dff78a7c..8552f230b4ec64a6e056198d3edb0439 entity.absMoveTo(d0, d1, d2, f, f1); this.player.absMoveTo(d0, d1, d2, this.player.getYRot(), this.player.getXRot()); // CraftBukkit this.connection.send(new ClientboundMoveVehiclePacket(entity)); -@@ -762,7 +771,32 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -763,7 +772,32 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic } private boolean noBlocksAround(Entity entity) { @@ -88,7 +88,7 @@ index e9e7b06e6dd074da4f6821f1117c6a29dff78a7c..8552f230b4ec64a6e056198d3edb0439 } @Override -@@ -1342,7 +1376,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -1343,7 +1377,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic } if (this.awaitingPositionFromClient != null) { @@ -97,7 +97,7 @@ index e9e7b06e6dd074da4f6821f1117c6a29dff78a7c..8552f230b4ec64a6e056198d3edb0439 this.awaitingTeleportTime = this.tickCount; this.teleport(this.awaitingPositionFromClient.x, this.awaitingPositionFromClient.y, this.awaitingPositionFromClient.z, this.player.getYRot(), this.player.getXRot()); } -@@ -1436,7 +1470,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -1437,7 +1471,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic } } @@ -106,7 +106,7 @@ index e9e7b06e6dd074da4f6821f1117c6a29dff78a7c..8552f230b4ec64a6e056198d3edb0439 d7 = d0 - this.lastGoodX; // Paper - diff on change, used for checking large move vectors above d8 = d1 - this.lastGoodY; // Paper - diff on change, used for checking large move vectors above -@@ -1477,6 +1511,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -1478,6 +1512,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic boolean flag1 = this.player.verticalCollisionBelow; this.player.move(MoverType.PLAYER, new Vec3(d7, d8, d9)); @@ -114,7 +114,7 @@ index e9e7b06e6dd074da4f6821f1117c6a29dff78a7c..8552f230b4ec64a6e056198d3edb0439 this.player.onGround = packet.isOnGround(); // CraftBukkit - SPIGOT-5810, SPIGOT-5835, SPIGOT-6828: reset by this.player.move // Paper start - prevent position desync if (this.awaitingPositionFromClient != null) { -@@ -1496,12 +1531,23 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -1497,12 +1532,23 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic boolean flag2 = false; if (!this.player.isChangingDimension() && d11 > org.spigotmc.SpigotConfig.movedWronglyThreshold && !this.player.isSleeping() && !this.player.gameMode.isCreative() && this.player.gameMode.getGameModeForPlayer() != GameType.SPECTATOR) { // Spigot @@ -140,7 +140,7 @@ index e9e7b06e6dd074da4f6821f1117c6a29dff78a7c..8552f230b4ec64a6e056198d3edb0439 this.internalTeleport(d3, d4, d5, f, f1, Collections.emptySet()); // CraftBukkit - SPIGOT-1807: Don't call teleport event, when the client thinks the player is falling, because the chunks are not loaded on the client yet. this.player.doCheckFallDamage(this.player.getY() - d6, packet.isOnGround()); } else { -@@ -1588,6 +1634,27 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -1589,6 +1635,27 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic } } diff --git a/patches/server/0762-Forward-CraftEntity-in-teleport-command.patch b/patches/server/0762-Forward-CraftEntity-in-teleport-command.patch index 6dddb78633..661d2e5bd3 100644 --- a/patches/server/0762-Forward-CraftEntity-in-teleport-command.patch +++ b/patches/server/0762-Forward-CraftEntity-in-teleport-command.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Forward CraftEntity in teleport command diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index 63802f5304f23a6e1e469e383692376d1f4d8f0d..374ba7c9a088bc56ec1da96902aab3c81889c64d 100644 +index 1a8b5b3250f8e047f35612a6762d47cf963b74fd..61f6e3196551b76d0300a60e3ad8e446b49dace3 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -3330,6 +3330,13 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -3331,6 +3331,13 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { } public void restoreFrom(Entity original) { @@ -22,7 +22,7 @@ index 63802f5304f23a6e1e469e383692376d1f4d8f0d..374ba7c9a088bc56ec1da96902aab3c8 CompoundTag nbttagcompound = original.saveWithoutId(new CompoundTag()); nbttagcompound.remove("Dimension"); -@@ -3411,10 +3418,10 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -3412,10 +3419,10 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { if (worldserver.getTypeKey() == LevelStem.END) { // CraftBukkit ServerLevel.makeObsidianPlatform(worldserver, this); // CraftBukkit } diff --git a/patches/server/0773-Validate-usernames.patch b/patches/server/0773-Validate-usernames.patch index e4bfe6cea3..bc6a92f1f3 100644 --- a/patches/server/0773-Validate-usernames.patch +++ b/patches/server/0773-Validate-usernames.patch @@ -56,10 +56,10 @@ index ed3af916dfa875dd0a5f1e730d20d11efd6419c6..cd4e76fe5b79c7d9e615b4886a568c74 if (gameprofile != null && packet.name().equalsIgnoreCase(gameprofile.getName())) { diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java -index 3c3e110f7caaf42783638aac74ef5e69513d1fff..c609f63a2e0deffba852f83a5990ad5150029948 100644 +index 6fa5d2552935e8e733cbbefb2db11239a26291dc..0996ae8318aab706892c6ef4caae369e62f54187 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -664,7 +664,7 @@ public abstract class PlayerList { +@@ -666,7 +666,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/0775-Expose-vanilla-BiomeProvider-from-WorldInfo.patch b/patches/server/0775-Expose-vanilla-BiomeProvider-from-WorldInfo.patch index e1ff3e0034..db426ff666 100644 --- a/patches/server/0775-Expose-vanilla-BiomeProvider-from-WorldInfo.patch +++ b/patches/server/0775-Expose-vanilla-BiomeProvider-from-WorldInfo.patch @@ -18,10 +18,10 @@ index 24c88555ea85dd2a0656e1f67a4828a5137157b8..cbbb0ff40488c430d15c2ed054d1b288 biomeProvider = gen.getDefaultBiomeProvider(worldInfo); } diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 4a37cfddbf152dad5bd315c20d1546e584e62e1a..d1bfa05340a983fc14c83d85371206d14197059b 100644 +index 05605d7a6384349f7ff13950d81d4f08a243b4eb..4e3ee12d6cdd18372239f35d3ab188e2116128fa 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -1213,7 +1213,7 @@ public final class CraftServer implements Server { +@@ -1214,7 +1214,7 @@ public final class CraftServer implements Server { List list = ImmutableList.of(new PhantomSpawner(), new PatrolSpawner(), new CatSpawner(), new VillageSiege(), new WanderingTraderSpawner(worlddata)); LevelStem worlddimension = iregistry.get(actualDimension); @@ -31,10 +31,10 @@ index 4a37cfddbf152dad5bd315c20d1546e584e62e1a..d1bfa05340a983fc14c83d85371206d1 biomeProvider = generator.getDefaultBiomeProvider(worldInfo); } diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -index dc9e6042e6c8deb997f609e10455f7947faa479e..5f9696a4a2490baf7667fa15a8b01a5f845e5f23 100644 +index 0855b437d8ba0ec71b4c0a5ed29629ff28f56f8a..4cea156d555688b366b6d54f965132871995015c 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -@@ -200,6 +200,30 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -201,6 +201,30 @@ public class CraftWorld extends CraftRegionAccessor implements World { public int getPlayerCount() { return world.players().size(); } diff --git a/patches/server/0783-Kick-on-main-for-illegal-chat.patch b/patches/server/0783-Kick-on-main-for-illegal-chat.patch index 7c2d916a87..9367c16b2f 100644 --- a/patches/server/0783-Kick-on-main-for-illegal-chat.patch +++ b/patches/server/0783-Kick-on-main-for-illegal-chat.patch @@ -7,10 +7,10 @@ Makes the PlayerKickEvent fire on the main thread for illegal characters or chat out-of-order errors. diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 8552f230b4ec64a6e056198d3edb04395138608a..c3d4a3d109746866bbade09e0c95d7897c912b4b 100644 +index cde507aa4d342c323c3ce05014ad9b4c6b0a2d5e..3cbdc0c897c57e2db01ba78c83c0f2c0fa1e6190 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -2162,7 +2162,9 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -2163,7 +2163,9 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic } // CraftBukkit end if (ServerGamePacketListenerImpl.isChatMessageIllegal(packet.message())) { @@ -20,7 +20,7 @@ index 8552f230b4ec64a6e056198d3edb04395138608a..c3d4a3d109746866bbade09e0c95d789 } else { Optional optional = this.tryHandleChat(packet.message(), packet.timeStamp(), packet.lastSeenMessages()); -@@ -2196,12 +2198,15 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -2197,7 +2199,9 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic @Override public void handleChatCommand(ServerboundChatCommandPacket packet) { if (ServerGamePacketListenerImpl.isChatMessageIllegal(packet.command())) { @@ -30,13 +30,7 @@ index 8552f230b4ec64a6e056198d3edb04395138608a..c3d4a3d109746866bbade09e0c95d789 } else { Optional optional = this.tryHandleChat(packet.command(), packet.timeStamp(), packet.lastSeenMessages()); - if (optional.isPresent()) { - this.server.submit(() -> { -+ if (player.hasDisconnected()) return; // Paper - this.performChatCommand(packet, (LastSeenMessages) optional.get()); - this.detectRateSpam("/" + packet.command()); // Spigot - }); -@@ -2276,7 +2281,9 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -2283,7 +2287,9 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic private Optional tryHandleChat(String message, Instant timestamp, LastSeenMessages.Update acknowledgment) { if (!this.updateChatOrder(timestamp)) { ServerGamePacketListenerImpl.LOGGER.warn("{} sent out-of-order chat: '{}'", this.player.getName().getString(), message); diff --git a/patches/server/0784-Multi-Block-Change-API-Implementation.patch b/patches/server/0784-Multi-Block-Change-API-Implementation.patch index 2cb0fc6f73..d193b8b305 100644 --- a/patches/server/0784-Multi-Block-Change-API-Implementation.patch +++ b/patches/server/0784-Multi-Block-Change-API-Implementation.patch @@ -25,10 +25,10 @@ index c96e75456c2f8564d3bc75993cc6e03ba605597d..7c6a6693760638a07b7c7c330aaeffd9 public void write(FriendlyByteBuf buf) { buf.writeLong(this.sectionPos.asLong()); diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -index 9329bd7ace628fef7734fbae263a9bc1a4faa8c4..93388dbf5768ee622374bc1247aaee9324bfaf9a 100644 +index 207ae9c07d4646686bc79156d7b72ade71084ce2..85c28926533c3159d42e8e7d90051472613dda8c 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -@@ -948,6 +948,32 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -952,6 +952,32 @@ public class CraftPlayer extends CraftHumanEntity implements Player { this.getHandle().connection.send(packet); } diff --git a/patches/server/0786-Freeze-Tick-Lock-API.patch b/patches/server/0786-Freeze-Tick-Lock-API.patch index f21a43eb14..9d9f4ebc17 100644 --- a/patches/server/0786-Freeze-Tick-Lock-API.patch +++ b/patches/server/0786-Freeze-Tick-Lock-API.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Freeze Tick Lock API diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index 374ba7c9a088bc56ec1da96902aab3c81889c64d..dccac696c29a340c5a60fc07aaab7f0f1506b039 100644 +index 61f6e3196551b76d0300a60e3ad8e446b49dace3..570d6b5777ea21619db23ef01f3230249d9ab6e1 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -397,6 +397,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -398,6 +398,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { private org.bukkit.util.Vector origin; @javax.annotation.Nullable private UUID originWorld; @@ -16,7 +16,7 @@ index 374ba7c9a088bc56ec1da96902aab3c81889c64d..dccac696c29a340c5a60fc07aaab7f0f public void setOrigin(@javax.annotation.Nonnull Location location) { this.origin = location.toVector(); -@@ -826,7 +827,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -827,7 +828,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { this.setRemainingFireTicks(this.remainingFireTicks - 1); } @@ -25,7 +25,7 @@ index 374ba7c9a088bc56ec1da96902aab3c81889c64d..dccac696c29a340c5a60fc07aaab7f0f this.setTicksFrozen(0); this.level.levelEvent((Player) null, 1009, this.blockPosition, 1); } -@@ -2297,6 +2298,9 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -2298,6 +2299,9 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { if (fromNetherPortal) { nbt.putBoolean("Paper.FromNetherPortal", true); } @@ -35,7 +35,7 @@ index 374ba7c9a088bc56ec1da96902aab3c81889c64d..dccac696c29a340c5a60fc07aaab7f0f // Paper end return nbt; } catch (Throwable throwable) { -@@ -2462,6 +2466,9 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -2463,6 +2467,9 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { if (spawnReason == null) { spawnReason = org.bukkit.event.entity.CreatureSpawnEvent.SpawnReason.DEFAULT; } @@ -59,7 +59,7 @@ index b167d83abee37d64f8ef5865b9407bf1d2237ea1..b30e52730a7dec78e425365975ba57aa if (this.isInPowderSnow && this.canFreeze()) { diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java -index 7ea5f911046fd05be8a997b07e6f66d69eaa9564..7df1eebce5b62214943e55314e9ec98f056fa330 100644 +index 743c32c449a135b242f545239c987af42cce2205..6478faa20adea00349600620c2ab7d559e2fc3b7 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java @@ -663,6 +663,17 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity { diff --git a/patches/server/0790-API-for-creating-command-sender-which-forwards-feedb.patch b/patches/server/0790-API-for-creating-command-sender-which-forwards-feedb.patch index 9b04a37dcb..496bc6f530 100644 --- a/patches/server/0790-API-for-creating-command-sender-which-forwards-feedb.patch +++ b/patches/server/0790-API-for-creating-command-sender-which-forwards-feedb.patch @@ -122,10 +122,10 @@ index 0000000000000000000000000000000000000000..e3a5f1ec376319bdfda87fa27ae217bf + } +} diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index d1bfa05340a983fc14c83d85371206d14197059b..5704441d2c53bbb5e3eda1c41066299a68e77300 100644 +index 4e3ee12d6cdd18372239f35d3ab188e2116128fa..56ab53830525b497d2abc7e422b03d1e98d1118c 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -1995,6 +1995,13 @@ public final class CraftServer implements Server { +@@ -1996,6 +1996,13 @@ public final class CraftServer implements Server { return console.console; } diff --git a/patches/server/0791-Add-missing-structure-set-seed-configs.patch b/patches/server/0791-Add-missing-structure-set-seed-configs.patch index 4c753a9f6c..e973db6aad 100644 --- a/patches/server/0791-Add-missing-structure-set-seed-configs.patch +++ b/patches/server/0791-Add-missing-structure-set-seed-configs.patch @@ -229,10 +229,10 @@ index 65dcb14241baadb2c9f8f16919d7b562198ad9c3..594a2dd3b1d4c29c969d1992b8e93795 @Override diff --git a/src/main/java/org/spigotmc/SpigotWorldConfig.java b/src/main/java/org/spigotmc/SpigotWorldConfig.java -index 6bcc46795d1f78746192cc107c4a1f61580ec3c5..5503ad6a93d331771a0e92c0da6adedf2ac81aff 100644 +index fb1495f9afe87ad80098beedbaa44efb66e36bca..39a823c03c9542a193b6c9555a01a1562be7d339 100644 --- a/src/main/java/org/spigotmc/SpigotWorldConfig.java +++ b/src/main/java/org/spigotmc/SpigotWorldConfig.java -@@ -362,6 +362,16 @@ public class SpigotWorldConfig +@@ -364,6 +364,16 @@ public class SpigotWorldConfig public int mansionSeed; public int fossilSeed; public int portalSeed; @@ -249,7 +249,7 @@ index 6bcc46795d1f78746192cc107c4a1f61580ec3c5..5503ad6a93d331771a0e92c0da6adedf private void initWorldGenSeeds() { this.villageSeed = this.getInt( "seed-village", 10387312 ); -@@ -379,6 +389,12 @@ public class SpigotWorldConfig +@@ -381,6 +391,12 @@ public class SpigotWorldConfig this.mansionSeed = this.getInt( "seed-mansion", 10387319 ); this.fossilSeed = this.getInt( "seed-fossil", 14357921 ); this.portalSeed = this.getInt( "seed-portal", 34222645 ); diff --git a/patches/server/0792-Implement-regenerateChunk.patch b/patches/server/0792-Implement-regenerateChunk.patch index 3db87dad36..54e3059a34 100644 --- a/patches/server/0792-Implement-regenerateChunk.patch +++ b/patches/server/0792-Implement-regenerateChunk.patch @@ -6,10 +6,10 @@ Subject: [PATCH] Implement regenerateChunk Co-authored-by: Jason Penilla <11360596+jpenilla@users.noreply.github.com> diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -index 5f9696a4a2490baf7667fa15a8b01a5f845e5f23..8e8edda568b60b7bb0d2ebd454c7d52df4d16d24 100644 +index 093fff34682fa59e96a5591a29f38d90c43738d0..fda4f367da3942fdf59a4a34ea73c6107c9ca465 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -@@ -139,6 +139,7 @@ import org.jetbrains.annotations.NotNull; +@@ -140,6 +140,7 @@ import org.jetbrains.annotations.NotNull; public class CraftWorld extends CraftRegionAccessor implements World { public static final int CUSTOM_DIMENSION_OFFSET = 10; private static final CraftPersistentDataTypeRegistry DATA_TYPE_REGISTRY = new CraftPersistentDataTypeRegistry(); @@ -17,7 +17,7 @@ index 5f9696a4a2490baf7667fa15a8b01a5f845e5f23..8e8edda568b60b7bb0d2ebd454c7d52d private final ServerLevel world; private WorldBorder worldBorder; -@@ -429,27 +430,62 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -425,27 +426,62 @@ public class CraftWorld extends CraftRegionAccessor implements World { @Override public boolean regenerateChunk(int x, int z) { org.spigotmc.AsyncCatcher.catchOp("chunk regenerate"); // Spigot diff --git a/patches/server/0794-Add-missing-Validate-calls-to-CraftServer-getSpawnLi.patch b/patches/server/0794-Add-missing-Validate-calls-to-CraftServer-getSpawnLi.patch index 12094cd1ec..97da54485d 100644 --- a/patches/server/0794-Add-missing-Validate-calls-to-CraftServer-getSpawnLi.patch +++ b/patches/server/0794-Add-missing-Validate-calls-to-CraftServer-getSpawnLi.patch @@ -6,10 +6,10 @@ Subject: [PATCH] Add missing Validate calls to CraftServer#getSpawnLimit Copies appropriate checks from CraftWorld#getSpawnLimit diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 5704441d2c53bbb5e3eda1c41066299a68e77300..81109a840669c18f3af92a29a253ee487e0098dd 100644 +index 56ab53830525b497d2abc7e422b03d1e98d1118c..b6070faf0a30da3956fe64e194250504bada9ba5 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -2169,6 +2169,8 @@ public final class CraftServer implements Server { +@@ -2170,6 +2170,8 @@ public final class CraftServer implements Server { @Override public int getSpawnLimit(SpawnCategory spawnCategory) { // Paper start diff --git a/patches/server/0795-Add-GameEvent-tags.patch b/patches/server/0795-Add-GameEvent-tags.patch index a2210651e1..70bc5ac6f0 100644 --- a/patches/server/0795-Add-GameEvent-tags.patch +++ b/patches/server/0795-Add-GameEvent-tags.patch @@ -46,10 +46,10 @@ index 0000000000000000000000000000000000000000..e7d9fd2702a1ce96596580fff8f5ee4f + } +} diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 81109a840669c18f3af92a29a253ee487e0098dd..1938914697c63ac71ac382406d1a47938fa61427 100644 +index b6070faf0a30da3956fe64e194250504bada9ba5..0907143274c0e1d1c122eb6fb4b116f52c360ec9 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -2579,6 +2579,15 @@ public final class CraftServer implements Server { +@@ -2580,6 +2580,15 @@ public final class CraftServer implements Server { return (org.bukkit.Tag) new CraftEntityTag(BuiltInRegistries.ENTITY_TYPE, entityTagKey); } } @@ -65,7 +65,7 @@ index 81109a840669c18f3af92a29a253ee487e0098dd..1938914697c63ac71ac382406d1a4793 default -> throw new IllegalArgumentException(); } -@@ -2611,6 +2620,13 @@ public final class CraftServer implements Server { +@@ -2612,6 +2621,13 @@ public final class CraftServer implements Server { net.minecraft.core.Registry> entityTags = BuiltInRegistries.ENTITY_TYPE; return entityTags.getTags().map(pair -> (org.bukkit.Tag) new CraftEntityTag(entityTags, pair.getFirst())).collect(ImmutableList.toImmutableList()); } diff --git a/patches/server/0801-Put-world-into-worldlist-before-initing-the-world.patch b/patches/server/0801-Put-world-into-worldlist-before-initing-the-world.patch index 1ccb7c642f..9f558932d3 100644 --- a/patches/server/0801-Put-world-into-worldlist-before-initing-the-world.patch +++ b/patches/server/0801-Put-world-into-worldlist-before-initing-the-world.patch @@ -23,10 +23,10 @@ index 23fce58a5909c5b01a5f0ef6912f90858cd3302c..a30c61e176501d1cbd2e330f85d5d258 if (worlddata.getCustomBossEvents() != null) { diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 1938914697c63ac71ac382406d1a47938fa61427..e8b8463ff4e896aaa3dcbb045bc94d2c5cb1ecb7 100644 +index 0907143274c0e1d1c122eb6fb4b116f52c360ec9..4736b0f3ac468be99a42b5c0e62cffbbe2149610 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -1242,10 +1242,11 @@ public final class CraftServer implements Server { +@@ -1243,10 +1243,11 @@ public final class CraftServer implements Server { return null; } diff --git a/patches/server/0803-Custom-Potion-Mixes.patch b/patches/server/0803-Custom-Potion-Mixes.patch index 92ec0c307e..7bd8187953 100644 --- a/patches/server/0803-Custom-Potion-Mixes.patch +++ b/patches/server/0803-Custom-Potion-Mixes.patch @@ -164,10 +164,10 @@ index 424406d2692856cfd82b6f3b7b6228fa3bd20c2f..c57efcb9a79337ec791e4e8f6671612f @Override diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index e8b8463ff4e896aaa3dcbb045bc94d2c5cb1ecb7..957af0133b0aeb4ec49949433d88e9c49f57faa0 100644 +index 4736b0f3ac468be99a42b5c0e62cffbbe2149610..fc088b26c3fab1afcfbcacfd19dc8a3b6111e94c 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -294,6 +294,7 @@ public final class CraftServer implements Server { +@@ -295,6 +295,7 @@ public final class CraftServer implements Server { private final io.papermc.paper.datapack.PaperDatapackManager datapackManager; // Paper public static Exception excessiveVelEx; // Paper - Velocity warnings private final io.papermc.paper.logging.SysoutCatcher sysoutCatcher = new io.papermc.paper.logging.SysoutCatcher(); // Paper @@ -175,7 +175,7 @@ index e8b8463ff4e896aaa3dcbb045bc94d2c5cb1ecb7..957af0133b0aeb4ec49949433d88e9c4 static { ConfigurationSerialization.registerClass(CraftOfflinePlayer.class); -@@ -320,7 +321,7 @@ public final class CraftServer implements Server { +@@ -321,7 +322,7 @@ public final class CraftServer implements Server { Enchantments.SHARPNESS.getClass(); org.bukkit.enchantments.Enchantment.stopAcceptingRegistrations(); @@ -184,7 +184,7 @@ index e8b8463ff4e896aaa3dcbb045bc94d2c5cb1ecb7..957af0133b0aeb4ec49949433d88e9c4 MobEffects.BLINDNESS.getClass(); PotionEffectType.stopAcceptingRegistrations(); // Ugly hack :( -@@ -2900,5 +2901,10 @@ public final class CraftServer implements Server { +@@ -2901,5 +2902,10 @@ public final class CraftServer implements Server { return datapackManager; } diff --git a/patches/server/0804-Force-close-world-loading-screen.patch b/patches/server/0804-Force-close-world-loading-screen.patch index 04ade65924..e0a18e2a25 100644 --- a/patches/server/0804-Force-close-world-loading-screen.patch +++ b/patches/server/0804-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 c609f63a2e0deffba852f83a5990ad5150029948..1cdf4d8794e982ff24c50a0267fbb024bbaba668 100644 +index 0996ae8318aab706892c6ef4caae369e62f54187..e64f806326a5400eab14e6ebe59901aa1ebea110 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -387,6 +387,16 @@ public abstract class PlayerList { +@@ -389,6 +389,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/0805-Fix-falling-block-spawn-methods.patch b/patches/server/0805-Fix-falling-block-spawn-methods.patch index 54dda5fa8c..cbb73d92ca 100644 --- a/patches/server/0805-Fix-falling-block-spawn-methods.patch +++ b/patches/server/0805-Fix-falling-block-spawn-methods.patch @@ -11,10 +11,10 @@ Restores the API behavior from previous versions of the server public net.minecraft.world.entity.item.FallingBlockEntity (Lnet/minecraft/world/level/Level;DDDLnet/minecraft/world/level/block/state/BlockState;)V diff --git a/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java b/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java -index a92d43c0c4793a594b3e17b5e03f7e944b781a55..a968b27ef287b699f3e0d7e6667419796b7789df 100644 +index cc3a90a3337b7d59e4377a1e2448f17a23604e57..b69df51f2a1eec62792e193f64a1815ad6a87e1f 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java -@@ -578,7 +578,7 @@ public abstract class CraftRegionAccessor implements RegionAccessor { +@@ -599,7 +599,7 @@ public abstract class CraftRegionAccessor implements RegionAccessor { // Paper end } else if (FallingBlock.class.isAssignableFrom(clazz)) { BlockPos pos = BlockPos.containing(x, y, z); @@ -24,10 +24,10 @@ index a92d43c0c4793a594b3e17b5e03f7e944b781a55..a968b27ef287b699f3e0d7e666741979 if (Snowball.class.isAssignableFrom(clazz)) { entity = new net.minecraft.world.entity.projectile.Snowball(world, x, y, z); diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -index 8e8edda568b60b7bb0d2ebd454c7d52df4d16d24..8c566479d0936a4d21a40adb87f6272158b217bd 100644 +index fda4f367da3942fdf59a4a34ea73c6107c9ca465..75a8c83779f97c430815964e09f1c3ea61ff4659 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -@@ -1404,7 +1404,12 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -1390,7 +1390,12 @@ public class CraftWorld extends CraftRegionAccessor implements World { Validate.notNull(material, "Material cannot be null"); Validate.isTrue(material.isBlock(), "Material must be a block"); @@ -41,7 +41,7 @@ index 8e8edda568b60b7bb0d2ebd454c7d52df4d16d24..8c566479d0936a4d21a40adb87f62721 return (FallingBlock) entity.getBukkitEntity(); } -@@ -1413,7 +1418,12 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -1399,7 +1404,12 @@ public class CraftWorld extends CraftRegionAccessor implements World { Validate.notNull(location, "Location cannot be null"); Validate.notNull(data, "BlockData cannot be null"); diff --git a/patches/server/0808-More-Projectile-API.patch b/patches/server/0808-More-Projectile-API.patch index dc8519b449..0d65553cbd 100644 --- a/patches/server/0808-More-Projectile-API.patch +++ b/patches/server/0808-More-Projectile-API.patch @@ -235,10 +235,10 @@ index c242f654c88ca1773429348939d3bb2ffae3768c..d1c7ab67cba881d96b7a5e9220130d86 + // Paper end - Expose firework item directly + manually setting flight } diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftFishHook.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftFishHook.java -index 6bfa984781a483d048ef4318761203c701d8a632..5e0c2c5094e1578162d1a50d50701fbd25e6d961 100644 +index 56beff81ca40fd452744bd1c3942ccc503f223d0..7e34d6a986a98f0b9d5c2a66000ea94e2d1f46b0 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftFishHook.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftFishHook.java -@@ -119,4 +119,15 @@ public class CraftFishHook extends CraftProjectile implements FishHook { +@@ -203,4 +203,15 @@ public class CraftFishHook extends CraftProjectile implements FishHook { public HookState getState() { return HookState.values()[this.getHandle().currentState.ordinal()]; } diff --git a/patches/server/0810-Don-t-allow-vehicle-movement-from-players-while-tele.patch b/patches/server/0810-Don-t-allow-vehicle-movement-from-players-while-tele.patch index af6857b49a..2694286a5a 100644 --- a/patches/server/0810-Don-t-allow-vehicle-movement-from-players-while-tele.patch +++ b/patches/server/0810-Don-t-allow-vehicle-movement-from-players-while-tele.patch @@ -7,10 +7,10 @@ Bring the vehicle move packet behavior in line with the regular player move packet. diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 1371ffc0426ff019c47f30f2cdeea51f72b137c3..bec15299c3421e800465120607d4da1e42787aa7 100644 +index 1d0ef70f50810682cedf50754b1933e85f295e08..b10ead22bf26bab708ba46ef996c24836a2ed300 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -576,6 +576,12 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -577,6 +577,12 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic } else { Entity entity = this.player.getRootVehicle(); diff --git a/patches/server/0811-Implement-getComputedBiome-API.patch b/patches/server/0811-Implement-getComputedBiome-API.patch index 8c570c98d7..fe646334c6 100644 --- a/patches/server/0811-Implement-getComputedBiome-API.patch +++ b/patches/server/0811-Implement-getComputedBiome-API.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Implement getComputedBiome API diff --git a/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java b/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java -index a968b27ef287b699f3e0d7e6667419796b7789df..28c9ea1d061ef6a8b27ee43f0a2f7703d7cc3c0e 100644 +index b69df51f2a1eec62792e193f64a1815ad6a87e1f..f4f1150e6be2bff0b8561451594691977a5f1d56 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java -@@ -219,6 +219,13 @@ public abstract class CraftRegionAccessor implements RegionAccessor { +@@ -220,6 +220,13 @@ public abstract class CraftRegionAccessor implements RegionAccessor { return CraftBlock.biomeBaseToBiome(this.getHandle().registryAccess().registryOrThrow(Registries.BIOME), this.getHandle().getNoiseBiome(x >> 2, y >> 2, z >> 2)); } @@ -23,10 +23,10 @@ index a968b27ef287b699f3e0d7e6667419796b7789df..28c9ea1d061ef6a8b27ee43f0a2f7703 public void setBiome(Location location, Biome biome) { this.setBiome(location.getBlockX(), location.getBlockY(), location.getBlockZ(), biome); diff --git a/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java b/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java -index 5343ae3cdda55d7e0b41747c7eccb52e6828f6c9..69d1c21a5c1007ae65f86b130c421f3f9540da2d 100644 +index 84911c7c6d038aadd3d84ac4797feaa91a556c3e..4aa7ea31c9d0e0bb5522301dc111d6a4a2e421fc 100644 --- a/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java +++ b/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java -@@ -343,6 +343,13 @@ public class CraftBlock implements Block { +@@ -342,6 +342,13 @@ public class CraftBlock implements Block { return this.getWorld().getBiome(this.getX(), this.getY(), this.getZ()); } @@ -41,10 +41,10 @@ index 5343ae3cdda55d7e0b41747c7eccb52e6828f6c9..69d1c21a5c1007ae65f86b130c421f3f public void setBiome(Biome bio) { this.getWorld().setBiome(this.getX(), this.getY(), this.getZ(), bio); diff --git a/src/main/java/org/bukkit/craftbukkit/generator/CraftLimitedRegion.java b/src/main/java/org/bukkit/craftbukkit/generator/CraftLimitedRegion.java -index 392701b0022e05d0fd03ee5836fd18f00502f028..b01904021bd4f485aaf03d1d7634b56f134d3099 100644 +index 0ea1586bab74983fca19dcc5415fbc7a044fe186..e3d6f0847bb3b524452f4dc073c07a5d9448bb9f 100644 --- a/src/main/java/org/bukkit/craftbukkit/generator/CraftLimitedRegion.java +++ b/src/main/java/org/bukkit/craftbukkit/generator/CraftLimitedRegion.java -@@ -166,6 +166,14 @@ public class CraftLimitedRegion extends CraftRegionAccessor implements LimitedRe +@@ -167,6 +167,14 @@ public class CraftLimitedRegion extends CraftRegionAccessor implements LimitedRe return super.getBiome(x, y, z); } diff --git a/patches/server/0814-Fix-saving-in-unloadWorld.patch b/patches/server/0814-Fix-saving-in-unloadWorld.patch index eca621cae0..c73233d365 100644 --- a/patches/server/0814-Fix-saving-in-unloadWorld.patch +++ b/patches/server/0814-Fix-saving-in-unloadWorld.patch @@ -6,10 +6,10 @@ Subject: [PATCH] Fix saving in unloadWorld Change savingDisabled to false to ensure ServerLevel's saving logic gets called when unloadWorld is called with save = true diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 957af0133b0aeb4ec49949433d88e9c49f57faa0..1bd1565b02fdcf22e0cb550290ad1ae792002cc0 100644 +index fc088b26c3fab1afcfbcacfd19dc8a3b6111e94c..49eec475f702b9ac35be92e92b77c047ee6e35bb 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -1290,7 +1290,7 @@ public final class CraftServer implements Server { +@@ -1291,7 +1291,7 @@ public final class CraftServer implements Server { try { if (save) { diff --git a/patches/server/0818-fix-player-loottables-running-when-mob-loot-gamerule.patch b/patches/server/0818-fix-player-loottables-running-when-mob-loot-gamerule.patch index cd325292b1..feb9503767 100644 --- a/patches/server/0818-fix-player-loottables-running-when-mob-loot-gamerule.patch +++ b/patches/server/0818-fix-player-loottables-running-when-mob-loot-gamerule.patch @@ -5,10 +5,10 @@ Subject: [PATCH] fix player loottables running when mob loot gamerule is false diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java -index 5afb17ccc16e614e91ff3cad2f714b4ab40fb979..c9529b1157bd8c813f8e303dd35b6416d5a72838 100644 +index 88d5866b67fd4617eabf1333b22843e9d64fdb39..212d61f1c0b9d7039595ec098b7e7d99a898bc4e 100644 --- a/src/main/java/net/minecraft/server/level/ServerPlayer.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java -@@ -873,12 +873,14 @@ public class ServerPlayer extends Player { +@@ -875,12 +875,14 @@ public class ServerPlayer extends Player { } } } diff --git a/patches/server/0819-Ensure-entity-passenger-world-matches-ridden-entity.patch b/patches/server/0819-Ensure-entity-passenger-world-matches-ridden-entity.patch index 60bbe62d85..2a67e2f4e2 100644 --- a/patches/server/0819-Ensure-entity-passenger-world-matches-ridden-entity.patch +++ b/patches/server/0819-Ensure-entity-passenger-world-matches-ridden-entity.patch @@ -6,10 +6,10 @@ Subject: [PATCH] Ensure entity passenger world matches ridden entity Bad plugins doing this would cause some obvious problems... diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index dccac696c29a340c5a60fc07aaab7f0f1506b039..e052694ca221508f28cbfbb93a6ec974d9ca65d8 100644 +index 570d6b5777ea21619db23ef01f3230249d9ab6e1..c37c1615a47c31c96c048386c8ff25ba4804a5c4 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -2723,6 +2723,12 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -2724,6 +2724,12 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { } protected boolean addPassenger(Entity entity) { // CraftBukkit diff --git a/patches/server/0820-Guard-against-invalid-entity-positions.patch b/patches/server/0820-Guard-against-invalid-entity-positions.patch index 60a900c510..de373cdc9c 100644 --- a/patches/server/0820-Guard-against-invalid-entity-positions.patch +++ b/patches/server/0820-Guard-against-invalid-entity-positions.patch @@ -6,10 +6,10 @@ Subject: [PATCH] Guard against invalid entity positions Anything not finite should be blocked and logged diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index e052694ca221508f28cbfbb93a6ec974d9ca65d8..b26fc1a1f30bd9736ac0cf09d381dc02c0bc34d6 100644 +index c37c1615a47c31c96c048386c8ff25ba4804a5c4..507db20f8622d8f26063150ded79e767e61be553 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -4326,11 +4326,33 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -4327,11 +4327,33 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { return this.getZ((2.0D * this.random.nextDouble() - 1.0D) * widthScale); } diff --git a/patches/server/0821-cache-resource-keys.patch b/patches/server/0821-cache-resource-keys.patch index 6015b1196f..9b197aaf19 100644 --- a/patches/server/0821-cache-resource-keys.patch +++ b/patches/server/0821-cache-resource-keys.patch @@ -5,10 +5,10 @@ Subject: [PATCH] cache resource keys diff --git a/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java b/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java -index 69d1c21a5c1007ae65f86b130c421f3f9540da2d..0d30b388d8d93a6dbbf8dfb30d26eb44c73e1e4e 100644 +index 4aa7ea31c9d0e0bb5522301dc111d6a4a2e421fc..a10ca7df7863d76e2b32bf414437cbfc6d35c9b7 100644 --- a/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java +++ b/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java -@@ -368,12 +368,13 @@ public class CraftBlock implements Block { +@@ -367,12 +367,13 @@ public class CraftBlock implements Block { return (biome == null) ? Biome.CUSTOM : biome; } diff --git a/patches/server/0825-Prevent-tile-entity-copies-loading-chunks.patch b/patches/server/0825-Prevent-tile-entity-copies-loading-chunks.patch index 48ac8c2020..80458627bf 100644 --- a/patches/server/0825-Prevent-tile-entity-copies-loading-chunks.patch +++ b/patches/server/0825-Prevent-tile-entity-copies-loading-chunks.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Prevent tile entity copies loading chunks diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index f1155e7df523d2030c3fe9b488a77fae5ad2febd..fd6d2add5d6ecaab8824c90c4cf82254aeee37b6 100644 +index 2339f46f6a3d5c50179c78515d2bafba588f3aa0..0150f1935bfc7b97f72683699dc265ac8508a8fb 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -3303,7 +3303,12 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -3309,7 +3309,12 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic BlockPos blockposition = BlockEntity.getPosFromTag(nbttagcompound); if (this.player.level.isLoaded(blockposition)) { diff --git a/patches/server/0826-Use-username-instead-of-display-name-in-PlayerList-g.patch b/patches/server/0826-Use-username-instead-of-display-name-in-PlayerList-g.patch index 0472e82cb8..72ef000460 100644 --- a/patches/server/0826-Use-username-instead-of-display-name-in-PlayerList-g.patch +++ b/patches/server/0826-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 1cdf4d8794e982ff24c50a0267fbb024bbaba668..aa67dd615a06d5f109a8f57dd3e6413e159cad2b 100644 +index e64f806326a5400eab14e6ebe59901aa1ebea110..168c53eee5bbf84c11a0b0f654e4540e4d082c2a 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -1421,7 +1421,7 @@ public abstract class PlayerList { +@@ -1423,7 +1423,7 @@ public abstract class PlayerList { // CraftBukkit start public ServerStatsCounter getPlayerStats(ServerPlayer entityhuman) { ServerStatsCounter serverstatisticmanager = entityhuman.getStats(); diff --git a/patches/server/0828-Pass-ServerLevel-for-gamerule-callbacks.patch b/patches/server/0828-Pass-ServerLevel-for-gamerule-callbacks.patch index daea405f74..787e4431e3 100644 --- a/patches/server/0828-Pass-ServerLevel-for-gamerule-callbacks.patch +++ b/patches/server/0828-Pass-ServerLevel-for-gamerule-callbacks.patch @@ -18,10 +18,10 @@ index 5b46cabf4f2e2a1f7feaad378dd98d64aeef8671..51b3db0b6c2cede95b584268e035c0fb if (dedicatedserverproperties.enableQuery) { diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index fd6d2add5d6ecaab8824c90c4cf82254aeee37b6..709a0adbb4f869f6e5016ddd009aecfb428228fd 100644 +index 0150f1935bfc7b97f72683699dc265ac8508a8fb..aed804e2d146f608587efa31deefe65f84241bbe 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -2894,7 +2894,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -2900,7 +2900,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic this.player = this.server.getPlayerList().respawn(this.player, false, RespawnReason.DEATH); if (this.server.isHardcore()) { this.player.setGameMode(GameType.SPECTATOR, org.bukkit.event.player.PlayerGameModeChangeEvent.Cause.HARDCORE_DEATH, null); // Paper @@ -158,10 +158,10 @@ index de713f1ca1d61a6b1fca2b66de9162556d102449..edd2c9d0cf5a81c779011cb4215d496a this.onChanged(server); } diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -index 8c566479d0936a4d21a40adb87f6272158b217bd..831c746e9aeab0fd5d6b1eec2fad4d9222c2f359 100644 +index 75a8c83779f97c430815964e09f1c3ea61ff4659..4f2b709140e30d1676cafc0d4b1d8d3bf4f7e96e 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -@@ -1924,7 +1924,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -1910,7 +1910,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { // Paper end GameRules.Value handle = this.getHandle().getGameRules().getRule(CraftWorld.getGameRulesNMS().get(rule)); handle.deserialize(event.getValue()); // Paper @@ -170,7 +170,7 @@ index 8c566479d0936a4d21a40adb87f6272158b217bd..831c746e9aeab0fd5d6b1eec2fad4d92 return true; } -@@ -1964,7 +1964,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -1950,7 +1950,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { // Paper end GameRules.Value handle = this.getHandle().getGameRules().getRule(CraftWorld.getGameRulesNMS().get(rule.getName())); handle.deserialize(event.getValue()); // Paper diff --git a/patches/server/0830-WorldCreator-keepSpawnLoaded.patch b/patches/server/0830-WorldCreator-keepSpawnLoaded.patch index 18bb31ffcd..5f05ddfb3c 100644 --- a/patches/server/0830-WorldCreator-keepSpawnLoaded.patch +++ b/patches/server/0830-WorldCreator-keepSpawnLoaded.patch @@ -5,10 +5,10 @@ Subject: [PATCH] WorldCreator#keepSpawnLoaded diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 1bd1565b02fdcf22e0cb550290ad1ae792002cc0..733b18de16e7924ae81a9255bcd061f95628630f 100644 +index 49eec475f702b9ac35be92e92b77c047ee6e35bb..1eca37136dedd5bd8e59446cda7476cab46fb0f6 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -1249,6 +1249,7 @@ public final class CraftServer implements Server { +@@ -1250,6 +1250,7 @@ public final class CraftServer implements Server { internal.setSpawnSettings(true, true); // Paper - move up diff --git a/patches/server/0839-Do-not-accept-invalid-client-settings.patch b/patches/server/0839-Do-not-accept-invalid-client-settings.patch index d283217e2e..92e9dc90a5 100644 --- a/patches/server/0839-Do-not-accept-invalid-client-settings.patch +++ b/patches/server/0839-Do-not-accept-invalid-client-settings.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Do not accept invalid client settings diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 709a0adbb4f869f6e5016ddd009aecfb428228fd..9ff3af312429a0cd9479d85040b73b5c547c5367 100644 +index aed804e2d146f608587efa31deefe65f84241bbe..37ad18b6d2a1c537b1cb3d622b6bae2f8100445c 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -3482,6 +3482,13 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -3488,6 +3488,13 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic @Override public void handleClientInformation(ServerboundClientInformationPacket packet) { PacketUtils.ensureRunningOnSameThread(packet, this, this.player.getLevel()); diff --git a/patches/server/0845-Prevent-entity-loading-causing-async-lookups.patch b/patches/server/0845-Prevent-entity-loading-causing-async-lookups.patch index 3496681ae3..29b61b8947 100644 --- a/patches/server/0845-Prevent-entity-loading-causing-async-lookups.patch +++ b/patches/server/0845-Prevent-entity-loading-causing-async-lookups.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Prevent entity loading causing async lookups diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index 83e201e34a6628faec9ba7497a1025aa207a103e..7e10c68fba3c833d414ffc80426615eef85b2c47 100644 +index 507db20f8622d8f26063150ded79e767e61be553..51176c3fbb00854ffd85ebf5f4fd4e439afa0ad8 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -789,6 +789,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -790,6 +790,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { public void baseTick() { this.level.getProfiler().push("entityBaseTick"); diff --git a/patches/server/0846-Throw-exception-on-world-create-while-being-ticked.patch b/patches/server/0846-Throw-exception-on-world-create-while-being-ticked.patch index 28537aede4..06073529ff 100644 --- a/patches/server/0846-Throw-exception-on-world-create-while-being-ticked.patch +++ b/patches/server/0846-Throw-exception-on-world-create-while-being-ticked.patch @@ -45,10 +45,10 @@ index 3e59620c84b3aa93d8ce41b0e9901a1621bb48df..682005e4b19ba3959d4e3a66475487da this.profiler.popPush("connection"); MinecraftTimings.connectionTimer.startTiming(); // Spigot diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 733b18de16e7924ae81a9255bcd061f95628630f..3713ce052cef9ccbee951473556cba6e0d1b485f 100644 +index 1eca37136dedd5bd8e59446cda7476cab46fb0f6..a141cd0d415e312da0a92349eb9cae3ccda3c397 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -845,6 +845,11 @@ public final class CraftServer implements Server { +@@ -846,6 +846,11 @@ public final class CraftServer implements Server { return new ArrayList(this.worlds.values()); } @@ -60,7 +60,7 @@ index 733b18de16e7924ae81a9255bcd061f95628630f..3713ce052cef9ccbee951473556cba6e public DedicatedPlayerList getHandle() { return this.playerList; } -@@ -1126,6 +1131,7 @@ public final class CraftServer implements Server { +@@ -1127,6 +1132,7 @@ public final class CraftServer implements Server { @Override public World createWorld(WorldCreator creator) { Preconditions.checkState(this.console.getAllLevels().iterator().hasNext(), "Cannot create additional worlds on STARTUP"); @@ -68,7 +68,7 @@ index 733b18de16e7924ae81a9255bcd061f95628630f..3713ce052cef9ccbee951473556cba6e Validate.notNull(creator, "Creator may not be null"); String name = creator.name(); -@@ -1264,6 +1270,7 @@ public final class CraftServer implements Server { +@@ -1265,6 +1271,7 @@ public final class CraftServer implements Server { @Override public boolean unloadWorld(World world, boolean save) { diff --git a/patches/server/0850-Add-option-for-strict-advancement-dimension-checks.patch b/patches/server/0850-Add-option-for-strict-advancement-dimension-checks.patch index 8a1dd11d68..22c108d157 100644 --- a/patches/server/0850-Add-option-for-strict-advancement-dimension-checks.patch +++ b/patches/server/0850-Add-option-for-strict-advancement-dimension-checks.patch @@ -11,10 +11,10 @@ distance trigger. This adds a config option to ignore that and use the exact dimension key of the worlds involved. diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java -index c9529b1157bd8c813f8e303dd35b6416d5a72838..ad63ba47e8d48daa80e00ca3bc26d68672cef3b3 100644 +index 212d61f1c0b9d7039595ec098b7e7d99a898bc4e..b30972c3ab19795e26589cd0cdd54c43414fe368 100644 --- a/src/main/java/net/minecraft/server/level/ServerPlayer.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java -@@ -1271,6 +1271,12 @@ public class ServerPlayer extends Player { +@@ -1273,6 +1273,12 @@ public class ServerPlayer extends Player { // CraftBukkit start ResourceKey maindimensionkey = CraftDimensionUtil.getMainDimensionKey(origin); ResourceKey maindimensionkey1 = CraftDimensionUtil.getMainDimensionKey(this.level); diff --git a/patches/server/0853-Don-t-broadcast-messages-to-command-blocks.patch b/patches/server/0853-Don-t-broadcast-messages-to-command-blocks.patch index 58244b0cf8..7ff69f974f 100644 --- a/patches/server/0853-Don-t-broadcast-messages-to-command-blocks.patch +++ b/patches/server/0853-Don-t-broadcast-messages-to-command-blocks.patch @@ -20,10 +20,10 @@ index 7c7e5f3c0f9cd1f16192a8fc8163da9b2d9519d5..888936385196a178ab8b730fd5e4fff4 Date date = new Date(); diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 3713ce052cef9ccbee951473556cba6e0d1b485f..33fe6f01cfef25482001a04bdd82367424d69317 100644 +index a141cd0d415e312da0a92349eb9cae3ccda3c397..8be0badce29413922dfd744b946ca3e4403bc4f6 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -1768,7 +1768,7 @@ public final class CraftServer implements Server { +@@ -1769,7 +1769,7 @@ public final class CraftServer implements Server { // Paper end Set recipients = new HashSet<>(); for (Permissible permissible : this.getPluginManager().getPermissionSubscriptions(permission)) { diff --git a/patches/server/0856-Don-t-print-component-in-resource-pack-rejection-mes.patch b/patches/server/0856-Don-t-print-component-in-resource-pack-rejection-mes.patch index 55c8ce8658..c1293f4258 100644 --- a/patches/server/0856-Don-t-print-component-in-resource-pack-rejection-mes.patch +++ b/patches/server/0856-Don-t-print-component-in-resource-pack-rejection-mes.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Don't print component in resource pack rejection message diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 798eaaaed23c55728a7c48ea900db873cf5c5197..03ee980ae8fdaa174c937f1e5175020f0626556e 100644 +index 2a4c4180a8ac2f3b2cbb75dc2095ff62bfb3289e..735e16fc2ad7a17accde96c51231dd4bbce109ed 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -2033,7 +2033,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -2034,7 +2034,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic public void handleResourcePackResponse(ServerboundResourcePackPacket packet) { PacketUtils.ensureRunningOnSameThread(packet, this, this.player.getLevel()); if (packet.getAction() == ServerboundResourcePackPacket.Action.DECLINED && this.server.isResourcePackRequired()) { diff --git a/patches/server/0857-Add-Player-getFishHook.patch b/patches/server/0857-Add-Player-getFishHook.patch index 7302cc061d..29b7b33f1c 100644 --- a/patches/server/0857-Add-Player-getFishHook.patch +++ b/patches/server/0857-Add-Player-getFishHook.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Add Player#getFishHook diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java -index b326654ef96cfd3f5cff476203844c2fb932b9b6..d3644b268c10fd839338a5b1bfc42b4ae5286555 100644 +index 86b5532b3be5484c68152a777b976bc44008b0df..7a2a73edc13930f34eb11d9d0802ae9ec5cd8d40 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java -@@ -160,6 +160,15 @@ public class CraftHumanEntity extends CraftLivingEntity implements HumanEntity { +@@ -161,6 +161,15 @@ public class CraftHumanEntity extends CraftLivingEntity implements HumanEntity { return new Location(worldServer.getWorld(), bed.getX(), bed.getY(), bed.getZ()); } // Paper end diff --git a/patches/server/0859-Add-various-missing-EntityDropItemEvent-calls.patch b/patches/server/0859-Add-various-missing-EntityDropItemEvent-calls.patch index 9b3b037834..c2bbb2f736 100644 --- a/patches/server/0859-Add-various-missing-EntityDropItemEvent-calls.patch +++ b/patches/server/0859-Add-various-missing-EntityDropItemEvent-calls.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Add various missing EntityDropItemEvent calls diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index 70fe8f109d86265200b2943e504610a2fb386420..496ba4f6a6a9e921bb7b311d96ff7cd7962eee11 100644 +index 51176c3fbb00854ffd85ebf5f4fd4e439afa0ad8..95ff9415fea96e1525c97a185e7890b5f3c70fad 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -2557,6 +2557,14 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -2558,6 +2558,14 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { stack.setCount(0); // Paper - destroy this item - if this ever leaks due to game bugs, ensure it doesn't dupe entityitem.setDefaultPickUpDelay(); diff --git a/patches/server/0860-Add-some-minimal-debug-information-to-chat-packet-er.patch b/patches/server/0860-Add-some-minimal-debug-information-to-chat-packet-er.patch index 9d37609ab7..ef123472fb 100644 --- a/patches/server/0860-Add-some-minimal-debug-information-to-chat-packet-er.patch +++ b/patches/server/0860-Add-some-minimal-debug-information-to-chat-packet-er.patch @@ -6,10 +6,10 @@ Subject: [PATCH] Add some minimal debug information to chat packet errors TODO: potentially add some kick leeway diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 5c85a9d609c02498a8f883bf44f5e85c21275318..05841b6e44396ed49618f5b478abe78fde0a73d0 100644 +index 27adfbd9c8333cd87b7a38fbbfa31e50ae3f105c..a522600f96e696561dc26d8154dd5072963935db 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -2286,7 +2286,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -2292,7 +2292,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic private Optional tryHandleChat(String message, Instant timestamp, LastSeenMessages.Update acknowledgment) { if (!this.updateChatOrder(timestamp)) { diff --git a/patches/server/0862-Fix-Spigot-Config-not-using-commands.spam-exclusions.patch b/patches/server/0862-Fix-Spigot-Config-not-using-commands.spam-exclusions.patch index cd448ed276..d27aea2a84 100644 --- a/patches/server/0862-Fix-Spigot-Config-not-using-commands.spam-exclusions.patch +++ b/patches/server/0862-Fix-Spigot-Config-not-using-commands.spam-exclusions.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Fix Spigot Config not using commands.spam-exclusions diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 05841b6e44396ed49618f5b478abe78fde0a73d0..82d7506988b0e443bf16be93a9e17257aeff9472 100644 +index a522600f96e696561dc26d8154dd5072963935db..99fe650529e267f8026c5019eab0295b2cddfc53 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -2533,7 +2533,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -2539,7 +2539,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic } // Spigot end // this.chatSpamTickCount += 20; diff --git a/patches/server/0863-More-Teleport-API.patch b/patches/server/0863-More-Teleport-API.patch index fcba19ed6f..32735d1984 100644 --- a/patches/server/0863-More-Teleport-API.patch +++ b/patches/server/0863-More-Teleport-API.patch @@ -7,10 +7,10 @@ Subject: [PATCH] More Teleport API public net.minecraft.server.network.ServerGamePacketListenerImpl internalTeleport(DDDFFLjava/util/Set;Z)V diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index dbc815053fc022cc62cd4fc418fecdf64a37a0a9..3c553407834768303ed858aba8aec0e13a7f4c13 100644 +index f83fd2dd742533285cde99bbc5180a34feb09c31..014a94c5b2f7c900f33a8e29a64d61690c94b150 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -1709,11 +1709,17 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -1710,11 +1710,17 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic return false; // CraftBukkit - Return event status } @@ -31,7 +31,7 @@ index dbc815053fc022cc62cd4fc418fecdf64a37a0a9..3c553407834768303ed858aba8aec0e1 d0 = to.getX(); d1 = to.getY(); diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java -index 7df1eebce5b62214943e55314e9ec98f056fa330..2aee8aacd50431c18ff28af678348ec27ede6b6b 100644 +index 6478faa20adea00349600620c2ab7d559e2fc3b7..52f8a76832b05061dc80381220c866316d4a089d 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java @@ -561,15 +561,36 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity { @@ -74,10 +74,10 @@ index 7df1eebce5b62214943e55314e9ec98f056fa330..2aee8aacd50431c18ff28af678348ec2 // Let the server handle cross world teleports if (location.getWorld() != null && !location.getWorld().equals(this.getWorld())) { diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -index 93388dbf5768ee622374bc1247aaee9324bfaf9a..1b9c9e8e0a3c94022360b789e87c7a104da08995 100644 +index 85c28926533c3159d42e8e7d90051472613dda8c..6e0e0e8405873069274c574240feea793e287f0c 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -@@ -1261,13 +1261,100 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -1259,13 +1259,100 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @Override public void setRotation(float yaw, float pitch) { @@ -179,7 +179,7 @@ index 93388dbf5768ee622374bc1247aaee9324bfaf9a..1b9c9e8e0a3c94022360b789e87c7a10 location.checkFinite(); ServerPlayer entity = this.getHandle(); -@@ -1280,7 +1367,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -1278,7 +1365,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player { return false; } @@ -188,7 +188,7 @@ index 93388dbf5768ee622374bc1247aaee9324bfaf9a..1b9c9e8e0a3c94022360b789e87c7a10 return false; } -@@ -1298,7 +1385,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -1296,7 +1383,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player { } // If this player is riding another entity, we must dismount before teleporting. @@ -197,7 +197,7 @@ index 93388dbf5768ee622374bc1247aaee9324bfaf9a..1b9c9e8e0a3c94022360b789e87c7a10 // SPIGOT-5509: Wakeup, similar to riding if (this.isSleeping()) { -@@ -1314,13 +1401,13 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -1312,13 +1399,13 @@ public class CraftPlayer extends CraftHumanEntity implements Player { ServerLevel toWorld = ((CraftWorld) to.getWorld()).getHandle(); // Close any foreign inventory diff --git a/patches/server/0864-Add-EntityPortalReadyEvent.patch b/patches/server/0864-Add-EntityPortalReadyEvent.patch index 76eb1492d0..7f95e0ef54 100644 --- a/patches/server/0864-Add-EntityPortalReadyEvent.patch +++ b/patches/server/0864-Add-EntityPortalReadyEvent.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Add EntityPortalReadyEvent diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index 496ba4f6a6a9e921bb7b311d96ff7cd7962eee11..32a74fa1afeef72c9014ded08ffb29eba7be1a1b 100644 +index 95ff9415fea96e1525c97a185e7890b5f3c70fad..239ace465b2911c0026649e6dd8d9168d9e39845 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -2912,6 +2912,13 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -2913,6 +2913,13 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { if (true && !this.isPassenger() && this.portalTime++ >= i) { // CraftBukkit this.level.getProfiler().push("portal"); this.portalTime = i; @@ -22,7 +22,7 @@ index 496ba4f6a6a9e921bb7b311d96ff7cd7962eee11..32a74fa1afeef72c9014ded08ffb29eb this.setPortalCooldown(); // CraftBukkit start if (this instanceof ServerPlayer) { -@@ -2919,6 +2926,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -2920,6 +2927,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { } else { this.changeDimension(worldserver1); } diff --git a/patches/server/0866-Send-block-entities-after-destroy-prediction.patch b/patches/server/0866-Send-block-entities-after-destroy-prediction.patch index dddbebae62..0e11a088c0 100644 --- a/patches/server/0866-Send-block-entities-after-destroy-prediction.patch +++ b/patches/server/0866-Send-block-entities-after-destroy-prediction.patch @@ -57,10 +57,10 @@ index 161a810a8c4bd4c916c54df49c44c504130cb28e..45b48da09eafa8482836e49768426069 } } diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 3c553407834768303ed858aba8aec0e13a7f4c13..0909716c7b76bc07a2cd3caee4bede0a83255a06 100644 +index 014a94c5b2f7c900f33a8e29a64d61690c94b150..385e7648dd2e9e812833010ed90bd8e6011082d8 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -1855,8 +1855,28 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -1856,8 +1856,28 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic return; } // Paper end - Don't allow digging in unloaded chunks diff --git a/patches/server/0867-Warn-on-plugins-accessing-faraway-chunks.patch b/patches/server/0867-Warn-on-plugins-accessing-faraway-chunks.patch index d91539074d..3c2781919d 100644 --- a/patches/server/0867-Warn-on-plugins-accessing-faraway-chunks.patch +++ b/patches/server/0867-Warn-on-plugins-accessing-faraway-chunks.patch @@ -18,10 +18,10 @@ index 4ace5a32e8d17303a4b5d9e8935a803d7c0df409..174f5ff8f827dab2d85cee525429d46b private static boolean isOutsideSpawnableHeight(int y) { diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -index 831c746e9aeab0fd5d6b1eec2fad4d9222c2f359..86ffc869b57410fd4993c0fd0ae000da2e2c070c 100644 +index 4f2b709140e30d1676cafc0d4b1d8d3bf4f7e96e..8d3a32a0538a6065fd0725721ab8a1a011c4d64a 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -@@ -313,9 +313,24 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -309,9 +309,24 @@ public class CraftWorld extends CraftRegionAccessor implements World { public boolean setSpawnLocation(int x, int y, int z) { return this.setSpawnLocation(x, y, z, 0.0F); } @@ -46,7 +46,7 @@ index 831c746e9aeab0fd5d6b1eec2fad4d9222c2f359..86ffc869b57410fd4993c0fd0ae000da // Paper start - add ticket to hold chunk for a little while longer if plugin accesses it net.minecraft.world.level.chunk.LevelChunk chunk = this.world.getChunkSource().getChunkAtIfLoadedImmediately(x, z); if (chunk == null) { -@@ -430,6 +445,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -426,6 +441,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { @Override public boolean regenerateChunk(int x, int z) { org.spigotmc.AsyncCatcher.catchOp("chunk regenerate"); // Spigot @@ -54,7 +54,7 @@ index 831c746e9aeab0fd5d6b1eec2fad4d9222c2f359..86ffc869b57410fd4993c0fd0ae000da // Paper start - implement regenerateChunk method final ServerLevel serverLevel = this.world; final net.minecraft.server.level.ServerChunkCache serverChunkCache = serverLevel.getChunkSource(); -@@ -526,6 +542,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -522,6 +538,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { @Override public boolean loadChunk(int x, int z, boolean generate) { org.spigotmc.AsyncCatcher.catchOp("chunk load"); // Spigot @@ -62,7 +62,7 @@ index 831c746e9aeab0fd5d6b1eec2fad4d9222c2f359..86ffc869b57410fd4993c0fd0ae000da // Paper start - Optimize this method ChunkPos chunkPos = new ChunkPos(x, z); ChunkAccess immediate = world.getChunkSource().getChunkAtIfLoadedImmediately(x, z); // Paper -@@ -589,6 +606,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -585,6 +602,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { @Override public boolean addPluginChunkTicket(int x, int z, Plugin plugin) { @@ -70,7 +70,7 @@ index 831c746e9aeab0fd5d6b1eec2fad4d9222c2f359..86ffc869b57410fd4993c0fd0ae000da Preconditions.checkArgument(plugin != null, "null plugin"); Preconditions.checkArgument(plugin.isEnabled(), "plugin is not enabled"); -@@ -657,6 +675,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -653,6 +671,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { @Override public void setChunkForceLoaded(int x, int z, boolean forced) { @@ -78,7 +78,7 @@ index 831c746e9aeab0fd5d6b1eec2fad4d9222c2f359..86ffc869b57410fd4993c0fd0ae000da this.getHandle().setChunkForced(x, z, forced); } -@@ -968,6 +987,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -959,6 +978,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { @Override public int getHighestBlockYAt(int x, int z, org.bukkit.HeightMap heightMap) { @@ -86,7 +86,7 @@ index 831c746e9aeab0fd5d6b1eec2fad4d9222c2f359..86ffc869b57410fd4993c0fd0ae000da // Transient load for this tick return this.world.getChunk(x >> 4, z >> 4).getHeight(CraftHeightMap.toNMS(heightMap), x, z); } -@@ -2344,6 +2364,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { +@@ -2330,6 +2350,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { // Spigot end // Paper start public java.util.concurrent.CompletableFuture getChunkAtAsync(int x, int z, boolean gen, boolean urgent) { diff --git a/patches/server/0868-Custom-Chat-Completion-Suggestions-API.patch b/patches/server/0868-Custom-Chat-Completion-Suggestions-API.patch index a2a02a5464..599e55c500 100644 --- a/patches/server/0868-Custom-Chat-Completion-Suggestions-API.patch +++ b/patches/server/0868-Custom-Chat-Completion-Suggestions-API.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Custom Chat Completion Suggestions API diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -index 1b9c9e8e0a3c94022360b789e87c7a104da08995..18e8fb6c16cac2b45de3e42a5f9dcd098e5633e6 100644 +index 6e0e0e8405873069274c574240feea793e287f0c..b764d508951e19634aface33b618bd3d3e114479 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -@@ -670,6 +670,22 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -674,6 +674,22 @@ public class CraftPlayer extends CraftHumanEntity implements Player { this.getHandle().getServer().getPlayerList().sendPlayerPermissionLevel(this.getHandle(), level, false); } diff --git a/patches/server/0870-Collision-API.patch b/patches/server/0870-Collision-API.patch index 0392537ee4..36e708c8de 100644 --- a/patches/server/0870-Collision-API.patch +++ b/patches/server/0870-Collision-API.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Collision API diff --git a/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java b/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java -index 28c9ea1d061ef6a8b27ee43f0a2f7703d7cc3c0e..0087ced09e0337d88fc210acb6772b6375047bf4 100644 +index f4f1150e6be2bff0b8561451594691977a5f1d56..3742e0b32e29d7dde0c2bd3d80348f8fb7b8aaf0 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java -@@ -998,5 +998,12 @@ public abstract class CraftRegionAccessor implements RegionAccessor { +@@ -1019,5 +1019,12 @@ public abstract class CraftRegionAccessor implements RegionAccessor { return this.getHandle().clip(new net.minecraft.world.level.ClipContext(vec3d, vec3d1, net.minecraft.world.level.ClipContext.Block.COLLIDER, net.minecraft.world.level.ClipContext.Fluid.NONE, null)).getType() == net.minecraft.world.phys.HitResult.Type.MISS; } @@ -22,7 +22,7 @@ index 28c9ea1d061ef6a8b27ee43f0a2f7703d7cc3c0e..0087ced09e0337d88fc210acb6772b63 // Paper end } diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java -index 2aee8aacd50431c18ff28af678348ec27ede6b6b..b6fc36af0fccf1a4ab0262b36da79d5eb63e73e3 100644 +index 52f8a76832b05061dc80381220c866316d4a089d..73bd76b7bfcffc1d9dac926d7a781d048f4f2350 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java @@ -1415,4 +1415,19 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity { diff --git a/patches/server/0872-Remove-invalid-signature-login-stacktrace.patch b/patches/server/0872-Remove-invalid-signature-login-stacktrace.patch index 10b7436b9e..f7887653d9 100644 --- a/patches/server/0872-Remove-invalid-signature-login-stacktrace.patch +++ b/patches/server/0872-Remove-invalid-signature-login-stacktrace.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Remove invalid signature login stacktrace diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 0f6c2725ff7e9aa6bcef16658aefcbc586d979b5..959e8d2cfa195e28239da03464e45563fcdd1244 100644 +index 6614b6ee463f6f68d14894addcbc79a6a5be5b10..7810ab5bd1791ff5323b7302a6351a987b93bae3 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -3612,7 +3612,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -3618,7 +3618,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic this.resetPlayerChatState(remotechatsession_a.validate(this.player.getGameProfile(), signaturevalidator, Duration.ZERO)); } catch (ProfilePublicKey.ValidationException profilepublickey_b) { diff --git a/patches/server/0873-Block-Ticking-API.patch b/patches/server/0873-Block-Ticking-API.patch index 86598b006e..944afe69ba 100644 --- a/patches/server/0873-Block-Ticking-API.patch +++ b/patches/server/0873-Block-Ticking-API.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Block Ticking API diff --git a/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java b/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java -index 0d30b388d8d93a6dbbf8dfb30d26eb44c73e1e4e..962c950ca9c7e047a3aec215d4faa73676049d36 100644 +index a10ca7df7863d76e2b32bf414437cbfc6d35c9b7..b6c4f3d34603929a56073444be5f25fda15ff0c7 100644 --- a/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java +++ b/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java -@@ -756,5 +756,21 @@ public class CraftBlock implements Block { +@@ -755,5 +755,21 @@ public class CraftBlock implements Block { public boolean isValidTool(ItemStack itemStack) { return getDrops(itemStack).size() != 0; } @@ -31,10 +31,10 @@ index 0d30b388d8d93a6dbbf8dfb30d26eb44c73e1e4e..962c950ca9c7e047a3aec215d4faa736 // Paper end } diff --git a/src/main/java/org/bukkit/craftbukkit/block/data/CraftBlockData.java b/src/main/java/org/bukkit/craftbukkit/block/data/CraftBlockData.java -index a585deb47ceb721489e0da4a09a94922fef86a3f..27344a44b776311801b03034730fd6710190e11a 100644 +index 9d09b3064fc0474170e6d584dd3ccb9899cfbd42..c061f76ff6ccf64d9eb53045e9bfabe2021e91ec 100644 --- a/src/main/java/org/bukkit/craftbukkit/block/data/CraftBlockData.java +++ b/src/main/java/org/bukkit/craftbukkit/block/data/CraftBlockData.java -@@ -675,4 +675,11 @@ public class CraftBlockData implements BlockData { +@@ -676,4 +676,11 @@ public class CraftBlockData implements BlockData { public void mirror(Mirror mirror) { this.state = this.state.mirror(net.minecraft.world.level.block.Mirror.valueOf(mirror.name())); } diff --git a/patches/server/0874-Add-Velocity-IP-Forwarding-Support.patch b/patches/server/0874-Add-Velocity-IP-Forwarding-Support.patch index 4a8092f783..6745465173 100644 --- a/patches/server/0874-Add-Velocity-IP-Forwarding-Support.patch +++ b/patches/server/0874-Add-Velocity-IP-Forwarding-Support.patch @@ -213,10 +213,10 @@ index 3fcd7bfdb8945b276c94a263e9da6b85ce470366..3431b1132e55c53cda7cf47f021f2306 } diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index c37cb8a3d7f1d463db8d3719e6a4e00446b32e00..0ba8446065def1b120fd73241de5bc14d60d3b82 100644 +index 8be0badce29413922dfd744b946ca3e4403bc4f6..e769f7b0904814ee63e2a73dca57e5dc33382fba 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -774,7 +774,7 @@ public final class CraftServer implements Server { +@@ -775,7 +775,7 @@ public final class CraftServer implements Server { @Override public long getConnectionThrottle() { // Spigot Start - Automatically set connection throttle for bungee configurations diff --git a/patches/server/0889-Set-position-before-player-sending-on-dimension-chan.patch b/patches/server/0889-Set-position-before-player-sending-on-dimension-chan.patch index ed62ec7656..3c700c1411 100644 --- a/patches/server/0889-Set-position-before-player-sending-on-dimension-chan.patch +++ b/patches/server/0889-Set-position-before-player-sending-on-dimension-chan.patch @@ -7,10 +7,10 @@ This causes a moment where the player entity is sent with the previous location, teleport packet which is sent shortly after is meant to correct that. diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java -index ad63ba47e8d48daa80e00ca3bc26d68672cef3b3..cf80b3cc36919b1ab448d472089b98c4edc9fe4d 100644 +index b30972c3ab19795e26589cd0cdd54c43414fe368..c5dc769d13fbc2a88a731d42669d0906ee306e4b 100644 --- a/src/main/java/net/minecraft/server/level/ServerPlayer.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java -@@ -1174,6 +1174,7 @@ public class ServerPlayer extends Player { +@@ -1176,6 +1176,7 @@ public class ServerPlayer extends Player { // CraftBukkit end this.setLevel(worldserver); diff --git a/patches/server/0892-Add-getDrops-to-BlockState.patch b/patches/server/0892-Add-getDrops-to-BlockState.patch index a83779ec9a..2984a969f8 100644 --- a/patches/server/0892-Add-getDrops-to-BlockState.patch +++ b/patches/server/0892-Add-getDrops-to-BlockState.patch @@ -7,10 +7,10 @@ Originally added isPreferredTool to BlockData but upstream added that. diff --git a/src/main/java/org/bukkit/craftbukkit/block/CraftBlockState.java b/src/main/java/org/bukkit/craftbukkit/block/CraftBlockState.java -index 966ac60daebb7bb211ab8096fc0c5f33db67320a..a8ab1d3ee81664193be39d2735d6495136e0e310 100644 +index 3e1d36a8c65e6567ac3b78903a25d5828ab74ea5..577a352dab0f8a71558cb6dedce788e78053ef52 100644 --- a/src/main/java/org/bukkit/craftbukkit/block/CraftBlockState.java +++ b/src/main/java/org/bukkit/craftbukkit/block/CraftBlockState.java -@@ -330,5 +330,33 @@ public class CraftBlockState implements BlockState { +@@ -331,5 +331,33 @@ public class CraftBlockState implements BlockState { public boolean isCollidable() { return this.data.getBlock().hasCollision; } diff --git a/patches/server/0893-Fix-a-bunch-of-vanilla-bugs.patch b/patches/server/0893-Fix-a-bunch-of-vanilla-bugs.patch index 998a3505a3..9df62d2ff5 100644 --- a/patches/server/0893-Fix-a-bunch-of-vanilla-bugs.patch +++ b/patches/server/0893-Fix-a-bunch-of-vanilla-bugs.patch @@ -41,10 +41,10 @@ https://bugs.mojang.com/browse/MC-262422 Co-authored-by: William Blake Galbreath diff --git a/src/main/java/net/minecraft/core/dispenser/DispenseItemBehavior.java b/src/main/java/net/minecraft/core/dispenser/DispenseItemBehavior.java -index 1023f91b6a23fc974ba709ec09834d9faae8003a..6fedf7381762ae3d76c4801ed6d5c0844c6c857b 100644 +index 9b56f742443ad98994acc34630f1cef75a00ca8a..618ad17e4f10f58994db55b82b70fbb141e3579e 100644 --- a/src/main/java/net/minecraft/core/dispenser/DispenseItemBehavior.java +++ b/src/main/java/net/minecraft/core/dispenser/DispenseItemBehavior.java -@@ -351,7 +351,7 @@ public interface DispenseItemBehavior { +@@ -352,7 +352,7 @@ public interface DispenseItemBehavior { } } // CraftBukkit end diff --git a/patches/server/0897-Correctly-handle-interactions-with-items-on-cooldown.patch b/patches/server/0897-Correctly-handle-interactions-with-items-on-cooldown.patch index b342a73515..3c87b5be58 100644 --- a/patches/server/0897-Correctly-handle-interactions-with-items-on-cooldown.patch +++ b/patches/server/0897-Correctly-handle-interactions-with-items-on-cooldown.patch @@ -30,10 +30,10 @@ index 16a1416cb2ce01071a033c5049edfb60b614d56a..1d33c02088c150189d7f4b0aa27f6a1d this.interactResult = event.useItemInHand() == Event.Result.DENY; this.interactPosition = blockposition.immutable(); diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java -index d2c0461bcc8e4c08bf375f76fad0c10086c40fd4..819c9c020f4d5a1373f68850134960d24b8fc308 100644 +index 4c957ccae26fcad437234051481e2a1824d17f76..0f4154560047735562b583081a9edb314f3a8a74 100644 --- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java +++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java -@@ -515,6 +515,12 @@ public class CraftEventFactory { +@@ -517,6 +517,12 @@ public class CraftEventFactory { } public static PlayerInteractEvent callPlayerInteractEvent(net.minecraft.world.entity.player.Player who, Action action, BlockPos position, Direction direction, ItemStack itemstack, boolean cancelledBlock, InteractionHand hand, Vec3 hitVec) { @@ -46,7 +46,7 @@ index d2c0461bcc8e4c08bf375f76fad0c10086c40fd4..819c9c020f4d5a1373f68850134960d2 // Paper end Player player = (who == null) ? null : (Player) who.getBukkitEntity(); CraftItemStack itemInHand = CraftItemStack.asCraftMirror(itemstack); -@@ -548,6 +554,11 @@ public class CraftEventFactory { +@@ -550,6 +556,11 @@ public class CraftEventFactory { if (cancelledBlock) { event.setUseInteractedBlock(Event.Result.DENY); } diff --git a/patches/server/0898-Add-PlayerInventorySlotChangeEvent.patch b/patches/server/0898-Add-PlayerInventorySlotChangeEvent.patch index 5eca8e0ad2..d9b7732756 100644 --- a/patches/server/0898-Add-PlayerInventorySlotChangeEvent.patch +++ b/patches/server/0898-Add-PlayerInventorySlotChangeEvent.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Add PlayerInventorySlotChangeEvent diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java -index cf80b3cc36919b1ab448d472089b98c4edc9fe4d..2eface459a431038db994f49f77a5834039cdaf6 100644 +index c5dc769d13fbc2a88a731d42669d0906ee306e4b..6fdb22809195fc2ba95ee22a5523eeabc2f2c4da 100644 --- a/src/main/java/net/minecraft/server/level/ServerPlayer.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java -@@ -328,6 +328,25 @@ public class ServerPlayer extends Player { +@@ -330,6 +330,25 @@ public class ServerPlayer extends Player { } } diff --git a/patches/server/0899-Elder-Guardian-appearance-API.patch b/patches/server/0899-Elder-Guardian-appearance-API.patch index 8c3d09bf7e..cf2690c385 100644 --- a/patches/server/0899-Elder-Guardian-appearance-API.patch +++ b/patches/server/0899-Elder-Guardian-appearance-API.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Elder Guardian appearance API diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -index 18e8fb6c16cac2b45de3e42a5f9dcd098e5633e6..30c1cd3b0c1f5382ace76c1a2c5461fe8cc61339 100644 +index b764d508951e19634aface33b618bd3d3e114479..1a2eba89fafe45a1221b66a21d9f8dbdceb0e799 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -@@ -3153,6 +3153,13 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -3161,6 +3161,13 @@ public class CraftPlayer extends CraftHumanEntity implements Player { } // Paper end diff --git a/patches/server/0903-fixed-entity-vehicle-collision-event-not-called.patch b/patches/server/0903-fixed-entity-vehicle-collision-event-not-called.patch index 7ed7d72f0b..8e79007256 100644 --- a/patches/server/0903-fixed-entity-vehicle-collision-event-not-called.patch +++ b/patches/server/0903-fixed-entity-vehicle-collision-event-not-called.patch @@ -5,10 +5,10 @@ Subject: [PATCH] fixed entity vehicle collision event not called diff --git a/src/main/java/net/minecraft/world/entity/vehicle/AbstractMinecart.java b/src/main/java/net/minecraft/world/entity/vehicle/AbstractMinecart.java -index 46c893fd33fdaf76d49af407112ff349e9579a12..9a80cf593bbdd7681bc9395daf4545a98e07636f 100644 +index 33dd6f9b3fde5bd19cfc6386dd9454df4a887489..ee4f924afe15c9a4d96af7a55b357076c7b28501 100644 --- a/src/main/java/net/minecraft/world/entity/vehicle/AbstractMinecart.java +++ b/src/main/java/net/minecraft/world/entity/vehicle/AbstractMinecart.java -@@ -142,7 +142,15 @@ public abstract class AbstractMinecart extends Entity { +@@ -143,7 +143,15 @@ public abstract class AbstractMinecart extends Entity { @Override public boolean canCollideWith(Entity other) { diff --git a/patches/server/0906-Add-fire-tick-delay-option.patch b/patches/server/0906-Add-fire-tick-delay-option.patch index d1a7affb60..d8e916dcdb 100644 --- a/patches/server/0906-Add-fire-tick-delay-option.patch +++ b/patches/server/0906-Add-fire-tick-delay-option.patch @@ -5,7 +5,7 @@ Subject: [PATCH] Add fire-tick-delay option diff --git a/src/main/java/net/minecraft/world/level/block/FireBlock.java b/src/main/java/net/minecraft/world/level/block/FireBlock.java -index 6ed2c13c8d22a936ae130cf8cf103451033a2cb7..2713fe3e118640dba73bdf4048ec707a43278991 100644 +index 69ec4de4d065481496f5363c8985d2f39cd0191d..c33dab52dc73da5f510ea5eed7785bf68e06605e 100644 --- a/src/main/java/net/minecraft/world/level/block/FireBlock.java +++ b/src/main/java/net/minecraft/world/level/block/FireBlock.java @@ -165,7 +165,7 @@ public class FireBlock extends BaseFireBlock { @@ -17,7 +17,7 @@ index 6ed2c13c8d22a936ae130cf8cf103451033a2cb7..2713fe3e118640dba73bdf4048ec707a if (world.getGameRules().getBoolean(GameRules.RULE_DOFIRETICK)) { if (!state.canSurvive(world, pos)) { fireExtinguished(world, pos); // CraftBukkit - invalid place location -@@ -362,11 +362,13 @@ public class FireBlock extends BaseFireBlock { +@@ -366,11 +366,13 @@ public class FireBlock extends BaseFireBlock { public void onPlace(BlockState iblockdata, Level world, BlockPos blockposition, BlockState iblockdata1, boolean flag, UseOnContext itemActionContext) { super.onPlace(iblockdata, world, blockposition, iblockdata1, flag, itemActionContext); // Paper end diff --git a/patches/server/0909-Track-projectile-source-for-fireworks-from-dispenser.patch b/patches/server/0909-Track-projectile-source-for-fireworks-from-dispenser.patch index 3f313856ec..b74d96a4fe 100644 --- a/patches/server/0909-Track-projectile-source-for-fireworks-from-dispenser.patch +++ b/patches/server/0909-Track-projectile-source-for-fireworks-from-dispenser.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Track projectile source for fireworks from dispensers diff --git a/src/main/java/net/minecraft/core/dispenser/DispenseItemBehavior.java b/src/main/java/net/minecraft/core/dispenser/DispenseItemBehavior.java -index 6fedf7381762ae3d76c4801ed6d5c0844c6c857b..6b5602a6b112c579cd39fffd167f316ea96511f5 100644 +index 618ad17e4f10f58994db55b82b70fbb141e3579e..46accf082b5e440ec743583bb0609c013234cb06 100644 --- a/src/main/java/net/minecraft/core/dispenser/DispenseItemBehavior.java +++ b/src/main/java/net/minecraft/core/dispenser/DispenseItemBehavior.java -@@ -516,6 +516,7 @@ public interface DispenseItemBehavior { +@@ -517,6 +517,7 @@ public interface DispenseItemBehavior { itemstack1 = CraftItemStack.asNMSCopy(event.getItem()); FireworkRocketEntity entityfireworks = new FireworkRocketEntity(pointer.getLevel(), itemstack1, pointer.x(), pointer.y(), pointer.x(), true); // Paper - GH-2871 - fix last firework in stack having no effects when dispensed diff --git a/patches/server/0911-Fix-EntityCombustEvent-cancellation-cant-fully-preve.patch b/patches/server/0911-Fix-EntityCombustEvent-cancellation-cant-fully-preve.patch index e4e29a3c4f..afa98f920a 100644 --- a/patches/server/0911-Fix-EntityCombustEvent-cancellation-cant-fully-preve.patch +++ b/patches/server/0911-Fix-EntityCombustEvent-cancellation-cant-fully-preve.patch @@ -6,10 +6,10 @@ Subject: [PATCH] Fix EntityCombustEvent cancellation cant fully prevent diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index 32a74fa1afeef72c9014ded08ffb29eba7be1a1b..ad7754fc9bc8340ced8e39bcd882a1307781910c 100644 +index 239ace465b2911c0026649e6dd8d9168d9e39845..06c22d56357d215922195b3ba9149427e61e412d 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -3183,6 +3183,10 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -3184,6 +3184,10 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { pluginManager.callEvent(entityCombustEvent); if (!entityCombustEvent.isCancelled()) { this.setSecondsOnFire(entityCombustEvent.getDuration(), false); diff --git a/patches/server/0916-Add-Player-Warden-Warning-API.patch b/patches/server/0916-Add-Player-Warden-Warning-API.patch index 9f3ffd7383..ecba5e5fed 100644 --- a/patches/server/0916-Add-Player-Warden-Warning-API.patch +++ b/patches/server/0916-Add-Player-Warden-Warning-API.patch @@ -10,10 +10,10 @@ public net.minecraft.world.entity.monster.warden.WardenSpawnTracker cooldownTick public net.minecraft.world.entity.monster.warden.WardenSpawnTracker increaseWarningLevel()V diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -index 30c1cd3b0c1f5382ace76c1a2c5461fe8cc61339..794c5b92e435f95f56f6d629fd21819de79f26cf 100644 +index 1a2eba89fafe45a1221b66a21d9f8dbdceb0e799..652489579c7014b46ebf67b0c72d2e50508955c2 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -@@ -3158,6 +3158,41 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -3166,6 +3166,41 @@ public class CraftPlayer extends CraftHumanEntity implements Player { public void showElderGuardian(boolean silent) { if (getHandle().connection != null) getHandle().connection.send(new ClientboundGameEventPacket(ClientboundGameEventPacket.GUARDIAN_ELDER_EFFECT, silent ? 0F : 1F)); } diff --git a/patches/server/0917-More-vanilla-friendly-methods-to-update-trades.patch b/patches/server/0917-More-vanilla-friendly-methods-to-update-trades.patch index e8f2a36299..03775bc1a0 100644 --- a/patches/server/0917-More-vanilla-friendly-methods-to-update-trades.patch +++ b/patches/server/0917-More-vanilla-friendly-methods-to-update-trades.patch @@ -35,10 +35,10 @@ index 235e41ddd77e126648df81d9d187a1bd178e19fe..6023b9eb3001e1a98ab8b970d853c4e7 public void gossip(ServerLevel world, Villager villager, long time) { diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftVillager.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftVillager.java -index 1fa8026ca63b7e38870daac59936a10b1950561e..a1a8ac55e572156671e47317ba061855be79e5ac 100644 +index a1705b0fae9574d4ce2bb815ea57a35f8551c3a6..4e880409b06086568627f3e930159f1abb979984 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftVillager.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftVillager.java -@@ -99,6 +99,34 @@ public class CraftVillager extends CraftAbstractVillager implements Villager { +@@ -100,6 +100,34 @@ public class CraftVillager extends CraftAbstractVillager implements Villager { } // Paper start diff --git a/patches/server/0920-Fix-async-entity-add-due-to-fungus-trees.patch b/patches/server/0920-Fix-async-entity-add-due-to-fungus-trees.patch index 1db4b01581..5209787a11 100644 --- a/patches/server/0920-Fix-async-entity-add-due-to-fungus-trees.patch +++ b/patches/server/0920-Fix-async-entity-add-due-to-fungus-trees.patch @@ -17,10 +17,10 @@ index 52fd12c474c01f3b53d0f6596b7a6fafee52bd0d..877498729c66de9aa6a27c9148f7494d BlockEntity tileentity = iblockdata.hasBlockEntity() ? this.getBlockEntity(pos) : null; diff --git a/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java b/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java -index 0087ced09e0337d88fc210acb6772b6375047bf4..ef25a0ae25e1f1f7c5bee64b9e60b17eb998ced6 100644 +index 3742e0b32e29d7dde0c2bd3d80348f8fb7b8aaf0..9868c1e58a41126b2b0f1014c74329015152ded6 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java -@@ -380,10 +380,10 @@ public abstract class CraftRegionAccessor implements RegionAccessor { +@@ -401,10 +401,10 @@ public abstract class CraftRegionAccessor implements RegionAccessor { ((ChorusFlowerBlock) Blocks.CHORUS_FLOWER).generatePlant(access, pos, random, 8); return true; case CRIMSON_FUNGUS: diff --git a/patches/server/0925-Sync-offhand-slot-in-menus.patch b/patches/server/0925-Sync-offhand-slot-in-menus.patch index 3e2a8413e4..35bcdf17eb 100644 --- a/patches/server/0925-Sync-offhand-slot-in-menus.patch +++ b/patches/server/0925-Sync-offhand-slot-in-menus.patch @@ -8,10 +8,10 @@ offhand slot isn't sent. This is not correct because you *can* put stuff into th by pressing the offhand swap item diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java -index 2eface459a431038db994f49f77a5834039cdaf6..1d4d02f26391ac55c7631817f09d05e2769b0d29 100644 +index 6fdb22809195fc2ba95ee22a5523eeabc2f2c4da..c4a070d445a0d834152eb53864eb08f4f90947ca 100644 --- a/src/main/java/net/minecraft/server/level/ServerPlayer.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java -@@ -297,6 +297,13 @@ public class ServerPlayer extends Player { +@@ -299,6 +299,13 @@ public class ServerPlayer extends Player { } diff --git a/patches/server/0926-Player-Entity-Tracking-Events.patch b/patches/server/0926-Player-Entity-Tracking-Events.patch index d9eba049b4..1e82fc3864 100644 --- a/patches/server/0926-Player-Entity-Tracking-Events.patch +++ b/patches/server/0926-Player-Entity-Tracking-Events.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Player Entity Tracking Events diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index ad7754fc9bc8340ced8e39bcd882a1307781910c..8a7af77e8ac456cc89da7e954a8090bf794475c8 100644 +index 06c22d56357d215922195b3ba9149427e61e412d..b93603dd0198719c6e6dca363328016ee824b8c8 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -3900,9 +3900,21 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -3901,9 +3901,21 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { EnchantmentHelper.doPostDamageEffects(attacker, target); } diff --git a/patches/server/0928-Properly-resend-entities.patch b/patches/server/0928-Properly-resend-entities.patch index 14d88db8b2..750e60cab6 100644 --- a/patches/server/0928-Properly-resend-entities.patch +++ b/patches/server/0928-Properly-resend-entities.patch @@ -66,10 +66,10 @@ index a276aed4821eb992e0f20e2d2c6229e0b96eef73..ff7ba7a161cfed7521354bc6e3f21ba0 public static class DataItem { diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 959e8d2cfa195e28239da03464e45563fcdd1244..e7d6e4354dc7e50716b902a54afd4cf2246dea62 100644 +index 7810ab5bd1791ff5323b7302a6351a987b93bae3..734a973ec4e5a6f24b430941b5c3ba6bcc296be5 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -2792,7 +2792,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -2798,7 +2798,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic // Entity in bucket - SPIGOT-4048 and SPIGOT-6859a if ((entity instanceof Bucketable && entity instanceof LivingEntity && origItem != null && origItem.asItem() == Items.WATER_BUCKET) && (event.isCancelled() || ServerGamePacketListenerImpl.this.player.getInventory().getSelected() == null || ServerGamePacketListenerImpl.this.player.getInventory().getSelected().getItem() != origItem)) { @@ -79,10 +79,10 @@ index 959e8d2cfa195e28239da03464e45563fcdd1244..e7d6e4354dc7e50716b902a54afd4cf2 } diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java -index aa67dd615a06d5f109a8f57dd3e6413e159cad2b..68e47dfff2519ed1fbe92f265f942fcc6cd6a00d 100644 +index 168c53eee5bbf84c11a0b0f654e4540e4d082c2a..0011e18963b12512464be10798006c641595988d 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -362,7 +362,7 @@ public abstract class PlayerList { +@@ -364,7 +364,7 @@ public abstract class PlayerList { ((ServerLevel)player.level).getChunkSource().chunkMap.addEntity(player); // Paper - track entity now // CraftBukkit end diff --git a/patches/server/0930-fix-Instruments.patch b/patches/server/0930-fix-Instruments.patch index 40e8dff1e3..a8afc9ff34 100644 --- a/patches/server/0930-fix-Instruments.patch +++ b/patches/server/0930-fix-Instruments.patch @@ -6,10 +6,10 @@ Subject: [PATCH] fix Instruments properly handle Player#playNote diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -index 794c5b92e435f95f56f6d629fd21819de79f26cf..939ef35852ee0fdad1759d3fc7f70409811d14ea 100644 +index 652489579c7014b46ebf67b0c72d2e50508955c2..4edffaef5075de849a3489cdfdee0eaf53b0df57 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -@@ -772,62 +772,18 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -776,62 +776,18 @@ public class CraftPlayer extends CraftHumanEntity implements Player { public void playNote(Location loc, Instrument instrument, Note note) { if (this.getHandle().connection == null) return; diff --git a/patches/server/0933-Fix-inconsistencies-in-dispense-events-regarding-sta.patch b/patches/server/0933-Fix-inconsistencies-in-dispense-events-regarding-sta.patch index e131a4e0c2..01f0b970d7 100644 --- a/patches/server/0933-Fix-inconsistencies-in-dispense-events-regarding-sta.patch +++ b/patches/server/0933-Fix-inconsistencies-in-dispense-events-regarding-sta.patch @@ -86,10 +86,10 @@ index eb55015f4c867fbf08430288744f58a3b9d86e89..958134519befadc27a5b647caf64acf2 } diff --git a/src/main/java/net/minecraft/core/dispenser/DispenseItemBehavior.java b/src/main/java/net/minecraft/core/dispenser/DispenseItemBehavior.java -index 6b5602a6b112c579cd39fffd167f316ea96511f5..9598aa381978194fee859721731196f0e6ee08fc 100644 +index 46accf082b5e440ec743583bb0609c013234cb06..88d18d18d69876c98e199acb647c6cca9448d55d 100644 --- a/src/main/java/net/minecraft/core/dispenser/DispenseItemBehavior.java +++ b/src/main/java/net/minecraft/core/dispenser/DispenseItemBehavior.java -@@ -217,7 +217,7 @@ public interface DispenseItemBehavior { +@@ -218,7 +218,7 @@ public interface DispenseItemBehavior { // CraftBukkit start ServerLevel worldserver = pointer.getLevel(); @@ -98,7 +98,7 @@ index 6b5602a6b112c579cd39fffd167f316ea96511f5..9598aa381978194fee859721731196f0 org.bukkit.block.Block block = worldserver.getWorld().getBlockAt(pointer.getPos().getX(), pointer.getPos().getY(), pointer.getPos().getZ()); CraftItemStack craftItem = CraftItemStack.asCraftMirror(itemstack1); -@@ -227,12 +227,13 @@ public interface DispenseItemBehavior { +@@ -228,12 +228,13 @@ public interface DispenseItemBehavior { } if (event.isCancelled()) { @@ -114,7 +114,7 @@ index 6b5602a6b112c579cd39fffd167f316ea96511f5..9598aa381978194fee859721731196f0 // Chain to handler for new item ItemStack eventStack = CraftItemStack.asNMSCopy(event.getItem()); DispenseItemBehavior idispensebehavior = (DispenseItemBehavior) DispenserBlock.DISPENSER_REGISTRY.get(eventStack.getItem()); -@@ -249,7 +250,7 @@ public interface DispenseItemBehavior { +@@ -250,7 +251,7 @@ public interface DispenseItemBehavior { return ItemStack.EMPTY; } @@ -123,7 +123,7 @@ index 6b5602a6b112c579cd39fffd167f316ea96511f5..9598aa381978194fee859721731196f0 // CraftBukkit end pointer.getLevel().gameEvent((Entity) null, GameEvent.ENTITY_PLACE, pointer.getPos()); return stack; -@@ -271,7 +272,7 @@ public interface DispenseItemBehavior { +@@ -272,7 +273,7 @@ public interface DispenseItemBehavior { ServerLevel worldserver = pointer.getLevel(); // CraftBukkit start @@ -132,7 +132,7 @@ index 6b5602a6b112c579cd39fffd167f316ea96511f5..9598aa381978194fee859721731196f0 org.bukkit.block.Block block = worldserver.getWorld().getBlockAt(pointer.getPos().getX(), pointer.getPos().getY(), pointer.getPos().getZ()); CraftItemStack craftItem = CraftItemStack.asCraftMirror(itemstack1); -@@ -281,12 +282,13 @@ public interface DispenseItemBehavior { +@@ -282,12 +283,13 @@ public interface DispenseItemBehavior { } if (event.isCancelled()) { @@ -148,7 +148,7 @@ index 6b5602a6b112c579cd39fffd167f316ea96511f5..9598aa381978194fee859721731196f0 // Chain to handler for new item ItemStack eventStack = CraftItemStack.asNMSCopy(event.getItem()); DispenseItemBehavior idispensebehavior = (DispenseItemBehavior) DispenserBlock.DISPENSER_REGISTRY.get(eventStack.getItem()); -@@ -303,7 +305,7 @@ public interface DispenseItemBehavior { +@@ -304,7 +306,7 @@ public interface DispenseItemBehavior { ArmorStand entityarmorstand = (ArmorStand) EntityType.ARMOR_STAND.spawn(worldserver, stack.getTag(), consumer, blockposition, MobSpawnType.DISPENSER, false, false); if (entityarmorstand != null) { @@ -157,7 +157,7 @@ index 6b5602a6b112c579cd39fffd167f316ea96511f5..9598aa381978194fee859721731196f0 } return stack; -@@ -325,7 +327,7 @@ public interface DispenseItemBehavior { +@@ -326,7 +328,7 @@ public interface DispenseItemBehavior { if (!list.isEmpty()) { // CraftBukkit start @@ -166,7 +166,7 @@ index 6b5602a6b112c579cd39fffd167f316ea96511f5..9598aa381978194fee859721731196f0 Level world = pointer.getLevel(); org.bukkit.block.Block block = world.getWorld().getBlockAt(pointer.getPos().getX(), pointer.getPos().getY(), pointer.getPos().getZ()); CraftItemStack craftItem = CraftItemStack.asCraftMirror(itemstack1); -@@ -336,12 +338,13 @@ public interface DispenseItemBehavior { +@@ -337,12 +339,13 @@ public interface DispenseItemBehavior { } if (event.isCancelled()) { @@ -182,7 +182,7 @@ index 6b5602a6b112c579cd39fffd167f316ea96511f5..9598aa381978194fee859721731196f0 // Chain to handler for new item ItemStack eventStack = CraftItemStack.asNMSCopy(event.getItem()); DispenseItemBehavior idispensebehavior = (DispenseItemBehavior) DispenserBlock.DISPENSER_REGISTRY.get(eventStack.getItem()); -@@ -352,7 +355,7 @@ public interface DispenseItemBehavior { +@@ -353,7 +356,7 @@ public interface DispenseItemBehavior { } // CraftBukkit end ((Saddleable) list.get(0)).equipSaddle(SoundSource.BLOCKS, CraftItemStack.asNMSCopy(event.getItem())); // Paper - Fix saddles losing nbt data - MC-191591 @@ -191,7 +191,7 @@ index 6b5602a6b112c579cd39fffd167f316ea96511f5..9598aa381978194fee859721731196f0 this.setSuccess(true); return stack; } else { -@@ -380,7 +383,7 @@ public interface DispenseItemBehavior { +@@ -381,7 +384,7 @@ public interface DispenseItemBehavior { } while (!entityhorseabstract.isArmor(stack) || entityhorseabstract.isWearingArmor() || !entityhorseabstract.isTamed()); // CraftBukkit start @@ -200,7 +200,7 @@ index 6b5602a6b112c579cd39fffd167f316ea96511f5..9598aa381978194fee859721731196f0 Level world = pointer.getLevel(); org.bukkit.block.Block block = world.getWorld().getBlockAt(pointer.getPos().getX(), pointer.getPos().getY(), pointer.getPos().getZ()); CraftItemStack craftItem = CraftItemStack.asCraftMirror(itemstack1); -@@ -391,12 +394,13 @@ public interface DispenseItemBehavior { +@@ -392,12 +395,13 @@ public interface DispenseItemBehavior { } if (event.isCancelled()) { @@ -216,7 +216,7 @@ index 6b5602a6b112c579cd39fffd167f316ea96511f5..9598aa381978194fee859721731196f0 // Chain to handler for new item ItemStack eventStack = CraftItemStack.asNMSCopy(event.getItem()); DispenseItemBehavior idispensebehavior = (DispenseItemBehavior) DispenserBlock.DISPENSER_REGISTRY.get(eventStack.getItem()); -@@ -406,6 +410,7 @@ public interface DispenseItemBehavior { +@@ -407,6 +411,7 @@ public interface DispenseItemBehavior { } } @@ -224,7 +224,7 @@ index 6b5602a6b112c579cd39fffd167f316ea96511f5..9598aa381978194fee859721731196f0 entityhorseabstract.getSlot(401).set(CraftItemStack.asNMSCopy(event.getItem())); // CraftBukkit end this.setSuccess(true); -@@ -452,7 +457,7 @@ public interface DispenseItemBehavior { +@@ -453,7 +458,7 @@ public interface DispenseItemBehavior { entityhorsechestedabstract = (AbstractChestedHorse) iterator1.next(); // CraftBukkit start } while (!entityhorsechestedabstract.isTamed()); @@ -233,7 +233,7 @@ index 6b5602a6b112c579cd39fffd167f316ea96511f5..9598aa381978194fee859721731196f0 Level world = pointer.getLevel(); org.bukkit.block.Block block = world.getWorld().getBlockAt(pointer.getPos().getX(), pointer.getPos().getY(), pointer.getPos().getZ()); CraftItemStack craftItem = CraftItemStack.asCraftMirror(itemstack1); -@@ -463,10 +468,13 @@ public interface DispenseItemBehavior { +@@ -464,10 +469,13 @@ public interface DispenseItemBehavior { } if (event.isCancelled()) { @@ -247,7 +247,7 @@ index 6b5602a6b112c579cd39fffd167f316ea96511f5..9598aa381978194fee859721731196f0 // Chain to handler for new item ItemStack eventStack = CraftItemStack.asNMSCopy(event.getItem()); DispenseItemBehavior idispensebehavior = (DispenseItemBehavior) DispenserBlock.DISPENSER_REGISTRY.get(eventStack.getItem()); -@@ -478,7 +486,7 @@ public interface DispenseItemBehavior { +@@ -479,7 +487,7 @@ public interface DispenseItemBehavior { entityhorsechestedabstract.getSlot(499).set(CraftItemStack.asNMSCopy(event.getItem())); // CraftBukkit end @@ -256,7 +256,7 @@ index 6b5602a6b112c579cd39fffd167f316ea96511f5..9598aa381978194fee859721731196f0 this.setSuccess(true); return stack; } -@@ -489,7 +497,7 @@ public interface DispenseItemBehavior { +@@ -490,7 +498,7 @@ public interface DispenseItemBehavior { Direction enumdirection = (Direction) pointer.getBlockState().getValue(DispenserBlock.FACING); // CraftBukkit start ServerLevel worldserver = pointer.getLevel(); @@ -265,7 +265,7 @@ index 6b5602a6b112c579cd39fffd167f316ea96511f5..9598aa381978194fee859721731196f0 org.bukkit.block.Block block = worldserver.getWorld().getBlockAt(pointer.getPos().getX(), pointer.getPos().getY(), pointer.getPos().getZ()); CraftItemStack craftItem = CraftItemStack.asCraftMirror(itemstack1); -@@ -499,12 +507,13 @@ public interface DispenseItemBehavior { +@@ -500,12 +508,13 @@ public interface DispenseItemBehavior { } if (event.isCancelled()) { @@ -281,7 +281,7 @@ index 6b5602a6b112c579cd39fffd167f316ea96511f5..9598aa381978194fee859721731196f0 // Chain to handler for new item ItemStack eventStack = CraftItemStack.asNMSCopy(event.getItem()); DispenseItemBehavior idispensebehavior = (DispenseItemBehavior) DispenserBlock.DISPENSER_REGISTRY.get(eventStack.getItem()); -@@ -521,7 +530,7 @@ public interface DispenseItemBehavior { +@@ -522,7 +531,7 @@ public interface DispenseItemBehavior { DispenseItemBehavior.setEntityPokingOutOfBlock(pointer, entityfireworks, enumdirection); entityfireworks.shoot((double) enumdirection.getStepX(), (double) enumdirection.getStepY(), (double) enumdirection.getStepZ(), 0.5F, 1.0F); pointer.getLevel().addFreshEntity(entityfireworks); @@ -290,7 +290,7 @@ index 6b5602a6b112c579cd39fffd167f316ea96511f5..9598aa381978194fee859721731196f0 // CraftBukkit end return stack; } -@@ -546,7 +555,7 @@ public interface DispenseItemBehavior { +@@ -547,7 +556,7 @@ public interface DispenseItemBehavior { double d5 = randomsource.triangle((double) enumdirection.getStepZ(), 0.11485000000000001D); // CraftBukkit start @@ -299,7 +299,7 @@ index 6b5602a6b112c579cd39fffd167f316ea96511f5..9598aa381978194fee859721731196f0 org.bukkit.block.Block block = worldserver.getWorld().getBlockAt(pointer.getPos().getX(), pointer.getPos().getY(), pointer.getPos().getZ()); CraftItemStack craftItem = CraftItemStack.asCraftMirror(itemstack1); -@@ -556,12 +565,13 @@ public interface DispenseItemBehavior { +@@ -557,12 +566,13 @@ public interface DispenseItemBehavior { } if (event.isCancelled()) { @@ -315,7 +315,7 @@ index 6b5602a6b112c579cd39fffd167f316ea96511f5..9598aa381978194fee859721731196f0 // Chain to handler for new item ItemStack eventStack = CraftItemStack.asNMSCopy(event.getItem()); DispenseItemBehavior idispensebehavior = (DispenseItemBehavior) DispenserBlock.DISPENSER_REGISTRY.get(eventStack.getItem()); -@@ -576,7 +586,7 @@ public interface DispenseItemBehavior { +@@ -577,7 +587,7 @@ public interface DispenseItemBehavior { entitysmallfireball.projectileSource = new org.bukkit.craftbukkit.projectiles.CraftBlockProjectileSource((DispenserBlockEntity) pointer.getEntity()); worldserver.addFreshEntity(entitysmallfireball); @@ -324,7 +324,7 @@ index 6b5602a6b112c579cd39fffd167f316ea96511f5..9598aa381978194fee859721731196f0 // CraftBukkit end return stack; } -@@ -621,7 +631,7 @@ public interface DispenseItemBehavior { +@@ -622,7 +632,7 @@ public interface DispenseItemBehavior { Material material = iblockdata.getMaterial(); if (worldserver.isEmptyBlock(blockposition) || !material.isSolid() || material.isReplaceable() || (dispensiblecontaineritem instanceof BucketItem && iblockdata.getBlock() instanceof LiquidBlockContainer && ((LiquidBlockContainer) iblockdata.getBlock()).canPlaceLiquid(worldserver, blockposition, iblockdata, ((BucketItem) dispensiblecontaineritem).content))) { org.bukkit.block.Block block = worldserver.getWorld().getBlockAt(pointer.getPos().getX(), pointer.getPos().getY(), pointer.getPos().getZ()); @@ -333,7 +333,7 @@ index 6b5602a6b112c579cd39fffd167f316ea96511f5..9598aa381978194fee859721731196f0 BlockDispenseEvent event = new BlockDispenseEvent(block, craftItem.clone(), new org.bukkit.util.Vector(x, y, z)); if (!DispenserBlock.eventFired) { -@@ -694,7 +704,7 @@ public interface DispenseItemBehavior { +@@ -695,7 +705,7 @@ public interface DispenseItemBehavior { // CraftBukkit start org.bukkit.block.Block bukkitBlock = worldserver.getWorld().getBlockAt(pointer.getPos().getX(), pointer.getPos().getY(), pointer.getPos().getZ()); @@ -342,7 +342,7 @@ index 6b5602a6b112c579cd39fffd167f316ea96511f5..9598aa381978194fee859721731196f0 BlockDispenseEvent event = new BlockDispenseEvent(bukkitBlock, craftItem.clone(), new org.bukkit.util.Vector(blockposition.getX(), blockposition.getY(), blockposition.getZ())); if (!DispenserBlock.eventFired) { -@@ -741,7 +751,7 @@ public interface DispenseItemBehavior { +@@ -742,7 +752,7 @@ public interface DispenseItemBehavior { // CraftBukkit start org.bukkit.block.Block bukkitBlock = worldserver.getWorld().getBlockAt(pointer.getPos().getX(), pointer.getPos().getY(), pointer.getPos().getZ()); @@ -351,7 +351,7 @@ index 6b5602a6b112c579cd39fffd167f316ea96511f5..9598aa381978194fee859721731196f0 BlockDispenseEvent event = new BlockDispenseEvent(bukkitBlock, craftItem.clone(), new org.bukkit.util.Vector(0, 0, 0)); if (!DispenserBlock.eventFired) { -@@ -802,7 +812,7 @@ public interface DispenseItemBehavior { +@@ -803,7 +813,7 @@ public interface DispenseItemBehavior { BlockPos blockposition = pointer.getPos().relative((Direction) pointer.getBlockState().getValue(DispenserBlock.FACING)); // CraftBukkit start org.bukkit.block.Block block = worldserver.getWorld().getBlockAt(pointer.getPos().getX(), pointer.getPos().getY(), pointer.getPos().getZ()); @@ -360,7 +360,7 @@ index 6b5602a6b112c579cd39fffd167f316ea96511f5..9598aa381978194fee859721731196f0 BlockDispenseEvent event = new BlockDispenseEvent(block, craftItem.clone(), new org.bukkit.util.Vector(0, 0, 0)); if (!DispenserBlock.eventFired) { -@@ -868,7 +878,7 @@ public interface DispenseItemBehavior { +@@ -869,7 +879,7 @@ public interface DispenseItemBehavior { // CraftBukkit start // EntityTNTPrimed entitytntprimed = new EntityTNTPrimed(worldserver, (double) blockposition.getX() + 0.5D, (double) blockposition.getY(), (double) blockposition.getZ() + 0.5D, (EntityLiving) null); @@ -369,7 +369,7 @@ index 6b5602a6b112c579cd39fffd167f316ea96511f5..9598aa381978194fee859721731196f0 org.bukkit.block.Block block = worldserver.getWorld().getBlockAt(pointer.getPos().getX(), pointer.getPos().getY(), pointer.getPos().getZ()); CraftItemStack craftItem = CraftItemStack.asCraftMirror(itemstack1); -@@ -878,12 +888,13 @@ public interface DispenseItemBehavior { +@@ -879,12 +889,13 @@ public interface DispenseItemBehavior { } if (event.isCancelled()) { @@ -385,7 +385,7 @@ index 6b5602a6b112c579cd39fffd167f316ea96511f5..9598aa381978194fee859721731196f0 // Chain to handler for new item ItemStack eventStack = CraftItemStack.asNMSCopy(event.getItem()); DispenseItemBehavior idispensebehavior = (DispenseItemBehavior) DispenserBlock.DISPENSER_REGISTRY.get(eventStack.getItem()); -@@ -899,7 +910,7 @@ public interface DispenseItemBehavior { +@@ -900,7 +911,7 @@ public interface DispenseItemBehavior { worldserver.addFreshEntity(entitytntprimed); worldserver.playSound((Player) null, entitytntprimed.getX(), entitytntprimed.getY(), entitytntprimed.getZ(), SoundEvents.TNT_PRIMED, SoundSource.BLOCKS, 1.0F, 1.0F); worldserver.gameEvent((Entity) null, GameEvent.ENTITY_PLACE, blockposition); @@ -394,7 +394,7 @@ index 6b5602a6b112c579cd39fffd167f316ea96511f5..9598aa381978194fee859721731196f0 return stack; } }); -@@ -926,7 +937,7 @@ public interface DispenseItemBehavior { +@@ -927,7 +938,7 @@ public interface DispenseItemBehavior { // CraftBukkit start org.bukkit.block.Block bukkitBlock = worldserver.getWorld().getBlockAt(pointer.getPos().getX(), pointer.getPos().getY(), pointer.getPos().getZ()); @@ -403,7 +403,7 @@ index 6b5602a6b112c579cd39fffd167f316ea96511f5..9598aa381978194fee859721731196f0 BlockDispenseEvent event = new BlockDispenseEvent(bukkitBlock, craftItem.clone(), new org.bukkit.util.Vector(blockposition.getX(), blockposition.getY(), blockposition.getZ())); if (!DispenserBlock.eventFired) { -@@ -975,7 +986,7 @@ public interface DispenseItemBehavior { +@@ -976,7 +987,7 @@ public interface DispenseItemBehavior { // CraftBukkit start org.bukkit.block.Block bukkitBlock = worldserver.getWorld().getBlockAt(pointer.getPos().getX(), pointer.getPos().getY(), pointer.getPos().getZ()); @@ -412,7 +412,7 @@ index 6b5602a6b112c579cd39fffd167f316ea96511f5..9598aa381978194fee859721731196f0 BlockDispenseEvent event = new BlockDispenseEvent(bukkitBlock, craftItem.clone(), new org.bukkit.util.Vector(blockposition.getX(), blockposition.getY(), blockposition.getZ())); if (!DispenserBlock.eventFired) { -@@ -1048,7 +1059,7 @@ public interface DispenseItemBehavior { +@@ -1049,7 +1060,7 @@ public interface DispenseItemBehavior { // CraftBukkit start org.bukkit.block.Block bukkitBlock = worldserver.getWorld().getBlockAt(pointer.getPos().getX(), pointer.getPos().getY(), pointer.getPos().getZ()); diff --git a/patches/server/0937-Improve-PortalEvents.patch b/patches/server/0937-Improve-PortalEvents.patch index 46a25cee0c..29dcd0269f 100644 --- a/patches/server/0937-Improve-PortalEvents.patch +++ b/patches/server/0937-Improve-PortalEvents.patch @@ -5,12 +5,12 @@ Subject: [PATCH] Improve PortalEvents diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index 8a7af77e8ac456cc89da7e954a8090bf794475c8..448b3d68b440cfeeb4bf8c5c7aabfdc9bdb97fc0 100644 +index b93603dd0198719c6e6dca363328016ee824b8c8..4392a9a2ab90acc48c36c91ef11e82644ba30d1c 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -3561,7 +3561,14 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -3562,7 +3562,14 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { Location enter = bukkitEntity.getLocation(); - Location exit = new Location(exitWorldServer.getWorld(), exitPosition.x(), exitPosition.y(), exitPosition.z()); + Location exit = CraftLocation.toBukkit(exitPosition, exitWorldServer.getWorld()); - EntityPortalEvent event = new EntityPortalEvent(bukkitEntity, enter, exit, searchRadius); + // Paper start diff --git a/patches/server/0938-Add-config-option-for-spider-worldborder-climbing.patch b/patches/server/0938-Add-config-option-for-spider-worldborder-climbing.patch index 6c2a6ed80b..a084e68488 100644 --- a/patches/server/0938-Add-config-option-for-spider-worldborder-climbing.patch +++ b/patches/server/0938-Add-config-option-for-spider-worldborder-climbing.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Add config option for spider worldborder climbing diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index 448b3d68b440cfeeb4bf8c5c7aabfdc9bdb97fc0..4d5c68aaea1fe44517862075b60e1989170618ab 100644 +index 4392a9a2ab90acc48c36c91ef11e82644ba30d1c..c0d8cc9cb6a11e44644c411aa296440f29a41bdf 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -398,6 +398,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -399,6 +399,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { @javax.annotation.Nullable private UUID originWorld; public boolean freezeLocked = false; // Paper - Freeze Tick Lock API @@ -16,7 +16,7 @@ index 448b3d68b440cfeeb4bf8c5c7aabfdc9bdb97fc0..4d5c68aaea1fe44517862075b60e1989 public void setOrigin(@javax.annotation.Nonnull Location location) { this.origin = location.toVector(); -@@ -1392,7 +1393,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -1393,7 +1394,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { io.papermc.paper.util.CollisionUtil.getCollisions(world, this, collisionBox, potentialCollisions, false, this.level.paperConfig().chunks.preventMovingIntoUnloadedChunks, false, false, null, null); diff --git a/patches/server/0939-Add-missing-SpigotConfig-logCommands-check.patch b/patches/server/0939-Add-missing-SpigotConfig-logCommands-check.patch index e817bbb65e..6937ab476d 100644 --- a/patches/server/0939-Add-missing-SpigotConfig-logCommands-check.patch +++ b/patches/server/0939-Add-missing-SpigotConfig-logCommands-check.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Add missing SpigotConfig logCommands check diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index e7d6e4354dc7e50716b902a54afd4cf2246dea62..78f5ec6e2f7994fa3fded16c9745c1e6a3f7b8ea 100644 +index 734a973ec4e5a6f24b430941b5c3ba6bcc296be5..1d621ee5a93251c962956b4a46d937352c92f0ee 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -2250,7 +2250,9 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -2256,7 +2256,9 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic private void performChatCommand(ServerboundChatCommandPacket packet, LastSeenMessages lastSeenMessages) { // CraftBukkit start String command = "/" + packet.command(); diff --git a/patches/server/0940-Fix-NPE-on-Allay-stopDancing-while-not-dancing.patch b/patches/server/0940-Fix-NPE-on-Allay-stopDancing-while-not-dancing.patch index c031d75462..04dbb4d045 100644 --- a/patches/server/0940-Fix-NPE-on-Allay-stopDancing-while-not-dancing.patch +++ b/patches/server/0940-Fix-NPE-on-Allay-stopDancing-while-not-dancing.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Fix NPE on Allay#stopDancing while not dancing diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftAllay.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftAllay.java -index 0c09acc98d12cdac46b2f51dcce1edbc8890c931..a0fed289f1f6b6addd60ccbd1344ad2c1202c78b 100644 +index 38b060f2395df1803a896be8fb2dbc7510e92832..debccfa7cb5517a877c06b13468db57534ace77e 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftAllay.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftAllay.java -@@ -83,7 +83,7 @@ public class CraftAllay extends CraftCreature implements org.bukkit.entity.Allay +@@ -84,7 +84,7 @@ public class CraftAllay extends CraftCreature implements org.bukkit.entity.Allay public void stopDancing() { this.getHandle().forceDancing = false; this.getHandle().jukeboxPos = null; diff --git a/patches/server/0941-Flying-Fall-Damage.patch b/patches/server/0941-Flying-Fall-Damage.patch index e40401cc10..293c3fe2d0 100644 --- a/patches/server/0941-Flying-Fall-Damage.patch +++ b/patches/server/0941-Flying-Fall-Damage.patch @@ -26,10 +26,10 @@ index 5b772b3caeafe98aa45a01bffe215a5dd33323b6..0629c471d38a77c44fc1c86ccdfcb069 } else { if (fallDistance >= 2.0F) { diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -index 939ef35852ee0fdad1759d3fc7f70409811d14ea..3ddd8c42ea1d2bdfc5b62d8fae6ce51b34a8e89b 100644 +index 4edffaef5075de849a3489cdfdee0eaf53b0df57..124a42abda64f29bb21ea3a48ee9c40d69932721 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -@@ -2321,6 +2321,19 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -2329,6 +2329,19 @@ public class CraftPlayer extends CraftHumanEntity implements Player { this.getHandle().onUpdateAbilities(); } diff --git a/patches/server/0942-Add-exploded-block-state-to-BlockExplodeEvent.patch b/patches/server/0942-Add-exploded-block-state-to-BlockExplodeEvent.patch index 84802db1d2..df81323db0 100644 --- a/patches/server/0942-Add-exploded-block-state-to-BlockExplodeEvent.patch +++ b/patches/server/0942-Add-exploded-block-state-to-BlockExplodeEvent.patch @@ -39,7 +39,7 @@ index 6d46908692637ace5d81a9948f5ed42e142f549a..d3d9bb2cdcaa3d671370ee3014341fe7 } } diff --git a/src/main/java/net/minecraft/world/level/Explosion.java b/src/main/java/net/minecraft/world/level/Explosion.java -index ff2ea0ae47fb6e083cf7dbb992d59416067b5c7d..59837144c2c0460aca6e8c349eb3d6528111d1dc 100644 +index f9cd27d6526188604aba67285f5f8fa7d6303481..185f7b1d4df59f5db7b85b529a2de6402630bf35 100644 --- a/src/main/java/net/minecraft/world/level/Explosion.java +++ b/src/main/java/net/minecraft/world/level/Explosion.java @@ -343,7 +343,7 @@ public class Explosion { @@ -90,23 +90,23 @@ index 7c22fc7a384c61670ec9db0c69178d29eba51f51..33e4d832f00f0f563931bed77722a2b6 } } diff --git a/src/main/java/net/minecraft/world/level/block/RespawnAnchorBlock.java b/src/main/java/net/minecraft/world/level/block/RespawnAnchorBlock.java -index 16f23ecffa52925904d585f3fed76aa61bac5f9d..bcea8af63b9911c36873290e5c34567b1eeaacf4 100644 +index b9903c29bdea8d1e3b6fce0e97be6bd9493cfdf4..2ed78cf83c0ae66a6ddba1ff307da89a24b0d0a8 100644 --- a/src/main/java/net/minecraft/world/level/block/RespawnAnchorBlock.java +++ b/src/main/java/net/minecraft/world/level/block/RespawnAnchorBlock.java -@@ -114,6 +114,7 @@ public class RespawnAnchorBlock extends Block { +@@ -124,6 +124,7 @@ public class RespawnAnchorBlock extends Block { } private void explode(BlockState state, Level world, final BlockPos explodedPos) { + final org.bukkit.block.BlockState explodedBlockState = org.bukkit.craftbukkit.block.CraftBlockStates.getBlockState(explodedPos, state, null); // Paper - exploded block state world.removeBlock(explodedPos, false); - boolean bl = Direction.Plane.HORIZONTAL.stream().map(explodedPos::relative).anyMatch((pos) -> { - return isWaterThatWouldFlow(pos, world); -@@ -126,7 +127,7 @@ public class RespawnAnchorBlock extends Block { - } + Stream stream = Direction.Plane.HORIZONTAL.stream(); // CraftBukkit - decompile error + +@@ -140,7 +141,7 @@ public class RespawnAnchorBlock extends Block { }; - Vec3 vec3 = explodedPos.getCenter(); -- world.explode((Entity)null, world.damageSources().badRespawnPointExplosion(vec3), explosionDamageCalculator, vec3, 5.0F, true, Level.ExplosionInteraction.BLOCK); -+ world.explode((Entity)null, world.damageSources().badRespawnPointExplosion(vec3, explodedBlockState), explosionDamageCalculator, vec3, 5.0F, true, Level.ExplosionInteraction.BLOCK); + Vec3 vec3d = explodedPos.getCenter(); + +- world.explode((Entity) null, world.damageSources().badRespawnPointExplosion(vec3d), explosiondamagecalculator, vec3d, 5.0F, true, Level.ExplosionInteraction.BLOCK); ++ world.explode((Entity) null, world.damageSources().badRespawnPointExplosion(vec3d, explodedBlockState), explosiondamagecalculator, vec3d, 5.0F, true, Level.ExplosionInteraction.BLOCK); // Paper } public static boolean canSetSpawn(Level world) { diff --git a/patches/server/0943-Expose-pre-collision-moving-velocity-to-VehicleBlock.patch b/patches/server/0943-Expose-pre-collision-moving-velocity-to-VehicleBlock.patch index b6ed2a081f..bcd8b80d4e 100644 --- a/patches/server/0943-Expose-pre-collision-moving-velocity-to-VehicleBlock.patch +++ b/patches/server/0943-Expose-pre-collision-moving-velocity-to-VehicleBlock.patch @@ -6,10 +6,10 @@ Subject: [PATCH] Expose pre-collision moving velocity to diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index 4d5c68aaea1fe44517862075b60e1989170618ab..4705d7066207250c03a5f98eef61554c901f2e35 100644 +index c0d8cc9cb6a11e44644c411aa296440f29a41bdf..df316ca580a0a3b4ba6b658f7d7bdf542f4ad85b 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -1104,7 +1104,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -1105,7 +1105,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { } if (!bl.getType().isAir()) { diff --git a/patches/server/0945-Use-single-player-info-update-packet-on-join.patch b/patches/server/0945-Use-single-player-info-update-packet-on-join.patch index 9b7e0ab9d2..7a256909c7 100644 --- a/patches/server/0945-Use-single-player-info-update-packet-on-join.patch +++ b/patches/server/0945-Use-single-player-info-update-packet-on-join.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Use single player info update packet on join diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 78f5ec6e2f7994fa3fded16c9745c1e6a3f7b8ea..0b907605b21ce04815643d2ce6d220880aa8f2cf 100644 +index 1d621ee5a93251c962956b4a46d937352c92f0ee..571cb21812b9927246950992505c1db730a5b868 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -3627,7 +3627,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -3633,7 +3633,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic this.signedMessageDecoder = session.createMessageDecoder(this.player.getUUID()); this.chatMessageChain.append((executor) -> { this.player.setChatSession(session); @@ -18,10 +18,10 @@ index 78f5ec6e2f7994fa3fded16c9745c1e6a3f7b8ea..0b907605b21ce04815643d2ce6d22088 }); } diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java -index 68e47dfff2519ed1fbe92f265f942fcc6cd6a00d..4d837c1530a3031a4c2a5a39d87bd013d60e14a6 100644 +index 0011e18963b12512464be10798006c641595988d..5c21de0d48fba88c3164b72e0eb624706b683fab 100644 --- a/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java -@@ -308,7 +308,7 @@ public abstract class PlayerList { +@@ -310,7 +310,7 @@ public abstract class PlayerList { player.sendServerStatus(serverping); } @@ -30,7 +30,7 @@ index 68e47dfff2519ed1fbe92f265f942fcc6cd6a00d..4d837c1530a3031a4c2a5a39d87bd013 this.players.add(player); this.playersByName.put(player.getScoreboardName().toLowerCase(java.util.Locale.ROOT), player); // Spigot this.playersByUUID.put(player.getUUID(), player); -@@ -344,6 +344,7 @@ public abstract class PlayerList { +@@ -346,6 +346,7 @@ public abstract class PlayerList { // CraftBukkit start - sendAll above replaced with this loop ClientboundPlayerInfoUpdatePacket packet = ClientboundPlayerInfoUpdatePacket.createPlayerInitializing(List.of(player)); @@ -38,7 +38,7 @@ index 68e47dfff2519ed1fbe92f265f942fcc6cd6a00d..4d837c1530a3031a4c2a5a39d87bd013 for (int i = 0; i < this.players.size(); ++i) { ServerPlayer entityplayer1 = (ServerPlayer) this.players.get(i); -@@ -351,12 +352,17 @@ public abstract class PlayerList { +@@ -353,12 +354,17 @@ public abstract class PlayerList { entityplayer1.connection.send(packet); } diff --git a/patches/server/0947-Win-Screen-API.patch b/patches/server/0947-Win-Screen-API.patch index a7acc7f8dc..b16b497433 100644 --- a/patches/server/0947-Win-Screen-API.patch +++ b/patches/server/0947-Win-Screen-API.patch @@ -7,10 +7,10 @@ Subject: [PATCH] Win Screen API public net.minecraft.server.level.ServerPlayer seenCredits diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -index 3ddd8c42ea1d2bdfc5b62d8fae6ce51b34a8e89b..c8d8ab8e5d8d0a986ff023ce1e195667472d7798 100644 +index 124a42abda64f29bb21ea3a48ee9c40d69932721..3f498543cf0476ff1b184788d93f13b70c476c16 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java -@@ -1231,6 +1231,25 @@ public class CraftPlayer extends CraftHumanEntity implements Player { +@@ -1229,6 +1229,25 @@ public class CraftPlayer extends CraftHumanEntity implements Player { this.getHandle().connection.send(packet); } diff --git a/patches/server/0949-Fix-force-opening-enchantment-tables.patch b/patches/server/0949-Fix-force-opening-enchantment-tables.patch index 2abcb07620..eb92847f0e 100644 --- a/patches/server/0949-Fix-force-opening-enchantment-tables.patch +++ b/patches/server/0949-Fix-force-opening-enchantment-tables.patch @@ -5,13 +5,13 @@ Subject: [PATCH] Fix force-opening enchantment tables diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java -index d3644b268c10fd839338a5b1bfc42b4ae5286555..d445a75736d4ab9f790387c6a8f077cc45f7023f 100644 +index 7a2a73edc13930f34eb11d9d0802ae9ec5cd8d40..ffef4593e87c42bcd87fd5de9de9a78b95a96c3b 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java -@@ -403,7 +403,18 @@ public class CraftHumanEntity extends CraftLivingEntity implements HumanEntity { +@@ -404,7 +404,18 @@ public class CraftHumanEntity extends CraftLivingEntity implements HumanEntity { // If there isn't an enchant table we can force create one, won't be very useful though. - BlockPos pos = new BlockPos(location.getBlockX(), location.getBlockY(), location.getBlockZ()); + BlockPos pos = CraftLocation.toBlockPosition(location); - this.getHandle().openMenu(((EnchantmentTableBlock) Blocks.ENCHANTING_TABLE).getMenuProvider(null, this.getHandle().level, pos)); + // Paper start + MenuProvider menuProvider = ((EnchantmentTableBlock) Blocks.ENCHANTING_TABLE).getMenuProvider(null, this.getHandle().level, pos); diff --git a/patches/server/0954-Fix-HumanEntity-drop-not-updating-the-client-inv.patch b/patches/server/0954-Fix-HumanEntity-drop-not-updating-the-client-inv.patch index 5d32898ade..c73b1fa213 100644 --- a/patches/server/0954-Fix-HumanEntity-drop-not-updating-the-client-inv.patch +++ b/patches/server/0954-Fix-HumanEntity-drop-not-updating-the-client-inv.patch @@ -7,10 +7,10 @@ Subject: [PATCH] Fix HumanEntity#drop not updating the client inv public net.minecraft.server.level.ServerPlayer containerSynchronizer diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java -index d445a75736d4ab9f790387c6a8f077cc45f7023f..c8cccfcf4d572a9e65fce09621aeed2a7045003c 100644 +index ffef4593e87c42bcd87fd5de9de9a78b95a96c3b..1b008e5217c5bbf566a213abb92e1c7c43a3a7c2 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java -@@ -756,8 +756,15 @@ public class CraftHumanEntity extends CraftLivingEntity implements HumanEntity { +@@ -757,8 +757,15 @@ public class CraftHumanEntity extends CraftLivingEntity implements HumanEntity { // Paper end @Override public boolean dropItem(boolean dropAll) { diff --git a/patches/server/0967-Treat-sequence-violations-like-they-should-be.patch b/patches/server/0967-Treat-sequence-violations-like-they-should-be.patch index 32163563cb..91b302ad20 100644 --- a/patches/server/0967-Treat-sequence-violations-like-they-should-be.patch +++ b/patches/server/0967-Treat-sequence-violations-like-they-should-be.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Treat sequence violations like they should be diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index f5888a2216a017b0db24ff7bfe2fc8f41b149605..8258764bafe5ad2d9aeaafd830aab3bb6617d2ff 100644 +index ea91fe6ad0c52c94e99c7988c10879ed70f4062c..6c4cc7e74a67f63d3c9b0e9865f25c45512d244b 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -2125,6 +2125,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -2126,6 +2126,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic public void ackBlockChangesUpTo(int sequence) { if (sequence < 0) { diff --git a/patches/server/0969-Prevent-causing-expired-keys-from-impacting-new-join.patch b/patches/server/0969-Prevent-causing-expired-keys-from-impacting-new-join.patch index 280d14e6e1..db2a91cc88 100644 --- a/patches/server/0969-Prevent-causing-expired-keys-from-impacting-new-join.patch +++ b/patches/server/0969-Prevent-causing-expired-keys-from-impacting-new-join.patch @@ -24,10 +24,10 @@ index 23e0e6937e28f09271a4ec7c35e0076a576cf3d3..4aa8b483841028fbcc43f9ed47730881 UPDATE_GAME_MODE((serialized, buf) -> { serialized.gameMode = GameType.byId(buf.readVarInt()); diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index dac73f994d416900ef3a3253e040225a805c827a..04a92f33f15d1696e38d38839651adf7d0462cac 100644 +index 5308d2996e807e1efba545fd293a4186dbfab3bf..aa287d7f37f38d938d195114408cb6dbda59063d 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -295,6 +295,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -296,6 +296,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic private final AtomicReference lastChatTimeStamp; @Nullable private RemoteChatSession chatSession; @@ -35,7 +35,7 @@ index dac73f994d416900ef3a3253e040225a805c827a..04a92f33f15d1696e38d38839651adf7 private SignedMessageChain.Decoder signedMessageDecoder; private final LastSeenMessagesValidator lastSeenMessages; private final MessageSignatureCache messageSignatureCache; -@@ -435,6 +436,13 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -436,6 +437,13 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic this.disconnect(Component.translatable("multiplayer.disconnect.idling"), org.bukkit.event.player.PlayerKickEvent.Cause.IDLING); // Paper - kick event cause } @@ -49,7 +49,7 @@ index dac73f994d416900ef3a3253e040225a805c827a..04a92f33f15d1696e38d38839651adf7 } public void resetPosition() { -@@ -3625,6 +3633,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -3631,6 +3639,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic private void resetPlayerChatState(RemoteChatSession session) { this.chatSession = session; diff --git a/patches/server/0975-Disable-allowListing-before-received-from-client.patch b/patches/server/0975-Disable-allowListing-before-received-from-client.patch index 9068e58573..a1900d6beb 100644 --- a/patches/server/0975-Disable-allowListing-before-received-from-client.patch +++ b/patches/server/0975-Disable-allowListing-before-received-from-client.patch @@ -8,10 +8,10 @@ despite a player having disabled listing, they are able to be seen for a brief m Player until the actual configuration value is received from the client. diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java -index 1d4d02f26391ac55c7631817f09d05e2769b0d29..a0053455eaeca04855b689f3b00b78dac39d08e3 100644 +index c4a070d445a0d834152eb53864eb08f4f90947ca..f4526885a57b804a754ab34675649a5466db300d 100644 --- a/src/main/java/net/minecraft/server/level/ServerPlayer.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java -@@ -284,7 +284,7 @@ public class ServerPlayer extends Player { +@@ -286,7 +286,7 @@ public class ServerPlayer extends Player { this.recipeBook = new ServerRecipeBook(); this.lastSectionPos = SectionPos.of(0, 0, 0); this.respawnDimension = Level.OVERWORLD; diff --git a/patches/server/0978-Fix-DamageCause-for-Falling-Blocks.patch b/patches/server/0978-Fix-DamageCause-for-Falling-Blocks.patch index 0f713f319e..430a94b984 100644 --- a/patches/server/0978-Fix-DamageCause-for-Falling-Blocks.patch +++ b/patches/server/0978-Fix-DamageCause-for-Falling-Blocks.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Fix DamageCause for Falling Blocks diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java -index 819c9c020f4d5a1373f68850134960d24b8fc308..dee0168b50c7fbaefb762939a04e8f51e7bc58f7 100644 +index 0f4154560047735562b583081a9edb314f3a8a74..221f5088953b3452966d07eabd4ea8b38c465fd9 100644 --- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java +++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java -@@ -1028,6 +1028,11 @@ public class CraftEventFactory { +@@ -1030,6 +1030,11 @@ public class CraftEventFactory { } else if (source.is(DamageTypes.SONIC_BOOM)) { cause = DamageCause.SONIC_BOOM; } diff --git a/work/Bukkit b/work/Bukkit index 465c496472..2fcba9b271 160000 --- a/work/Bukkit +++ b/work/Bukkit @@ -1 +1 @@ -Subproject commit 465c4964722bd062eb83331142cfa1af63a4f0c2 +Subproject commit 2fcba9b271a8557073af845ba6c9c1c121565bea diff --git a/work/CraftBukkit b/work/CraftBukkit index 818582f409..01b2e1af41 160000 --- a/work/CraftBukkit +++ b/work/CraftBukkit @@ -1 +1 @@ -Subproject commit 818582f409401817e7331a6e31e25a1ae4832ad8 +Subproject commit 01b2e1af41a8698d54437d275b2e7d41014d5d81 diff --git a/work/Spigot b/work/Spigot index 514cf03ae9..7da74dae7f 160000 --- a/work/Spigot +++ b/work/Spigot @@ -1 +1 @@ -Subproject commit 514cf03ae91c086bf9e47825379698b3a97b6326 +Subproject commit 7da74dae7f21e374cd5ee71645fb2bfccdf05beb