diff --git a/patches/api/0007-Adventure.patch b/patches/api/0007-Adventure.patch index 49272d4311..819908984e 100644 --- a/patches/api/0007-Adventure.patch +++ b/patches/api/0007-Adventure.patch @@ -7,7 +7,7 @@ Co-authored-by: zml Co-authored-by: Jake Potrebic diff --git a/build.gradle.kts b/build.gradle.kts -index 17fd7162ab32785252bf2579daae8d47aec21684..f3018c133440e2f6d1bcdf1adb060dfc6db1a866 100644 +index ccf5b30fa48e641fc8d04f185f9ffca55d4e2154..0ed6d9e6619db7559dc5b65a8da6e54e6e15d31c 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -10,6 +10,19 @@ java { @@ -1076,19 +1076,19 @@ 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 bc4417d8ffa92a78f690bfa5705d3e42cdc11fd2..d3519fa5b99e2888a194c6382415537785fbeef0 100644 +index dd0fef9155077ce6df7bdadc9e4152008f700a3b..92e8b0b1ccebdc2646337114793ea9f3e7759d25 100644 --- a/src/main/java/org/bukkit/World.java +++ b/src/main/java/org/bukkit/World.java @@ -38,7 +38,7 @@ import org.jetbrains.annotations.Nullable; /** * Represents a world, which may contain entities, chunks and blocks */ --public interface World extends PluginMessageRecipient, Metadatable { -+public interface World extends PluginMessageRecipient, Metadatable, net.kyori.adventure.audience.ForwardingAudience { // Paper +-public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient, Metadatable { ++public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient, Metadatable, net.kyori.adventure.audience.ForwardingAudience { // Paper /** * Gets the {@link Block} at the given coordinates -@@ -640,6 +640,14 @@ public interface World extends PluginMessageRecipient, Metadatable { +@@ -633,6 +633,14 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient @NotNull public List getPlayers(); diff --git a/patches/api/0049-Provide-E-TE-Chunk-count-stat-methods.patch b/patches/api/0049-Provide-E-TE-Chunk-count-stat-methods.patch index 5cd5541fcb..25684b41b0 100644 --- a/patches/api/0049-Provide-E-TE-Chunk-count-stat-methods.patch +++ b/patches/api/0049-Provide-E-TE-Chunk-count-stat-methods.patch @@ -7,12 +7,12 @@ Provides counts without the ineffeciency of using .getEntities().size() which creates copy of the collections. diff --git a/src/main/java/org/bukkit/World.java b/src/main/java/org/bukkit/World.java -index d3519fa5b99e2888a194c6382415537785fbeef0..8804be419520859355b69660e6f3166d1aa8b1ea 100644 +index 864fd2f67820e60e74443c135f8f5e5c62a077bb..370a7a078eeaeac70cd5032264e6dd21fb444bd1 100644 --- a/src/main/java/org/bukkit/World.java +++ b/src/main/java/org/bukkit/World.java @@ -40,6 +40,33 @@ import org.jetbrains.annotations.Nullable; */ - public interface World extends PluginMessageRecipient, Metadatable, net.kyori.adventure.audience.ForwardingAudience { // Paper + public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient, Metadatable, net.kyori.adventure.audience.ForwardingAudience { // Paper + // Paper start + /** diff --git a/patches/api/0068-Allow-plugins-to-use-SLF4J-for-logging.patch b/patches/api/0068-Allow-plugins-to-use-SLF4J-for-logging.patch index 2e4760ca33..4ce74e6774 100644 --- a/patches/api/0068-Allow-plugins-to-use-SLF4J-for-logging.patch +++ b/patches/api/0068-Allow-plugins-to-use-SLF4J-for-logging.patch @@ -27,10 +27,10 @@ index 7cb2fd3adcbf425857ec3de03d009d4c0bd81dc3..689d470ebe2c7e25e4c87f6127978d1d implementation("org.ow2.asm:asm:9.1") implementation("org.ow2.asm:asm-commons:9.1") diff --git a/src/main/java/org/bukkit/plugin/Plugin.java b/src/main/java/org/bukkit/plugin/Plugin.java -index febfec6efafd76bb59b4b43aa223af16f73339b4..e1174ed0b0f9b77068117712a867aa28bfaa64b5 100644 +index 03ca87a1cbace2459174bb7bb8847bda766e80c5..c25fc646be750d3a3b2f4fb3f1c53daee5254107 100644 --- a/src/main/java/org/bukkit/plugin/Plugin.java +++ b/src/main/java/org/bukkit/plugin/Plugin.java -@@ -166,6 +166,18 @@ public interface Plugin extends TabExecutor { +@@ -179,6 +179,18 @@ public interface Plugin extends TabExecutor { @NotNull public Logger getLogger(); diff --git a/patches/api/0069-Handle-plugin-prefixes-in-implementation-logging-con.patch b/patches/api/0069-Handle-plugin-prefixes-in-implementation-logging-con.patch index a1273c87c6..4df160a20b 100644 --- a/patches/api/0069-Handle-plugin-prefixes-in-implementation-logging-con.patch +++ b/patches/api/0069-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 2231900549607a0917dd04e8b433c027b846cef9..bb2e55e97bf887a28cac7d4f9a0a23960d22cf56 100644 +index 50a479488917b4ce019fa71a496c41e843e9c5c4..f99d60ae4003f953b5680a997e9e43e63c035b0c 100644 --- a/src/main/java/org/bukkit/plugin/java/JavaPlugin.java +++ b/src/main/java/org/bukkit/plugin/java/JavaPlugin.java -@@ -42,7 +42,7 @@ public abstract class JavaPlugin extends PluginBase { +@@ -43,7 +43,7 @@ public abstract class JavaPlugin extends PluginBase { private boolean naggable = true; private FileConfiguration newConfig = null; private File configFile = null; @@ -29,7 +29,7 @@ index 2231900549607a0917dd04e8b433c027b846cef9..bb2e55e97bf887a28cac7d4f9a0a2396 public JavaPlugin() { final ClassLoader classLoader = this.getClass().getClassLoader(); -@@ -276,7 +276,8 @@ public abstract class JavaPlugin extends PluginBase { +@@ -277,7 +277,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/0071-Add-workaround-for-plugins-modifying-the-parent-of-t.patch b/patches/api/0071-Add-workaround-for-plugins-modifying-the-parent-of-t.patch index c4f874c6ed..3d26c42d43 100644 --- a/patches/api/0071-Add-workaround-for-plugins-modifying-the-parent-of-t.patch +++ b/patches/api/0071-Add-workaround-for-plugins-modifying-the-parent-of-t.patch @@ -60,10 +60,10 @@ index 0000000000000000000000000000000000000000..76f2cb9cd99cad2a9484eab2becd8c36 + +} diff --git a/src/main/java/org/bukkit/plugin/java/JavaPlugin.java b/src/main/java/org/bukkit/plugin/java/JavaPlugin.java -index bb2e55e97bf887a28cac7d4f9a0a23960d22cf56..04fa3991f6ce4e9dad804f28fc6c947695857089 100644 +index f99d60ae4003f953b5680a997e9e43e63c035b0c..c943bd801b54519ba6cf5d45aec593d7b7438f99 100644 --- a/src/main/java/org/bukkit/plugin/java/JavaPlugin.java +++ b/src/main/java/org/bukkit/plugin/java/JavaPlugin.java -@@ -42,7 +42,7 @@ public abstract class JavaPlugin extends PluginBase { +@@ -43,7 +43,7 @@ public abstract class JavaPlugin extends PluginBase { private boolean naggable = true; private FileConfiguration newConfig = null; private File configFile = null; @@ -72,7 +72,7 @@ index bb2e55e97bf887a28cac7d4f9a0a23960d22cf56..04fa3991f6ce4e9dad804f28fc6c9476 public JavaPlugin() { final ClassLoader classLoader = this.getClass().getClassLoader(); -@@ -276,8 +276,11 @@ public abstract class JavaPlugin extends PluginBase { +@@ -277,8 +277,11 @@ public abstract class JavaPlugin extends PluginBase { this.dataFolder = dataFolder; this.classLoader = classLoader; this.configFile = new File(dataFolder, "config.yml"); diff --git a/patches/api/0097-Additional-world.getNearbyEntities-API-s.patch b/patches/api/0097-Additional-world.getNearbyEntities-API-s.patch index b944621c0a..1fa4fee7a7 100644 --- a/patches/api/0097-Additional-world.getNearbyEntities-API-s.patch +++ b/patches/api/0097-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 8804be419520859355b69660e6f3166d1aa8b1ea..6cc9c7fc913f229c4869a976e73253acb74fcda3 100644 +index 6b3dc349e5bf8f092e4d2bbbd4747d7d527b0949..9945fe0ee354603490cc0b759264f91e8a7a0f6b 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 8804be419520859355b69660e6f3166d1aa8b1ea..6cc9c7fc913f229c4869a976e73253ac import java.util.Collection; import java.util.HashMap; import java.util.List; -@@ -659,6 +662,256 @@ public interface World extends PluginMessageRecipient, Metadatable, net.kyori.ad +@@ -652,6 +655,256 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient @NotNull public Collection getEntitiesByClasses(@NotNull Class... classes); diff --git a/patches/api/0099-Expand-World.spawnParticle-API-and-add-Builder.patch b/patches/api/0099-Expand-World.spawnParticle-API-and-add-Builder.patch index 07976f7ff7..9580a95bca 100644 --- a/patches/api/0099-Expand-World.spawnParticle-API-and-add-Builder.patch +++ b/patches/api/0099-Expand-World.spawnParticle-API-and-add-Builder.patch @@ -522,10 +522,10 @@ index c5315ee1ed435c39a3ae298e248b67c5dc291497..687a62707c8021f87e03d6bc358b3b4e * 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 0d1e026934b45d7d7419efe3365561f5f19f3823..2ca5f2715e8827b9b1041e7e62807216d9608bf8 100644 +index 9945fe0ee354603490cc0b759264f91e8a7a0f6b..8b71809fd13c267ef6c84552c6d0a263670ad62f 100644 --- a/src/main/java/org/bukkit/World.java +++ b/src/main/java/org/bukkit/World.java -@@ -2674,7 +2674,57 @@ public interface World extends PluginMessageRecipient, Metadatable, net.kyori.ad +@@ -2573,7 +2573,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 d85a3bbdfe..3e47c176d5 100644 --- a/patches/api/0114-Expand-Explosions-API.patch +++ b/patches/api/0114-Expand-Explosions-API.patch @@ -106,10 +106,10 @@ index bbc636baef2e2b0586c7d517be428438ca26ab66..a8d4f7972d07ddde171b4a1ec470a4c6 * 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 ca2b1cbff153c53ec9182e44a1979350bacd695b..53407b999258967a116241ab7d791ac52a344b80 100644 +index 8b71809fd13c267ef6c84552c6d0a263670ad62f..d5793644cf51f6e864897893961f367c8d0dc6e8 100644 --- a/src/main/java/org/bukkit/World.java +++ b/src/main/java/org/bukkit/World.java -@@ -1442,6 +1442,88 @@ public interface World extends PluginMessageRecipient, Metadatable, net.kyori.ad +@@ -1419,6 +1419,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 339775b32f..0b2ef4f5fe 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 53407b999258967a116241ab7d791ac52a344b80..a7bd869fb5b8e35274eee0d8dae9dd6fe3c1c540 100644 +index d5793644cf51f6e864897893961f367c8d0dc6e8..fef5a98a5c84b018f30a59faac613a60257f3a44 100644 --- a/src/main/java/org/bukkit/World.java +++ b/src/main/java/org/bukkit/World.java -@@ -946,6 +946,17 @@ public interface World extends PluginMessageRecipient, Metadatable, net.kyori.ad +@@ -939,6 +939,17 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient @NotNull public Collection getNearbyEntities(@NotNull Location location, double x, double y, double z); @@ -20,7 +20,7 @@ index 53407b999258967a116241ab7d791ac52a344b80..a7bd869fb5b8e35274eee0d8dae9dd6f + * @return the entity with the given UUID, or null if it isn't found + */ + @Nullable -+ public Entity getEntity(@NotNull UUID uuid); ++ public Entity getEntity(@NotNull java.util.UUID uuid); + // Paper end + /** diff --git a/patches/api/0135-Provide-Chunk-Coordinates-as-a-Long-API.patch b/patches/api/0135-Provide-Chunk-Coordinates-as-a-Long-API.patch index 17690209af..0b526f3b4b 100644 --- a/patches/api/0135-Provide-Chunk-Coordinates-as-a-Long-API.patch +++ b/patches/api/0135-Provide-Chunk-Coordinates-as-a-Long-API.patch @@ -44,10 +44,10 @@ index beac1439c71fb28f1a3baecf56157237e12ccfd5..fa576096e908f8fbdbef53e1bd91215a * 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 a7bd869fb5b8e35274eee0d8dae9dd6fe3c1c540..85c9ea1241d580386be00fb85ea1446addd376c4 100644 +index 5846d085b770b3c89cadcd9e2e57ded776babc9e..49e07ff7a3d8a2d9994205c8b29bd7295bc6acc0 100644 --- a/src/main/java/org/bukkit/World.java +++ b/src/main/java/org/bukkit/World.java -@@ -207,6 +207,22 @@ public interface World extends PluginMessageRecipient, Metadatable, net.kyori.ad +@@ -207,6 +207,22 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient @NotNull public Chunk getChunkAt(@NotNull Block block); diff --git a/patches/api/0139-Allow-Blocks-to-be-accessed-via-a-long-key.patch b/patches/api/0139-Allow-Blocks-to-be-accessed-via-a-long-key.patch index 47e5f25932..966ebe8678 100644 --- a/patches/api/0139-Allow-Blocks-to-be-accessed-via-a-long-key.patch +++ b/patches/api/0139-Allow-Blocks-to-be-accessed-via-a-long-key.patch @@ -48,10 +48,10 @@ index 36ed248f0716f2cc465c08ab851b7d83d4c7c0a7..58728a0f0722b378efa129e26f0c822b * @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 85c9ea1241d580386be00fb85ea1446addd376c4..4f563c6afc3568a5a45594bcc87790eeefc4148d 100644 +index 49e07ff7a3d8a2d9994205c8b29bd7295bc6acc0..28bcf496d658ba305a6bf459cdd710502399ff04 100644 --- a/src/main/java/org/bukkit/World.java +++ b/src/main/java/org/bukkit/World.java -@@ -90,6 +90,38 @@ public interface World extends PluginMessageRecipient, Metadatable, net.kyori.ad +@@ -90,6 +90,38 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient @NotNull public Block getBlockAt(@NotNull Location location); diff --git a/patches/api/0143-isChunkGenerated-API.patch b/patches/api/0143-isChunkGenerated-API.patch index 83bfc4adc8..fac20ce8a4 100644 --- a/patches/api/0143-isChunkGenerated-API.patch +++ b/patches/api/0143-isChunkGenerated-API.patch @@ -34,10 +34,10 @@ index 58728a0f0722b378efa129e26f0c822b63d1af36..88b3e0323dbc4f0fce31b147c7aaa08d /** * 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 4f563c6afc3568a5a45594bcc87790eeefc4148d..868e34482a3a5773dfbdc80b36adcee25239614a 100644 +index 28bcf496d658ba305a6bf459cdd710502399ff04..e4bf314c954d8cca6bdb52f0b88137cac4d83f24 100644 --- a/src/main/java/org/bukkit/World.java +++ b/src/main/java/org/bukkit/World.java -@@ -253,6 +253,17 @@ public interface World extends PluginMessageRecipient, Metadatable, net.kyori.ad +@@ -253,6 +253,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/0146-Async-Chunks-API.patch b/patches/api/0146-Async-Chunks-API.patch index 9f8b1b83a4..416deecbaf 100644 --- a/patches/api/0146-Async-Chunks-API.patch +++ b/patches/api/0146-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 868e34482a3a5773dfbdc80b36adcee25239614a..1264c65235e622f648d71ef10d804ef5193da973 100644 +index 891eaf0d1ed600e8e81a7bbdaf9e8f34e2ca50b9..2a371a93c99cb034df897fa82d816ee852a2c4e7 100644 --- a/src/main/java/org/bukkit/World.java +++ b/src/main/java/org/bukkit/World.java -@@ -969,6 +969,482 @@ public interface World extends PluginMessageRecipient, Metadatable, net.kyori.ad +@@ -962,6 +962,482 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient } return nearby; } diff --git a/patches/api/0159-Add-sun-related-API.patch b/patches/api/0159-Add-sun-related-API.patch index d276f4329a..020695c84b 100644 --- a/patches/api/0159-Add-sun-related-API.patch +++ b/patches/api/0159-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 1264c65235e622f648d71ef10d804ef5193da973..b80a2fe9eb6824d986126e451900a62244d3a8e7 100644 +index 2a371a93c99cb034df897fa82d816ee852a2c4e7..f2dc2c9138c3e2e3431837cb24307be894da3ee0 100644 --- a/src/main/java/org/bukkit/World.java +++ b/src/main/java/org/bukkit/World.java -@@ -1812,6 +1812,16 @@ public interface World extends PluginMessageRecipient, Metadatable, net.kyori.ad +@@ -1789,6 +1789,16 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient */ public void setFullTime(long time); diff --git a/patches/api/0181-Add-Heightmap-API.patch b/patches/api/0181-Add-Heightmap-API.patch index e845add87f..0c6c7fb4b0 100644 --- a/patches/api/0181-Add-Heightmap-API.patch +++ b/patches/api/0181-Add-Heightmap-API.patch @@ -51,7 +51,7 @@ index 0000000000000000000000000000000000000000..709e44ea1b14ab6917501c928e689cc6 + SOLID_OR_LIQUID_NO_LEAVES; +} diff --git a/src/main/java/org/bukkit/Location.java b/src/main/java/org/bukkit/Location.java -index 1835d39f6259732e56d51fa746faf1e4c65eaf07..c9b953aa55eeee87e81b9b712c0f501a58e641fb 100644 +index 23ca89dde7f6ac9082d4b97fce2959425f3680cb..8321441b8f528a05e297f485672f928e76fe017d 100644 --- a/src/main/java/org/bukkit/Location.java +++ b/src/main/java/org/bukkit/Location.java @@ -638,6 +638,47 @@ public class Location implements Cloneable, ConfigurationSerializable { @@ -103,10 +103,10 @@ index 1835d39f6259732e56d51fa746faf1e4c65eaf07..c9b953aa55eeee87e81b9b712c0f501a * 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 b80a2fe9eb6824d986126e451900a62244d3a8e7..6fe2875f95bb600606d66e2f7113d325d10a9b9c 100644 +index ef17e3caf6a899fc19ed5b1df1446d42322fb098..57b4b3056d6408b67f070be5fe29e58c4699b486 100644 --- a/src/main/java/org/bukkit/World.java +++ b/src/main/java/org/bukkit/World.java -@@ -160,6 +160,87 @@ public interface World extends PluginMessageRecipient, Metadatable, net.kyori.ad +@@ -160,6 +160,87 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient @NotNull public Block getHighestBlockAt(@NotNull Location location); diff --git a/patches/api/0189-World-view-distance-api.patch b/patches/api/0189-World-view-distance-api.patch index 4a941354c0..9024e2115e 100644 --- a/patches/api/0189-World-view-distance-api.patch +++ b/patches/api/0189-World-view-distance-api.patch @@ -5,10 +5,10 @@ Subject: [PATCH] World view distance api diff --git a/src/main/java/org/bukkit/World.java b/src/main/java/org/bukkit/World.java -index b4bef2b62cd78cf51d1fc2fd5b85a0ad9dae7a3d..a02d9d7851431211822e1d4157b218db9d404ab7 100644 +index d4912e83ed9e3166501458035269d480469b6c5d..157f4d6b587c382e1f5c558e0a0f8c1b486be7a4 100644 --- a/src/main/java/org/bukkit/World.java +++ b/src/main/java/org/bukkit/World.java -@@ -3529,6 +3529,34 @@ public interface World extends PluginMessageRecipient, Metadatable, net.kyori.ad +@@ -3428,6 +3428,34 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient int getViewDistance(); // Spigot end diff --git a/patches/api/0206-Spawn-Reason-API.patch b/patches/api/0206-Spawn-Reason-API.patch index 78038ce509..8ddcbaa4df 100644 --- a/patches/api/0206-Spawn-Reason-API.patch +++ b/patches/api/0206-Spawn-Reason-API.patch @@ -4,53 +4,45 @@ Date: Thu, 10 Apr 2014 23:18:28 -0400 Subject: [PATCH] Spawn Reason API -diff --git a/src/main/java/org/bukkit/World.java b/src/main/java/org/bukkit/World.java -index cd96c851d00185e7ee3ec6682b166fc1d06b6a73..10c22809535b6151b45aa18a02b80b8f2e3e6dff 100644 ---- a/src/main/java/org/bukkit/World.java -+++ b/src/main/java/org/bukkit/World.java -@@ -1,6 +1,8 @@ - package org.bukkit; - - import java.io.File; -+ +diff --git a/src/main/java/org/bukkit/RegionAccessor.java b/src/main/java/org/bukkit/RegionAccessor.java +index e285d54450471ed22e12e77c7b829fde6b564ede..35e407ec7bd8d5cd38069fe7f2cf3d9d3bc94cbe 100644 +--- a/src/main/java/org/bukkit/RegionAccessor.java ++++ b/src/main/java/org/bukkit/RegionAccessor.java +@@ -9,6 +9,7 @@ import org.bukkit.block.data.BlockData; + import org.bukkit.entity.Entity; + import org.bukkit.entity.EntityType; + import org.bukkit.entity.LivingEntity; +import org.bukkit.event.entity.CreatureSpawnEvent; - import org.bukkit.generator.ChunkGenerator; - - import java.util.ArrayList; -@@ -2249,6 +2251,12 @@ public interface World extends PluginMessageRecipient, Metadatable, net.kyori.ad - @NotNull - public T spawn(@NotNull Location location, @NotNull Class clazz) throws IllegalArgumentException; - -+ // Paper start -+ @NotNull -+ public default T spawn(@NotNull Location location, @NotNull Class clazz, @NotNull CreatureSpawnEvent.SpawnReason reason) throws IllegalArgumentException { -+ return spawn(location, clazz, reason, null); -+ } -+ - /** - * Spawn an entity of a specific class at the given {@link Location}, with - * the supplied function run before the entity is added to the world. -@@ -2266,7 +2274,28 @@ public interface World extends PluginMessageRecipient, Metadatable, net.kyori.ad + import org.bukkit.util.Consumer; + import org.jetbrains.annotations.NotNull; + import org.jetbrains.annotations.Nullable; +@@ -288,7 +289,34 @@ public interface RegionAccessor { * {@link Entity} requested cannot be spawned */ @NotNull -- public T spawn(@NotNull Location location, @NotNull Class clazz, @Nullable Consumer function) throws IllegalArgumentException; +- T spawn(@NotNull Location location, @NotNull Class clazz, @Nullable Consumer function) throws IllegalArgumentException; ++ // Paper start + public default T spawn(@NotNull Location location, @NotNull Class clazz, @Nullable Consumer function) throws IllegalArgumentException { + return spawn(location, clazz, CreatureSpawnEvent.SpawnReason.CUSTOM, function); + } + + @NotNull ++ public default T spawn(@NotNull Location location, @NotNull Class clazz, @NotNull CreatureSpawnEvent.SpawnReason reason) throws IllegalArgumentException { ++ return spawn(location, clazz, reason, null); ++ } ++ ++ @NotNull + public default T spawn(@NotNull Location location, @NotNull Class clazz, @NotNull CreatureSpawnEvent.SpawnReason reason, @Nullable Consumer function) throws IllegalArgumentException { + return spawn(location, clazz, function, reason); + } + + @NotNull -+ public default Entity spawnEntity(@NotNull Location loc, @NotNull EntityType type, @NotNull CreatureSpawnEvent.SpawnReason reason) { ++ public default Entity spawnEntity(@NotNull Location loc, @NotNull org.bukkit.entity.EntityType type, @NotNull CreatureSpawnEvent.SpawnReason reason) { + return spawn(loc, (Class) type.getEntityClass(), reason, null); + } + + @NotNull -+ public default Entity spawnEntity(@NotNull Location loc, @NotNull EntityType type, @NotNull CreatureSpawnEvent.SpawnReason reason, @Nullable Consumer function) { ++ public default Entity spawnEntity(@NotNull Location loc, @NotNull org.bukkit.entity.EntityType type, @NotNull CreatureSpawnEvent.SpawnReason reason, @Nullable Consumer function) { + return spawn(loc, (Class) type.getEntityClass(), reason, function); + } + @@ -59,4 +51,4 @@ index cd96c851d00185e7ee3ec6682b166fc1d06b6a73..10c22809535b6151b45aa18a02b80b8f + // Paper end /** - * Spawn a {@link FallingBlock} entity at the given {@link Location} of + * Creates a new entity at the given {@link Location} with the supplied diff --git a/patches/api/0217-Allow-delegation-to-vanilla-chunk-gen.patch b/patches/api/0217-Allow-delegation-to-vanilla-chunk-gen.patch index c730d55f24..f346c955c6 100644 --- a/patches/api/0217-Allow-delegation-to-vanilla-chunk-gen.patch +++ b/patches/api/0217-Allow-delegation-to-vanilla-chunk-gen.patch @@ -57,10 +57,10 @@ index 2b21ffb60312cdd2033096b52155610b689f3294..a0695411d3a55babd3cb5f926c349698 * Creates a boss bar instance to display to players. The progress * defaults to 1.0 diff --git a/src/main/java/org/bukkit/generator/ChunkGenerator.java b/src/main/java/org/bukkit/generator/ChunkGenerator.java -index 9d7592988a2fbcc70f889b0622adbef014054d00..244a8a93c35d5a84e17672ff745051587bca384c 100644 +index 80fcd02e9cb5f432f21b1f68fd8266f296becaa0..0667315e2bd10254aef59c2a6bcceee9d927b6d5 100644 --- a/src/main/java/org/bukkit/generator/ChunkGenerator.java +++ b/src/main/java/org/bukkit/generator/ChunkGenerator.java -@@ -227,6 +227,22 @@ public abstract class ChunkGenerator { +@@ -454,6 +454,22 @@ public abstract class ChunkGenerator { return false; } diff --git a/patches/api/0220-Add-moon-phase-API.patch b/patches/api/0220-Add-moon-phase-API.patch index 364b9c106b..4d135f999c 100644 --- a/patches/api/0220-Add-moon-phase-API.patch +++ b/patches/api/0220-Add-moon-phase-API.patch @@ -47,10 +47,10 @@ index 0000000000000000000000000000000000000000..df05153397b42930cd53d37b30824c7e + } +} diff --git a/src/main/java/org/bukkit/World.java b/src/main/java/org/bukkit/World.java -index 10c22809535b6151b45aa18a02b80b8f2e3e6dff..27d97cde0fb5f6d727656c291e34dc468200f0c0 100644 +index 823ac73c8bb30b142a51ed25858b7f3449bf8c83..a805cb95e0695a0729e083ea0995a1ef02b3724f 100644 --- a/src/main/java/org/bukkit/World.java +++ b/src/main/java/org/bukkit/World.java -@@ -70,6 +70,12 @@ public interface World extends PluginMessageRecipient, Metadatable, net.kyori.ad +@@ -68,6 +68,12 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient * @return The amount of Players in this world */ int getPlayerCount(); diff --git a/patches/api/0282-Implement-Keyed-on-World.patch b/patches/api/0282-Implement-Keyed-on-World.patch index a4298b4e0d..5aa55bf968 100644 --- a/patches/api/0282-Implement-Keyed-on-World.patch +++ b/patches/api/0282-Implement-Keyed-on-World.patch @@ -5,7 +5,7 @@ Subject: [PATCH] Implement Keyed on World diff --git a/src/main/java/org/bukkit/Bukkit.java b/src/main/java/org/bukkit/Bukkit.java -index cf7138a9251e92065fef8b0090eaaf779064e2fc..4bd7fee100800d0ede600afcde2277b1de9e52f2 100644 +index 9cd632751c7e15c79b65209d69c76e8ae1916deb..fa99f414c2ce515bbdb6d8ca7bb94aa2ad1f640a 100644 --- a/src/main/java/org/bukkit/Bukkit.java +++ b/src/main/java/org/bukkit/Bukkit.java @@ -663,6 +663,18 @@ public final class Bukkit { @@ -28,7 +28,7 @@ index cf7138a9251e92065fef8b0090eaaf779064e2fc..4bd7fee100800d0ede600afcde2277b1 /** * Gets the map from the given item ID. diff --git a/src/main/java/org/bukkit/Server.java b/src/main/java/org/bukkit/Server.java -index 724a32e4a4861f9f9a8ffc5b5a497b458efffc0f..dcdd0c3f3d03e4a3043909cf051faeb665115c34 100644 +index 3e77a6a294afa41e3dd0e5288b4a761d77ee18ff..14dc56c8e7702e63875f6d2f8aa804a109107456 100644 --- a/src/main/java/org/bukkit/Server.java +++ b/src/main/java/org/bukkit/Server.java @@ -561,6 +561,17 @@ public interface Server extends PluginMessageRecipient, net.kyori.adventure.audi @@ -50,19 +50,19 @@ index 724a32e4a4861f9f9a8ffc5b5a497b458efffc0f..dcdd0c3f3d03e4a3043909cf051faeb6 * Gets the map from the given item ID. * diff --git a/src/main/java/org/bukkit/World.java b/src/main/java/org/bukkit/World.java -index 27d97cde0fb5f6d727656c291e34dc468200f0c0..178a0853bd8136c6a7408f5d49604ceb2479f138 100644 +index 61403e0d86ef3ab799dfcf490830e515f064bd73..00fc240c2da96d937ade789a1110190d6cd79254 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; +@@ -41,7 +41,7 @@ import org.jetbrains.annotations.Nullable; /** * Represents a world, which may contain entities, chunks and blocks */ --public interface World extends PluginMessageRecipient, Metadatable, net.kyori.adventure.audience.ForwardingAudience { // Paper -+public interface World extends PluginMessageRecipient, Metadatable, net.kyori.adventure.audience.ForwardingAudience, Keyed { // Paper +-public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient, Metadatable, net.kyori.adventure.audience.ForwardingAudience { // Paper ++public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient, Metadatable, net.kyori.adventure.audience.ForwardingAudience, Keyed { // Paper // Paper start /** -@@ -1534,6 +1534,15 @@ public interface World extends PluginMessageRecipient, Metadatable, net.kyori.ad +@@ -1525,6 +1525,15 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient @NotNull java.util.concurrent.CompletableFuture getChunkAtAsync(int x, int z, boolean gen, boolean urgent); @@ -79,10 +79,10 @@ index 27d97cde0fb5f6d727656c291e34dc468200f0c0..178a0853bd8136c6a7408f5d49604ceb /** diff --git a/src/main/java/org/bukkit/WorldCreator.java b/src/main/java/org/bukkit/WorldCreator.java -index 6774c8176c44dea9cbff69aaf0f27c0a53a2bbb4..c0454d977119b28115b7698a2c4287f0f56efa55 100644 +index 60bed20c2845f9dc15ecbed81157a63d75a4c4f4..14986911b4d0099ea2c91ab2196a771b7dee4c50 100644 --- a/src/main/java/org/bukkit/WorldCreator.java +++ b/src/main/java/org/bukkit/WorldCreator.java -@@ -11,6 +11,7 @@ import org.jetbrains.annotations.Nullable; +@@ -12,6 +12,7 @@ import org.jetbrains.annotations.Nullable; * Represents various types of options that may be used to create a world. */ public class WorldCreator { @@ -90,7 +90,7 @@ index 6774c8176c44dea9cbff69aaf0f27c0a53a2bbb4..c0454d977119b28115b7698a2c4287f0 private final String name; private long seed; private World.Environment environment = World.Environment.NORMAL; -@@ -26,13 +27,67 @@ public class WorldCreator { +@@ -28,13 +29,67 @@ public class WorldCreator { * @param name Name of the world that will be created */ public WorldCreator(@NotNull String name) { diff --git a/patches/api/0291-More-World-API.patch b/patches/api/0291-More-World-API.patch index 32c4912519..41047ddf9b 100644 --- a/patches/api/0291-More-World-API.patch +++ b/patches/api/0291-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 e149ab9b4ccd1b98791c3ebe5e9c7eb97de853af..4d8be6f200dbe2bd534a7f62152074dca59f9db4 100644 +index 00fc240c2da96d937ade789a1110190d6cd79254..59f11b9f36a7fdf7240daf93ea3f2af99d7ec255 100644 --- a/src/main/java/org/bukkit/World.java +++ b/src/main/java/org/bukkit/World.java -@@ -3564,6 +3564,114 @@ public interface World extends PluginMessageRecipient, Metadatable, net.kyori.ad +@@ -3434,6 +3434,114 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient @Nullable public Location locateNearestStructure(@NotNull Location origin, @NotNull StructureType structureType, int radius, boolean findUnexplored); diff --git a/patches/api/0318-Add-more-line-of-sight-methods.patch b/patches/api/0318-Add-more-line-of-sight-methods.patch index b0121b47ab..006cdd2d06 100644 --- a/patches/api/0318-Add-more-line-of-sight-methods.patch +++ b/patches/api/0318-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/World.java b/src/main/java/org/bukkit/World.java -index 244bb359492ae486f0610f5aea6b75997dbc4bdc..8ae9198ba7fdb006dc420504a984627add20dbb5 100644 +index 4834a48100922c6452448d4ef2a75377c7a5afa2..3d06947726ee7072ab8b62722e690f189f3935ab 100644 --- a/src/main/java/org/bukkit/World.java +++ b/src/main/java/org/bukkit/World.java -@@ -76,6 +76,14 @@ public interface World extends PluginMessageRecipient, Metadatable, net.kyori.ad +@@ -74,6 +74,14 @@ public interface World extends RegionAccessor, WorldInfo, PluginMessageRecipient */ @NotNull io.papermc.paper.world.MoonPhase getMoonPhase(); diff --git a/patches/api/0319-Add-Feature-Stage-API.patch b/patches/api/0319-Add-Feature-Stage-API.patch index 3bd221105e..c7db5c3e46 100644 --- a/patches/api/0319-Add-Feature-Stage-API.patch +++ b/patches/api/0319-Add-Feature-Stage-API.patch @@ -324,10 +324,10 @@ index 0000000000000000000000000000000000000000..f3b465d3883547d53e55183c2a4e22c6 + @NotNull T spawn(@NotNull Vector location, @NotNull Class clazz, @Nullable Consumer function, @NotNull CreatureSpawnEvent.SpawnReason reason) throws IllegalArgumentException; +} diff --git a/src/main/java/org/bukkit/generator/ChunkGenerator.java b/src/main/java/org/bukkit/generator/ChunkGenerator.java -index 244a8a93c35d5a84e17672ff745051587bca384c..e547f324790ca27dfb85b030988fc03bfc6107f1 100644 +index 0667315e2bd10254aef59c2a6bcceee9d927b6d5..5cf3f8875753b0293ea56b65a64f0075b03257c3 100644 --- a/src/main/java/org/bukkit/generator/ChunkGenerator.java +++ b/src/main/java/org/bukkit/generator/ChunkGenerator.java -@@ -161,6 +161,19 @@ public abstract class ChunkGenerator { +@@ -343,6 +343,19 @@ public abstract class ChunkGenerator { return new ArrayList(); } diff --git a/patches/server/0004-Paper-config-files.patch b/patches/server/0004-Paper-config-files.patch index 47cc354a6f..c04c5052f4 100644 --- a/patches/server/0004-Paper-config-files.patch +++ b/patches/server/0004-Paper-config-files.patch @@ -660,7 +660,7 @@ index 067216078c7b50390957d1fcfbfbaaeb81cfba21..7f3d83d3d071f6b441ad119b1c93be03 + // Paper end } diff --git a/src/main/java/net/minecraft/world/level/Level.java b/src/main/java/net/minecraft/world/level/Level.java -index 7f81dd05ec8945a851b6501854dc894cad240a66..d6b2e7d643f907ddd81d394d9b613e9ce93a786e 100644 +index ae26cf65169fd25520263a3edb93424383fa7bb0..5de52a4c33fd136b43b150b7ed0df7703f4b2817 100644 --- a/src/main/java/net/minecraft/world/level/Level.java +++ b/src/main/java/net/minecraft/world/level/Level.java @@ -147,6 +147,8 @@ public abstract class Level implements LevelAccessor, AutoCloseable { @@ -674,17 +674,17 @@ index 7f81dd05ec8945a851b6501854dc894cad240a66..d6b2e7d643f907ddd81d394d9b613e9c private org.spigotmc.TickLimiter entityLimiter; @@ -167,6 +169,7 @@ public abstract class Level implements LevelAccessor, AutoCloseable { - protected Level(WritableLevelData worlddatamutable, ResourceKey resourcekey, final DimensionType dimensionmanager, Supplier supplier, boolean flag, boolean flag1, long i, org.bukkit.generator.ChunkGenerator gen, org.bukkit.World.Environment env) { + protected Level(WritableLevelData worlddatamutable, ResourceKey resourcekey, final DimensionType dimensionmanager, Supplier supplier, boolean flag, boolean flag1, long i, org.bukkit.generator.ChunkGenerator gen, org.bukkit.generator.BiomeProvider biomeProvider, org.bukkit.World.Environment env) { this.spigotConfig = new org.spigotmc.SpigotWorldConfig(((net.minecraft.world.level.storage.PrimaryLevelData) worlddatamutable).getLevelName()); // Spigot + this.paperConfig = new com.destroystokyo.paper.PaperWorldConfig(((net.minecraft.world.level.storage.PrimaryLevelData) worlddatamutable).getLevelName(), this.spigotConfig); // Paper this.generator = gen; - this.world = new CraftWorld((ServerLevel) this, gen, env); + this.world = new CraftWorld((ServerLevel) this, gen, biomeProvider, env); this.ticksPerAnimalSpawns = this.getCraftServer().getTicksPerAnimalSpawns(); // CraftBukkit diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index ace054af2d4f1ab026ee6a5d96e35e7cc7fd53f8..7964acaef50a1786c0510e04723e1ec8dc682757 100644 +index 289838b07b027dad54789c977db87fd7637577a0..127386a7d436d9e6a54ee66e7a40a20b73be6481 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -814,6 +814,7 @@ public final class CraftServer implements Server { +@@ -820,6 +820,7 @@ public final class CraftServer implements Server { } org.spigotmc.SpigotConfig.init((File) console.options.valueOf("spigot-settings")); // Spigot @@ -692,7 +692,7 @@ index ace054af2d4f1ab026ee6a5d96e35e7cc7fd53f8..7964acaef50a1786c0510e04723e1ec8 for (ServerLevel world : this.console.getAllLevels()) { world.serverLevelData.setDifficulty(config.difficulty); world.setSpawnSettings(config.spawnMonsters, config.spawnAnimals); -@@ -847,12 +848,14 @@ public final class CraftServer implements Server { +@@ -853,12 +854,14 @@ public final class CraftServer implements Server { world.ticksPerAmbientSpawns = this.getTicksPerAmbientSpawns(); } world.spigotConfig.init(); // Spigot @@ -707,7 +707,7 @@ index ace054af2d4f1ab026ee6a5d96e35e7cc7fd53f8..7964acaef50a1786c0510e04723e1ec8 this.overrideAllCommandBlockCommands = this.commandsConfiguration.getStringList("command-block-overrides").contains("*"); this.ignoreVanillaPermissions = this.commandsConfiguration.getBoolean("ignore-vanilla-permissions"); -@@ -2188,4 +2191,35 @@ public final class CraftServer implements Server { +@@ -2247,4 +2250,35 @@ public final class CraftServer implements Server { return this.spigot; } // Spigot end @@ -744,7 +744,7 @@ index ace054af2d4f1ab026ee6a5d96e35e7cc7fd53f8..7964acaef50a1786c0510e04723e1ec8 + // Paper end } diff --git a/src/main/java/org/bukkit/craftbukkit/Main.java b/src/main/java/org/bukkit/craftbukkit/Main.java -index 7f818c6bed25e0b793cca268b786f61440c429ef..1ac3243555c2c61d6b6717e6826539d9d6a3248b 100644 +index 90af1b123722bac1c4c5956465a153ec1ea998ff..11d1bc56439ff867224ef1c2058aee67ba0ee332 100644 --- a/src/main/java/org/bukkit/craftbukkit/Main.java +++ b/src/main/java/org/bukkit/craftbukkit/Main.java @@ -129,6 +129,14 @@ public class Main { diff --git a/patches/server/0005-MC-Dev-fixes.patch b/patches/server/0005-MC-Dev-fixes.patch index 2f795f32e1..f4f48505b0 100644 --- a/patches/server/0005-MC-Dev-fixes.patch +++ b/patches/server/0005-MC-Dev-fixes.patch @@ -157,10 +157,10 @@ index 3db1f50262df75dc99fd5a1224985cd9f5f14c9f..6611aebafb14b83bce3eeb87701e2edc private static final int MIN_PROTOCOL_ID = -1; private static final int MAX_PROTOCOL_ID = 2; diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java -index bae8c5ccfc32c2a36a1f7e03ab4fb762dc3ff2c8..b5f3bf8ff585c518326b0dcb5b793f181d52505f 100644 +index 4e8e28b0224aab1d40cae17d330488c09d5497a8..6f56df5b0550735e3da122729080125c3dff5d06 100644 --- a/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java -@@ -1768,7 +1768,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop implements SnooperPopulator, CommandSource, AutoCloseable { -@@ -895,6 +895,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop= 5000000000L) { -@@ -1216,14 +1237,12 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop 0 && this.tickCount % this.autosavePeriod == 0) { // CraftBukkit @@ -861,7 +861,7 @@ index 571e57affcf81151550184b45934ae810885145f..fcc775723bcef7c6b740ee332c21ef70 } this.profiler.push("snooper"); -@@ -1236,6 +1255,13 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop chunkConsumer) { diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java -index 912c9b0c010436854fab7540b0c9cc63115e39a4..253d62b0da6bd59363a85139a5a5d5f11169466a 100644 +index f9fde3155944bb44ecb14524c585ed8eb9eac78c..0db1607dc6bbf0def58bdc14fca33dbaa48a8e40 100644 --- a/src/main/java/net/minecraft/server/level/ServerLevel.java +++ b/src/main/java/net/minecraft/server/level/ServerLevel.java @@ -1,6 +1,8 @@ @@ -1450,7 +1450,7 @@ index 8c4744b3a3ebf73d31f59d1566320031550aa3bb..c731f22390773bcd43d392b86ae5b42b 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 01a5c95c40b39ba71add80f65359e390b9079f4e..11f9be795dc622f84866acf461cf3b3190b3d62c 100644 +index 89ed84d2e3ac8f25785a2d39b4fd37e50497e49e..96f8a886f348c1e18b4b1b97579ea44d43a05a44 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java @@ -126,7 +126,6 @@ import org.bukkit.craftbukkit.event.CraftPortalEvent; @@ -1461,7 +1461,7 @@ index 01a5c95c40b39ba71add80f65359e390b9079f4e..11f9be795dc622f84866acf461cf3b31 import org.bukkit.event.entity.EntityCombustByEntityEvent; import org.bukkit.event.hanging.HangingBreakByEntityEvent; import org.bukkit.event.vehicle.VehicleBlockCollisionEvent; -@@ -281,7 +280,6 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n +@@ -282,7 +281,6 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n public org.bukkit.projectiles.ProjectileSource projectileSource; // For projectiles only public boolean forceExplosionKnockback; // SPIGOT-949 public boolean persistentInvisibility = false; @@ -1469,7 +1469,7 @@ index 01a5c95c40b39ba71add80f65359e390b9079f4e..11f9be795dc622f84866acf461cf3b31 // Spigot start public final org.spigotmc.ActivationRange.ActivationType activationType = org.spigotmc.ActivationRange.initializeEntityActivationType(this); public final boolean defaultActivationState; -@@ -716,7 +714,6 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n +@@ -717,7 +715,6 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n } public void move(MoverType movementType, Vec3 movement) { @@ -1477,7 +1477,7 @@ index 01a5c95c40b39ba71add80f65359e390b9079f4e..11f9be795dc622f84866acf461cf3b31 if (this.noPhysics) { this.setPos(this.getX() + movement.x, this.getY() + movement.y, this.getZ() + movement.z); } else { -@@ -863,7 +860,6 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n +@@ -864,7 +861,6 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n this.level.getProfiler().pop(); } } @@ -1549,7 +1549,7 @@ index 7f3d83d3d071f6b441ad119b1c93be035e911e70..8d5c61a77bea2f2f5dbff26cb479f855 } diff --git a/src/main/java/net/minecraft/world/entity/LivingEntity.java b/src/main/java/net/minecraft/world/entity/LivingEntity.java -index 3b09f76805053802bb779e227749d81482636407..759cd74cda7f0d1f3c0f3bc0a2a941e16258a1c0 100644 +index 2473816c70c05662d75f6b875b46a4e53d7b76fa..914f69157ac5e5e9e77de968c4e328d8f44b9465 100644 --- a/src/main/java/net/minecraft/world/entity/LivingEntity.java +++ b/src/main/java/net/minecraft/world/entity/LivingEntity.java @@ -140,7 +140,7 @@ import org.bukkit.event.entity.EntityTeleportEvent; @@ -1627,7 +1627,7 @@ index 3b09f76805053802bb779e227749d81482636407..759cd74cda7f0d1f3c0f3bc0a2a941e1 if (!this.level.isClientSide && this.isSensitiveToWater() && this.isInWaterRainOrBubble()) { this.hurt(DamageSource.DROWN, 1.0F); diff --git a/src/main/java/net/minecraft/world/level/Level.java b/src/main/java/net/minecraft/world/level/Level.java -index 3286beed6bf79f5f6b91227f596fcc43200e8bda..e38cd4df0924cce7fee4fd98967990945a62ecf4 100644 +index 03b87448628f41699336245cbf0f882d3fe20f7e..64bf654a622e2b5e79c45d288c812e32518769c6 100644 --- a/src/main/java/net/minecraft/world/level/Level.java +++ b/src/main/java/net/minecraft/world/level/Level.java @@ -82,7 +82,6 @@ import org.bukkit.Bukkit; @@ -1823,10 +1823,10 @@ index b645a2fc839dbf922ce73b23b7d53e9a5fe1a2ee..1b478ebfe6792a157772a5812d0daa1a private static CompoundTag packStructureData(ServerLevel world, ChunkPos chunkcoordintpair, Map, StructureStart> map, Map, LongSet> map1) { diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 7964acaef50a1786c0510e04723e1ec8dc682757..02d8cfeaea105d42a437b08c3ba59c50eda5a452 100644 +index 127386a7d436d9e6a54ee66e7a40a20b73be6481..5749657a70191d52932a45d810bb07d8efd29531 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -2160,12 +2160,31 @@ public final class CraftServer implements Server { +@@ -2219,12 +2219,31 @@ public final class CraftServer implements Server { private final org.bukkit.Server.Spigot spigot = new org.bukkit.Server.Spigot() { diff --git a/patches/server/0010-Adventure.patch b/patches/server/0010-Adventure.patch index 24fd1b659e..33215439e6 100644 --- a/patches/server/0010-Adventure.patch +++ b/patches/server/0010-Adventure.patch @@ -1702,10 +1702,10 @@ index 7a0e7961df1e62b311ea2ecc76d7343a8646723b..6859fafa42527d45366018f737c19e6c } collection = icons; diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 02d8cfeaea105d42a437b08c3ba59c50eda5a452..6ba6e88174644cfea81445f1e8483e8118744027 100644 +index 5749657a70191d52932a45d810bb07d8efd29531..70d1ac0c352f16ee2dc394e5df31eea02d7c3ad9 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -573,8 +573,10 @@ public final class CraftServer implements Server { +@@ -579,8 +579,10 @@ public final class CraftServer implements Server { } @Override @@ -1716,7 +1716,7 @@ index 02d8cfeaea105d42a437b08c3ba59c50eda5a452..6ba6e88174644cfea81445f1e8483e81 } @Override -@@ -1382,7 +1384,15 @@ public final class CraftServer implements Server { +@@ -1405,7 +1407,15 @@ public final class CraftServer implements Server { return this.configuration.getInt("settings.spawn-radius", -1); } @@ -1732,7 +1732,7 @@ index 02d8cfeaea105d42a437b08c3ba59c50eda5a452..6ba6e88174644cfea81445f1e8483e81 public String getShutdownMessage() { return this.configuration.getString("settings.shutdown-message"); } -@@ -1499,7 +1509,20 @@ public final class CraftServer implements Server { +@@ -1558,7 +1568,20 @@ public final class CraftServer implements Server { } @Override @@ -1753,7 +1753,7 @@ index 02d8cfeaea105d42a437b08c3ba59c50eda5a452..6ba6e88174644cfea81445f1e8483e81 Set recipients = new HashSet<>(); for (Permissible permissible : this.getPluginManager().getPermissionSubscriptions(permission)) { if (permissible instanceof CommandSender && permissible.hasPermission(permission)) { -@@ -1507,14 +1530,14 @@ public final class CraftServer implements Server { +@@ -1566,14 +1589,14 @@ public final class CraftServer implements Server { } } @@ -1770,7 +1770,7 @@ index 02d8cfeaea105d42a437b08c3ba59c50eda5a452..6ba6e88174644cfea81445f1e8483e81 for (CommandSender recipient : recipients) { recipient.sendMessage(message); -@@ -1750,6 +1773,14 @@ public final class CraftServer implements Server { +@@ -1809,6 +1832,14 @@ public final class CraftServer implements Server { return CraftInventoryCreator.INSTANCE.createInventory(owner, type); } @@ -1785,7 +1785,7 @@ index 02d8cfeaea105d42a437b08c3ba59c50eda5a452..6ba6e88174644cfea81445f1e8483e81 @Override public Inventory createInventory(InventoryHolder owner, InventoryType type, String title) { Validate.isTrue(type.isCreatable(), "Cannot open an inventory of type ", type); -@@ -1762,13 +1793,28 @@ public final class CraftServer implements Server { +@@ -1821,13 +1852,28 @@ public final class CraftServer implements Server { return CraftInventoryCreator.INSTANCE.createInventory(owner, size); } @@ -1814,7 +1814,7 @@ index 02d8cfeaea105d42a437b08c3ba59c50eda5a452..6ba6e88174644cfea81445f1e8483e81 public Merchant createMerchant(String title) { return new CraftMerchantCustom(title == null ? InventoryType.MERCHANT.getDefaultTitle() : title); } -@@ -1812,6 +1858,12 @@ public final class CraftServer implements Server { +@@ -1871,6 +1917,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) } @@ -1827,7 +1827,7 @@ index 02d8cfeaea105d42a437b08c3ba59c50eda5a452..6ba6e88174644cfea81445f1e8483e81 @Override public String getMotd() { return this.console.getMotd(); -@@ -2240,5 +2292,15 @@ public final class CraftServer implements Server { +@@ -2299,5 +2351,15 @@ public final class CraftServer implements Server { return null; } } @@ -1844,7 +1844,7 @@ index 02d8cfeaea105d42a437b08c3ba59c50eda5a452..6ba6e88174644cfea81445f1e8483e81 // Paper end } diff --git a/src/main/java/org/bukkit/craftbukkit/Main.java b/src/main/java/org/bukkit/craftbukkit/Main.java -index 5944e75b9501a3f9f25be5efe11351dd337158c5..e4cd36cf6626ad702ee654587b2f8c5442e4fe2b 100644 +index 11d1bc56439ff867224ef1c2058aee67ba0ee332..52f78b8a3d4588f9aba10c8aea4d36cb02f1f54f 100644 --- a/src/main/java/org/bukkit/craftbukkit/Main.java +++ b/src/main/java/org/bukkit/craftbukkit/Main.java @@ -19,6 +19,12 @@ public class Main { @@ -1861,10 +1861,10 @@ index 5944e75b9501a3f9f25be5efe11351dd337158c5..e4cd36cf6626ad702ee654587b2f8c54 OptionParser parser = new OptionParser() { { diff --git a/src/main/java/org/bukkit/craftbukkit/block/CraftBeacon.java b/src/main/java/org/bukkit/craftbukkit/block/CraftBeacon.java -index 95b8d32adedf579172187c594e18177f3a84850e..5abf219e86c6b4cf0c6b2e8ea72d7ed7b4f612e3 100644 +index 449f42b324e31e1a28562b1fe99416f8925f5204..c35e1964a295032623cf9cb6ade84e69ed92194f 100644 --- a/src/main/java/org/bukkit/craftbukkit/block/CraftBeacon.java +++ b/src/main/java/org/bukkit/craftbukkit/block/CraftBeacon.java -@@ -70,6 +70,19 @@ public class CraftBeacon extends CraftBlockEntityState implem +@@ -73,6 +73,19 @@ public class CraftBeacon extends CraftBlockEntityState implem this.getSnapshot().secondaryPower = (effect != null) ? MobEffect.byId(effect.getId()) : null; } @@ -2083,10 +2083,10 @@ index cf69a45f038c2b8336010f5fe277313fd0513b5b..eb99e0c2462a2d1ab4508a5c3f1580b6 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 3aecaf187b0360eb0e5dc9a8948c834cf3401ad8..8d7d256fa33635807d187d493e71b6b4e17fa2e8 100644 +index f13410c3376c7c5b666c803666ba23a40fbea8a0..3f7e976d5490768d71e8ce5344d3d150039cdc21 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java -@@ -810,6 +810,19 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity { +@@ -815,6 +815,19 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity { return this.getHandle().getVehicle().getBukkitEntity(); } diff --git a/patches/server/0014-Allow-nerfed-mobs-to-jump-and-take-water-damage.patch b/patches/server/0014-Allow-nerfed-mobs-to-jump-and-take-water-damage.patch index b14895a01d..2ff607b54c 100644 --- a/patches/server/0014-Allow-nerfed-mobs-to-jump-and-take-water-damage.patch +++ b/patches/server/0014-Allow-nerfed-mobs-to-jump-and-take-water-damage.patch @@ -19,10 +19,10 @@ index 78948c42b13194005bdbbbc69c2b7ae0732a78c5..b41e7922dd96c3358eb849ab39982a75 + } } diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index 11f9be795dc622f84866acf461cf3b3190b3d62c..8369238dd8042310b8e2aa10e463a3a9f9f7ec64 100644 +index 96f8a886f348c1e18b4b1b97579ea44d43a05a44..f1230adeaf399424630412975310cb3e31ed001f 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -1264,6 +1264,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n +@@ -1265,6 +1265,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n return this.isInWater() || this.isInRain(); } @@ -31,7 +31,7 @@ index 11f9be795dc622f84866acf461cf3b3190b3d62c..8369238dd8042310b8e2aa10e463a3a9 return this.isInWater() || this.isInRain() || this.isInBubbleColumn(); } diff --git a/src/main/java/net/minecraft/world/entity/Mob.java b/src/main/java/net/minecraft/world/entity/Mob.java -index 9d9d7990c49fd37c660efcb2c87a6c3495d648a6..5c01a30ccdcf05f516700fb95a46606f2c4cfc6b 100644 +index d0047fc5156f13c831ab4f23a429d567ed6a39ac..abaa57d9a4d222753d28801c6ab86b11c71aca6b 100644 --- a/src/main/java/net/minecraft/world/entity/Mob.java +++ b/src/main/java/net/minecraft/world/entity/Mob.java @@ -104,6 +104,7 @@ public abstract class Mob extends LivingEntity { diff --git a/patches/server/0018-Show-Paper-in-client-crashes-server-lists-and-Mojang.patch b/patches/server/0018-Show-Paper-in-client-crashes-server-lists-and-Mojang.patch index e3ef06fea3..fc597576db 100644 --- a/patches/server/0018-Show-Paper-in-client-crashes-server-lists-and-Mojang.patch +++ b/patches/server/0018-Show-Paper-in-client-crashes-server-lists-and-Mojang.patch @@ -19,10 +19,10 @@ index 2c53a400611c78236c5a1c1270d27c02e94251bf..a1d5c0f8fe2adb2ee56f3217e089211e if (outputStream != null) { try { diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java -index fcc775723bcef7c6b740ee332c21ef70e591c77e..0ee92562ef7c6ac99f5bea0b6d0751d0add50f16 100644 +index b3707d09bd73c306ea5e87785e6754ede9fc2846..cb1caae296d8d27d65f6f63f0f86aee53d363664 100644 --- a/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java -@@ -1420,7 +1420,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop processQueue = new java.util.concurrent.ConcurrentLinkedQueue(); public int autosavePeriod; public Commands vanillaCommandDispatcher; -@@ -290,7 +290,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop playerView; public int reloadCount; @@ -17,7 +17,7 @@ index a493f3ae60f2b2f4397a0b81f25a014d9edc805d..ea8ed9c3d83e7038c334779b7bd37392 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 3510448dd6964981cd9aa64c24c85c310eb75971..99bd0df1351c356b0ff9f5d864ba5dad89c90acf 100644 +index 118ba56a539471bded0cb42334576d5394aee4ab..7e50d589724c15ce30424cf1d82eb56e84acd28b 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java @@ -435,10 +435,40 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity { diff --git a/patches/server/0055-Disable-Scoreboards-for-non-players-by-default.patch b/patches/server/0055-Disable-Scoreboards-for-non-players-by-default.patch index dcca2da812..7e84d7c0d2 100644 --- a/patches/server/0055-Disable-Scoreboards-for-non-players-by-default.patch +++ b/patches/server/0055-Disable-Scoreboards-for-non-players-by-default.patch @@ -25,10 +25,10 @@ index abbbe1786eb68af02f9d39650aad730ac44aac8a..3ac2ac3db9b1c271b3c21930bb137166 + } } diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index df636b5510693821d9e159624b5ae2c6451d2299..edb75ce3fe60bc0730b99edca3a6e03ee15714c0 100644 +index db2933ed070a75bf4f46e37b52a8dbb7e9afb364..76304c6bd6b9509cf83e4a580ebdecdc10b64354 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -2549,6 +2549,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n +@@ -2550,6 +2550,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n @Nullable public Team getTeam() { @@ -37,7 +37,7 @@ index df636b5510693821d9e159624b5ae2c6451d2299..edb75ce3fe60bc0730b99edca3a6e03e } diff --git a/src/main/java/net/minecraft/world/entity/LivingEntity.java b/src/main/java/net/minecraft/world/entity/LivingEntity.java -index 5b285714ce231d45d879be83ae36d94eaa8310c0..6c2adddb3d55e5384d1386788bce13ee4c7a6bbe 100644 +index 0f1a9e7561f6df4844545ff4565e996bb21eb9dc..200aca8237dd7fbb0e4959831bda877c58ec37fb 100644 --- a/src/main/java/net/minecraft/world/entity/LivingEntity.java +++ b/src/main/java/net/minecraft/world/entity/LivingEntity.java @@ -803,6 +803,7 @@ public abstract class LivingEntity extends Entity { diff --git a/patches/server/0056-Add-methods-for-working-with-arrows-stuck-in-living-.patch b/patches/server/0056-Add-methods-for-working-with-arrows-stuck-in-living-.patch index eca15ea8fb..9a455c8865 100644 --- a/patches/server/0056-Add-methods-for-working-with-arrows-stuck-in-living-.patch +++ b/patches/server/0056-Add-methods-for-working-with-arrows-stuck-in-living-.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Add methods for working with arrows stuck in living entities diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java -index 97dc4aa5dc3cb5cb21e9a2e316a3f729d6896b85..9e98e854b6b3f8dac3990abaa1c9f60fd1ff3836 100644 +index 8e97b3985056caa2aa692ec6250022e095d0b3a6..e955126fc82dfcdadb824c8d2d15e8b1f33bc67f 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java -@@ -690,4 +690,16 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity { +@@ -713,4 +713,16 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity { this.getHandle().persistentInvisibility = invisible; this.getHandle().setSharedFlag(5, invisible); } diff --git a/patches/server/0059-Default-loading-permissions.yml-before-plugins.patch b/patches/server/0059-Default-loading-permissions.yml-before-plugins.patch index c90b3983df..34ab1b461d 100644 --- a/patches/server/0059-Default-loading-permissions.yml-before-plugins.patch +++ b/patches/server/0059-Default-loading-permissions.yml-before-plugins.patch @@ -30,10 +30,10 @@ index 8330f57d57181002dab4599e2c1f477cf9e51784..e3ca633a99d30ebf9dc35fd9236836b5 + } } diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index ea8ed9c3d83e7038c334779b7bd3739286101f73..14d50ebcf9b229bf0664d200117d027983cbf1a2 100644 +index 7c9e42e85e2ccc220d30d72f3f1c2c139e195bbb..f3e50cebfbac08d9cf997faf99e63f750fff8a5c 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -409,6 +409,7 @@ public final class CraftServer implements Server { +@@ -415,6 +415,7 @@ public final class CraftServer implements Server { if (type == PluginLoadOrder.STARTUP) { this.helpMap.clear(); this.helpMap.initializeGeneralTopics(); @@ -41,7 +41,7 @@ index ea8ed9c3d83e7038c334779b7bd3739286101f73..14d50ebcf9b229bf0664d200117d0279 } Plugin[] plugins = this.pluginManager.getPlugins(); -@@ -428,7 +429,7 @@ public final class CraftServer implements Server { +@@ -434,7 +435,7 @@ public final class CraftServer implements Server { this.commandMap.registerServerAliases(); DefaultPermissions.registerCorePermissions(); CraftDefaultPermissions.registerCorePermissions(); diff --git a/patches/server/0060-Allow-Reloading-of-Custom-Permissions.patch b/patches/server/0060-Allow-Reloading-of-Custom-Permissions.patch index 75d10e9adf..7c9993a682 100644 --- a/patches/server/0060-Allow-Reloading-of-Custom-Permissions.patch +++ b/patches/server/0060-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 14d50ebcf9b229bf0664d200117d027983cbf1a2..71e5640c9416d95412638f2bceeb901b9188ac58 100644 +index f3e50cebfbac08d9cf997faf99e63f750fff8a5c..d9196e8268ffcdd5e696b98b4a384baa03d8bb21 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -2338,5 +2338,23 @@ public final class CraftServer implements Server { +@@ -2397,5 +2397,23 @@ public final class CraftServer implements Server { } return this.adventure$audiences; } diff --git a/patches/server/0061-Remove-Metadata-on-reload.patch b/patches/server/0061-Remove-Metadata-on-reload.patch index 5435b05905..4e743f6626 100644 --- a/patches/server/0061-Remove-Metadata-on-reload.patch +++ b/patches/server/0061-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 71e5640c9416d95412638f2bceeb901b9188ac58..0f30b58e047c1bc034b2e34ed8fc3823cddaaf7f 100644 +index d9196e8268ffcdd5e696b98b4a384baa03d8bb21..d4c1b181ac1d1f4aaedf2c2ace8aff632439c8d7 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -877,8 +877,16 @@ public final class CraftServer implements Server { +@@ -883,8 +883,16 @@ public final class CraftServer implements Server { world.paperConfig.init(); // Paper } diff --git a/patches/server/0062-Handle-Item-Meta-Inconsistencies.patch b/patches/server/0062-Handle-Item-Meta-Inconsistencies.patch index 2e03a8abb6..481aaee707 100644 --- a/patches/server/0062-Handle-Item-Meta-Inconsistencies.patch +++ b/patches/server/0062-Handle-Item-Meta-Inconsistencies.patch @@ -79,7 +79,7 @@ index ddf0889b20b42c17edc2678d809bddf3dacf4c8f..7f44e9e382aa87ad9be94394d05bbcac public boolean isEnchanted() { diff --git a/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemStack.java b/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemStack.java -index b89292f10e254616bfe3da4700eb12a9fd41f25d..45d61dbe785155501d9fa23e33b1954c5ad1c0e4 100644 +index d6467a42d54954dffe919482294cb9355f217f21..84f11780a22b3369519fc8f80d6c274360045df7 100644 --- a/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemStack.java +++ b/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemStack.java @@ -6,7 +6,6 @@ import java.util.Map; @@ -89,8 +89,8 @@ index b89292f10e254616bfe3da4700eb12a9fd41f25d..45d61dbe785155501d9fa23e33b1954c -import net.minecraft.world.item.enchantment.EnchantmentHelper; import org.apache.commons.lang.Validate; import org.bukkit.Material; - import org.bukkit.configuration.serialization.DelegateDeserialization; -@@ -177,28 +176,11 @@ public final class CraftItemStack extends ItemStack { + import org.bukkit.NamespacedKey; +@@ -178,28 +177,11 @@ public final class CraftItemStack extends ItemStack { public void addUnsafeEnchantment(Enchantment ench, int level) { Validate.notNull(ench, "Cannot add null enchantment"); @@ -107,7 +107,7 @@ index b89292f10e254616bfe3da4700eb12a9fd41f25d..45d61dbe785155501d9fa23e33b1954c - for (int i = 0; i < size; i++) { - CompoundTag tag = (CompoundTag) list.get(i); - String id = tag.getString(ENCHANTMENTS_ID.NBT); -- if (id.equals(ench.getKey().toString())) { +- if (ench.getKey().equals(NamespacedKey.fromString(id))) { - tag.putShort(ENCHANTMENTS_LVL.NBT, (short) level); - return; - } @@ -124,7 +124,7 @@ index b89292f10e254616bfe3da4700eb12a9fd41f25d..45d61dbe785155501d9fa23e33b1954c } static boolean makeTag(net.minecraft.world.item.ItemStack item) { -@@ -215,66 +197,34 @@ public final class CraftItemStack extends ItemStack { +@@ -216,66 +198,34 @@ public final class CraftItemStack extends ItemStack { @Override public boolean containsEnchantment(Enchantment ench) { @@ -157,7 +157,7 @@ index b89292f10e254616bfe3da4700eb12a9fd41f25d..45d61dbe785155501d9fa23e33b1954c - for (int i = 0; i < size; i++) { - CompoundTag enchantment = (CompoundTag) list.get(i); - String id = enchantment.getString(ENCHANTMENTS_ID.NBT); -- if (id.equals(ench.getKey().toString())) { +- if (ench.getKey().equals(NamespacedKey.fromString(id))) { - index = i; - level = 0xffff & enchantment.getShort(ENCHANTMENTS_LVL.NBT); - break; diff --git a/patches/server/0067-Use-a-Shared-Random-for-Entities.patch b/patches/server/0067-Use-a-Shared-Random-for-Entities.patch index dbc3024de1..92abbf3678 100644 --- a/patches/server/0067-Use-a-Shared-Random-for-Entities.patch +++ b/patches/server/0067-Use-a-Shared-Random-for-Entities.patch @@ -6,7 +6,7 @@ Subject: [PATCH] Use a Shared Random for Entities Reduces memory usage and provides ensures more randomness, Especially since a lot of garbage entity objects get created. diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index edb75ce3fe60bc0730b99edca3a6e03ee15714c0..8d667633a01b33d9dd1fd3314f367e0ea8733735 100644 +index 76304c6bd6b9509cf83e4a580ebdecdc10b64354..48ecf563e32315894fe363d95505c5899e6294c1 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java @@ -153,6 +153,21 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n @@ -31,7 +31,7 @@ index edb75ce3fe60bc0730b99edca3a6e03ee15714c0..8d667633a01b33d9dd1fd3314f367e0e private CraftEntity bukkitEntity; public CraftEntity getBukkitEntity() { -@@ -324,7 +339,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n +@@ -325,7 +340,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n this.bb = Entity.INITIAL_AABB; this.stuckSpeedMultiplier = Vec3.ZERO; this.nextStep = 1.0F; diff --git a/patches/server/0070-Only-process-BlockPhysicsEvent-if-a-plugin-has-a-lis.patch b/patches/server/0070-Only-process-BlockPhysicsEvent-if-a-plugin-has-a-lis.patch index 966576cf88..30311faf56 100644 --- a/patches/server/0070-Only-process-BlockPhysicsEvent-if-a-plugin-has-a-lis.patch +++ b/patches/server/0070-Only-process-BlockPhysicsEvent-if-a-plugin-has-a-lis.patch @@ -6,10 +6,10 @@ Subject: [PATCH] Only process BlockPhysicsEvent if a plugin has a listener Saves on some object allocation and processing when no plugin listens to this diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java -index d1267242746fe2aee0fd12ed01900e4e72df3f89..4ed4744c887ca52fa3f85ad4ea41e79543cc13ce 100644 +index 36305b91d6e529900074040b8448bc57b9ef85bd..597b8d4c79714484e7c8be6e4f90294a96259e4e 100644 --- a/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java -@@ -1365,6 +1365,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop { return worldserver + " " + worldserver.dimension().location(); diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java -index 7251c939dabb4591f1c30bd1b33b6e707615b6e9..ba964bc8b2d86b86be2d527fdc8d8aa342ac0e5e 100644 +index c19276ce8a2f4045ca7fe7b7600bd952b8bd5777..b178f93d38a865ae2841d044326370623065b112 100644 --- a/src/main/java/net/minecraft/server/level/ServerLevel.java +++ b/src/main/java/net/minecraft/server/level/ServerLevel.java @@ -197,6 +197,7 @@ public class ServerLevel extends Level implements WorldGenLevel { @@ -30,7 +30,7 @@ index 7251c939dabb4591f1c30bd1b33b6e707615b6e9..ba964bc8b2d86b86be2d527fdc8d8aa3 @Override public LevelChunk getChunkIfLoaded(int x, int z) { // Paper - this was added in world too but keeping here for NMS ABI return this.chunkSource.getChunk(x, z, false); diff --git a/src/main/java/net/minecraft/world/level/Level.java b/src/main/java/net/minecraft/world/level/Level.java -index c6dbace64d19de52112c64c824640cf48db216e3..5c395ffa57372dee3fc29e9bd4b5545211aec29c 100644 +index be2b000c899e52cc6a97b87c854f10cec44d8ea1..f05dcb3c9f17a0aa991fcbd3b3f58f507059a8cd 100644 --- a/src/main/java/net/minecraft/world/level/Level.java +++ b/src/main/java/net/minecraft/world/level/Level.java @@ -471,7 +471,7 @@ public abstract class Level implements LevelAccessor, AutoCloseable { diff --git a/patches/server/0083-Configurable-Player-Collision.patch b/patches/server/0083-Configurable-Player-Collision.patch index 238edbec43..74d98f7997 100644 --- a/patches/server/0083-Configurable-Player-Collision.patch +++ b/patches/server/0083-Configurable-Player-Collision.patch @@ -32,10 +32,10 @@ index 8885220e4813b34627b42523834bbec995d8950d..4c9660176e783999301565790b8cf6f4 buf.writeComponent(this.playerPrefix); buf.writeComponent(this.playerSuffix); diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java -index 4ed4744c887ca52fa3f85ad4ea41e79543cc13ce..275e7503ec6a0ceec9839c7d11fb3710cf9f15d2 100644 +index 597b8d4c79714484e7c8be6e4f90294a96259e4e..5ef6d6cafbd39cf15189bc65cc4dea1f99ef37a0 100644 --- a/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java -@@ -160,6 +160,7 @@ import net.minecraft.world.level.storage.loot.LootTables; +@@ -161,6 +161,7 @@ import net.minecraft.world.level.storage.loot.LootTables; import net.minecraft.world.level.storage.loot.PredicateManager; import net.minecraft.world.phys.Vec2; import net.minecraft.world.phys.Vec3; @@ -43,7 +43,7 @@ index 4ed4744c887ca52fa3f85ad4ea41e79543cc13ce..275e7503ec6a0ceec9839c7d11fb3710 import org.apache.commons.lang3.Validate; import org.apache.logging.log4j.LogManager; import org.apache.logging.log4j.Logger; -@@ -599,6 +600,20 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop implements SnooperPopulator, CommandSource, AutoCloseable { @@ -17,7 +17,7 @@ index 275e7503ec6a0ceec9839c7d11fb3710cf9f15d2..4d5f3509d7be914658014d07c72ec127 public static final Logger LOGGER = LogManager.getLogger(); private static final float AVERAGE_TICK_TIME_SMOOTHING = 0.8F; private static final int TICK_STATS_SPAN = 100; -@@ -314,6 +315,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop { -@@ -2235,7 +2237,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop, ServerLevel> levels; private PlayerList playerList; private volatile boolean running; @@ -41,7 +41,7 @@ index feab424cbfcb4c8f7ce38cdeeb42dce3fe1ce7aa..14d94990ca8160b0a28b40ae6b8261f5 private boolean stopped; private int tickCount; protected final Proxy proxy; -@@ -925,7 +926,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop processQueue = new java.util.concurrent.ConcurrentLinkedQueue(); public int autosavePeriod; -@@ -361,7 +362,9 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop extends CraftBlockStat - this.tileEntity = tileEntityClass.cast(world.getHandle().getBlockEntity(this.getPosition())); +@@ -25,20 +25,40 @@ public class CraftBlockEntityState extends CraftBlockStat + this.tileEntity = tileEntityClass.cast(getWorldHandle().getBlockEntity(this.getPosition())); Preconditions.checkState(this.tileEntity != null, "Tile is null, asynchronous access? %s", block); + // Paper start @@ -133,7 +133,7 @@ index fd5b5287d67af364f149d4e284001fd319986bd5..972d4aa11a0a119e8e6703af99d93bcd + // Paper end } - private T createSnapshot(T tileEntity) { + public void refreshSnapshot() { diff --git a/src/main/java/org/bukkit/craftbukkit/persistence/CraftPersistentDataContainer.java b/src/main/java/org/bukkit/craftbukkit/persistence/CraftPersistentDataContainer.java index ddd7b63f0452042baa3fca04bb9fbdb42fcecbfd..b638351581fa09c488425a2318b782a5812140ce 100644 --- a/src/main/java/org/bukkit/craftbukkit/persistence/CraftPersistentDataContainer.java diff --git a/patches/server/0169-AsyncTabCompleteEvent.patch b/patches/server/0169-AsyncTabCompleteEvent.patch index 67e9e43bb5..93abcf6b38 100644 --- a/patches/server/0169-AsyncTabCompleteEvent.patch +++ b/patches/server/0169-AsyncTabCompleteEvent.patch @@ -72,10 +72,10 @@ index cf42d59254f2786bfe8785249ad270d35996417a..8c2242d7e443bee26741608c65d314d8 @Override diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 472c466c8257bcd696184ac71019acd491eca714..f3461229c19ad011e33b2d0e2675622e1f339bcb 100644 +index eb46de0cff9dbedf19a3826ca2a876f22284f210..ad2b2e17125408712a247457db167ef6bf3e354e 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -1933,7 +1933,7 @@ public final class CraftServer implements Server { +@@ -1992,7 +1992,7 @@ public final class CraftServer implements Server { offers = this.tabCompleteChat(player, message); } diff --git a/patches/server/0183-Implement-extended-PaperServerListPingEvent.patch b/patches/server/0183-Implement-extended-PaperServerListPingEvent.patch index 702afaf246..e106b17676 100644 --- a/patches/server/0183-Implement-extended-PaperServerListPingEvent.patch +++ b/patches/server/0183-Implement-extended-PaperServerListPingEvent.patch @@ -190,7 +190,7 @@ index 67455a5ba75c9b816213e44d6872c5ddf8e27e98..23efad80934930beadf15e65781551d4 public ClientboundStatusResponsePacket(ServerStatus metadata) { diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java -index 34e801e225173246ba6f4c2ab68ef3f5f2278d78..2bbed2eb8f992764deac2cd5e08471aa0f967606 100644 +index d7ec805b7922b19e4d67288bb4eb4fc10af5166f..cc90827ca284c058f6f209cf7c9cc6ca8b8be29d 100644 --- a/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java @@ -2,6 +2,9 @@ package net.minecraft.server; @@ -203,7 +203,7 @@ index 34e801e225173246ba6f4c2ab68ef3f5f2278d78..2bbed2eb8f992764deac2cd5e08471aa import com.google.common.collect.Lists; import com.google.common.collect.Maps; import com.google.common.collect.Sets; -@@ -1313,7 +1316,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop= 5000000000L) { this.lastServerStatus = i; this.status.setPlayers(new ServerStatus.Players(this.getMaxPlayers(), this.getPlayerCount())); @@ -236,7 +236,7 @@ index 9baa56d6da9c24706f1dbc8851fd68ca752cab26..d65191a50349ec86fe35df4ac1070f94 // CraftBukkit end } diff --git a/src/main/java/org/spigotmc/SpigotConfig.java b/src/main/java/org/spigotmc/SpigotConfig.java -index e7586c325290ceb8669f9f9d430c73080a37dd05..314fa148fe783a0558ba00b068e0bf69a91577e1 100644 +index d73dfe72a54b621c0f944c90904df3e3bc709445..8e7630de11637a75a4a54a22283cbb2d0c7e6438 100644 --- a/src/main/java/org/spigotmc/SpigotConfig.java +++ b/src/main/java/org/spigotmc/SpigotConfig.java @@ -289,7 +289,7 @@ public class SpigotConfig diff --git a/patches/server/0187-getPlayerUniqueId-API.patch b/patches/server/0187-getPlayerUniqueId-API.patch index aa83d2efdc..4f478fb3d1 100644 --- a/patches/server/0187-getPlayerUniqueId-API.patch +++ b/patches/server/0187-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 f3461229c19ad011e33b2d0e2675622e1f339bcb..ac431c5b9a05a9aa65351092534298141f506fb8 100644 +index ad2b2e17125408712a247457db167ef6bf3e354e..063c6f78c6813d5f49ea6f15e23cfb7aa4adbc2f 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -1591,6 +1591,25 @@ public final class CraftServer implements Server { +@@ -1650,6 +1650,25 @@ public final class CraftServer implements Server { return recipients.size(); } diff --git a/patches/server/0198-Expand-World.spawnParticle-API-and-add-Builder.patch b/patches/server/0198-Expand-World.spawnParticle-API-and-add-Builder.patch index 46848cdde9..f7cdfaadfc 100644 --- a/patches/server/0198-Expand-World.spawnParticle-API-and-add-Builder.patch +++ b/patches/server/0198-Expand-World.spawnParticle-API-and-add-Builder.patch @@ -10,7 +10,7 @@ Adds an option to control the force mode of the particle. This adds a new Builder API which is much friendlier to use. diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java -index 160da347ed52739e930044fe456a4dd36e561a43..d06fa20dd605e9ce0e41a4d69ffeec98bceb3a63 100644 +index 2aecd5ce8e5db8c0fc54bc0c86759baaaa4bd615..22c6d606256708ff9142569e745e58b608da62a6 100644 --- a/src/main/java/net/minecraft/server/level/ServerLevel.java +++ b/src/main/java/net/minecraft/server/level/ServerLevel.java @@ -1242,12 +1242,17 @@ public class ServerLevel extends Level implements WorldGenLevel { @@ -34,10 +34,10 @@ index 160da347ed52739e930044fe456a4dd36e561a43..d06fa20dd605e9ce0e41a4d69ffeec98 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 1e96978cb4abf92eadd570bcda6a04ac76793e30..39412e473be4d138d789cabe27f4b64b00f23a97 100644 +index f5cc3134edfc56885b53fa2efbbff1ab24955f0f..d6a9f43b72d8b135734a17946cb0482c9dffbaec 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -@@ -2404,11 +2404,17 @@ public class CraftWorld implements World { +@@ -1721,11 +1721,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/0203-Allow-spawning-Item-entities-with-World.spawnEntity.patch b/patches/server/0203-Allow-spawning-Item-entities-with-World.spawnEntity.patch index ba26252d65..af33f6278e 100644 --- a/patches/server/0203-Allow-spawning-Item-entities-with-World.spawnEntity.patch +++ b/patches/server/0203-Allow-spawning-Item-entities-with-World.spawnEntity.patch @@ -7,18 +7,18 @@ 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/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -index 18e4c893f86cdaf816e5d88416fe3fe7be953bc5..1aab57f7eabc1acce9827017fde7daf382b46dce 100644 ---- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -+++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -@@ -1508,6 +1508,10 @@ public class CraftWorld implements World { +diff --git a/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java b/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java +index eca9a9eb3d8dcd51ee9e96f2f4050bf51bc58b48..aea3fafb093814bfb1e010aa70d138eecc07af93 100644 +--- a/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java ++++ b/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java +@@ -525,6 +525,10 @@ public abstract class CraftRegionAccessor implements RegionAccessor { if (Boat.class.isAssignableFrom(clazz)) { - entity = new net.minecraft.world.entity.vehicle.Boat(this.world, x, y, z); + entity = new net.minecraft.world.entity.vehicle.Boat(world, x, y, z); entity.moveTo(x, y, z, yaw, pitch); + // Paper start + } else if (org.bukkit.entity.Item.class.isAssignableFrom(clazz)) { -+ entity = new ItemEntity(world, x, y, z, new net.minecraft.world.item.ItemStack(net.minecraft.world.item.Item.byBlock(net.minecraft.world.level.block.Blocks.DIRT))); ++ entity = new net.minecraft.world.entity.item.ItemEntity(world, x, y, z, new net.minecraft.world.item.ItemStack(net.minecraft.world.item.Item.byBlock(net.minecraft.world.level.block.Blocks.DIRT))); + // Paper end } else if (FallingBlock.class.isAssignableFrom(clazz)) { - entity = new FallingBlockEntity(this.world, x, y, z, this.world.getBlockState(new BlockPos(x, y, z))); + entity = new FallingBlockEntity(world, x, y, z, this.getHandle().getBlockState(new BlockPos(x, y, z))); } else if (Projectile.class.isAssignableFrom(clazz)) { diff --git a/patches/server/0205-ItemStack-getMaxItemUseDuration.patch b/patches/server/0205-ItemStack-getMaxItemUseDuration.patch index 22d1c60bc7..87e1f660fd 100644 --- a/patches/server/0205-ItemStack-getMaxItemUseDuration.patch +++ b/patches/server/0205-ItemStack-getMaxItemUseDuration.patch @@ -6,10 +6,10 @@ Subject: [PATCH] ItemStack#getMaxItemUseDuration Allows you to determine how long it takes to use a usable/consumable item diff --git a/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemStack.java b/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemStack.java -index 379612cb78d275fa61125390c7429fcb2920ab33..efdcccac85626835ff29ed00976978d5bb900356 100644 +index 84f11780a22b3369519fc8f80d6c274360045df7..4b43e6a1b628e2060d1095dab892efd9d1dfc485 100644 --- a/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemStack.java +++ b/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemStack.java -@@ -172,6 +172,13 @@ public final class CraftItemStack extends ItemStack { +@@ -173,6 +173,13 @@ public final class CraftItemStack extends ItemStack { return (this.handle == null) ? Material.AIR.getMaxStackSize() : this.handle.getItem().getMaxStackSize(); } diff --git a/patches/server/0208-Fix-CraftEntity-hashCode.patch b/patches/server/0208-Fix-CraftEntity-hashCode.patch index e088d63394..97aa276942 100644 --- a/patches/server/0208-Fix-CraftEntity-hashCode.patch +++ b/patches/server/0208-Fix-CraftEntity-hashCode.patch @@ -21,10 +21,10 @@ check is essentially the same as this.getHandle() == other.getHandle() However, replaced it too to make it clearer of intent. diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java -index 2840228aa6aa8f1559b976d396aa9d1f8f4d6a40..84316ea7f1ad285009f02cdf6e501c577958a170 100644 +index edf381a0fd8a568fb2095a0369c3eb062e9a566b..8b776445716e483e040be165c18118593a63d694 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java -@@ -786,14 +786,15 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity { +@@ -791,14 +791,15 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity { return false; } final CraftEntity other = (CraftEntity) obj; diff --git a/patches/server/0211-Make-shield-blocking-delay-configurable.patch b/patches/server/0211-Make-shield-blocking-delay-configurable.patch index 95b26dc6d1..91ce60adf8 100644 --- a/patches/server/0211-Make-shield-blocking-delay-configurable.patch +++ b/patches/server/0211-Make-shield-blocking-delay-configurable.patch @@ -19,7 +19,7 @@ index a0a846a2e60bdc17537bd697137f65321c1a61d8..e1110274a9f6b8f7007537732ec8eff7 + } } diff --git a/src/main/java/net/minecraft/world/entity/LivingEntity.java b/src/main/java/net/minecraft/world/entity/LivingEntity.java -index 571ca7409cdce36ce228c7f3ebf2bce7a87897df..0a954a83e29f2ffc622675f671416bdadc1d3f6a 100644 +index 2c68fb49040dcb1b6acead188fa9094180577aa7..3be95347badafc35990f5fbb1c0be77b8702bc64 100644 --- a/src/main/java/net/minecraft/world/entity/LivingEntity.java +++ b/src/main/java/net/minecraft/world/entity/LivingEntity.java @@ -3668,12 +3668,24 @@ public abstract class LivingEntity extends Entity { @@ -49,10 +49,10 @@ index 571ca7409cdce36ce228c7f3ebf2bce7a87897df..0a954a83e29f2ffc622675f671416bda return this.isShiftKeyDown(); } diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java -index 7beb84da34e58b18cd83a53eab2bcf703e8bf35e..d9f06a7ff7c6b4c60ddbc5d7131916fabd0fc4d2 100644 +index 90b70935242757b5c302bac7777eb1428d69619e..1ffdc8785d1073511e58d4826457efa9d71c357d 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java -@@ -712,5 +712,15 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity { +@@ -735,5 +735,15 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity { public void setArrowsStuck(int arrows) { getHandle().setArrowCount(arrows); } diff --git a/patches/server/0215-Expand-Explosions-API.patch b/patches/server/0215-Expand-Explosions-API.patch index a9d8a34274..4b317fb29b 100644 --- a/patches/server/0215-Expand-Explosions-API.patch +++ b/patches/server/0215-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 1aab57f7eabc1acce9827017fde7daf382b46dce..9b9dc5b8e5c2ce6ab4876067374e24d6cbf2fa12 100644 +index d6a9f43b72d8b135734a17946cb0482c9dffbaec..1200a6ddf67643250bb3386190bb2f6538abe52e 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -@@ -892,6 +892,12 @@ public class CraftWorld implements World { +@@ -686,6 +686,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 ? Explosion.BlockInteraction.BREAK : Explosion.BlockInteraction.NONE).wasCanceled; } diff --git a/patches/server/0216-LivingEntity-Hand-Raised-Item-Use-API.patch b/patches/server/0216-LivingEntity-Hand-Raised-Item-Use-API.patch index bbfe9bd0fb..f663585050 100644 --- a/patches/server/0216-LivingEntity-Hand-Raised-Item-Use-API.patch +++ b/patches/server/0216-LivingEntity-Hand-Raised-Item-Use-API.patch @@ -6,10 +6,10 @@ Subject: [PATCH] LivingEntity Hand Raised/Item Use API How long an entity has raised hands to charge an attack or use an item diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java -index d9f06a7ff7c6b4c60ddbc5d7131916fabd0fc4d2..0aec2e79d053b6cb845ffea393ad431b3d254b83 100644 +index 1ffdc8785d1073511e58d4826457efa9d71c357d..918f87cc79062602e1db41d9368921c0092b1840 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java -@@ -722,5 +722,30 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity { +@@ -745,5 +745,30 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity { public void setShieldBlockingDelay(int delay) { getHandle().setShieldBlockingDelay(delay); } diff --git a/patches/server/0219-Implement-World.getEntity-UUID-API.patch b/patches/server/0219-Implement-World.getEntity-UUID-API.patch index adf400d574..0d9216058a 100644 --- a/patches/server/0219-Implement-World.getEntity-UUID-API.patch +++ b/patches/server/0219-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 9b9dc5b8e5c2ce6ab4876067374e24d6cbf2fa12..dac119e71c53f246944b3d2072f1fa7d6c8fa828 100644 +index 1200a6ddf67643250bb3386190bb2f6538abe52e..a049c5b10db3ebc3f5a27b3510d09075d2bccf2a 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -@@ -1298,6 +1298,15 @@ public class CraftWorld implements World { +@@ -1020,6 +1020,15 @@ public class CraftWorld extends CraftRegionAccessor implements World { return list; } diff --git a/patches/server/0225-add-more-information-to-Entity.toString.patch b/patches/server/0225-add-more-information-to-Entity.toString.patch index 039904c610..ef9bca954c 100644 --- a/patches/server/0225-add-more-information-to-Entity.toString.patch +++ b/patches/server/0225-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 ea9f165a958c507ef57523e7cfbccbea77aef6d9..7ce7660bcd6cdc23d6d06c9009a96a08e637ccbd 100644 +index 06ee6000f53da50e7883a68208bdb5f839632f94..1d9b91e6c7180e4a7db03a01c7ec5f799f5ab983 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -2809,7 +2809,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n +@@ -2810,7 +2810,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n } public String toString() { diff --git a/patches/server/0236-Don-t-call-getItemMeta-on-hasItemMeta.patch b/patches/server/0236-Don-t-call-getItemMeta-on-hasItemMeta.patch index d8ae36bf3d..0366b007bf 100644 --- a/patches/server/0236-Don-t-call-getItemMeta-on-hasItemMeta.patch +++ b/patches/server/0236-Don-t-call-getItemMeta-on-hasItemMeta.patch @@ -11,10 +11,10 @@ Returns true if getDamage() == 0 or has damage tag or other tag is set. Check the `ItemMetaTest#testTaggedButNotMeta` method to see how this method behaves. diff --git a/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemStack.java b/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemStack.java -index 3cf23bc0a28ac5f4ac7b51f427f17365eaff8cc1..f02bbc2e927ea2d8e861597da4dbe4d199e48799 100644 +index 4b43e6a1b628e2060d1095dab892efd9d1dfc485..e9fa60755da0bc358020266ff4e450e1b31da595 100644 --- a/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemStack.java +++ b/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemStack.java -@@ -575,7 +575,7 @@ public final class CraftItemStack extends ItemStack { +@@ -576,7 +576,7 @@ public final class CraftItemStack extends ItemStack { @Override public boolean hasItemMeta() { diff --git a/patches/server/0239-Add-hand-to-bucket-events.patch b/patches/server/0239-Add-hand-to-bucket-events.patch index 65b7f3d97f..e33bef787f 100644 --- a/patches/server/0239-Add-hand-to-bucket-events.patch +++ b/patches/server/0239-Add-hand-to-bucket-events.patch @@ -5,7 +5,7 @@ Subject: [PATCH] Add hand to bucket events diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java -index 19f8e74f292e83f7438683efddbaa4930f1a7c48..4e0e5d3e0b91d4b7be4eaa6fe252287d90bc010e 100644 +index c4bb49f8007169f62deeef19ccce2b907d961374..68e0d76aed7e993c35ac2e73dda6ed251a817d39 100644 --- a/src/main/java/net/minecraft/server/level/ServerLevel.java +++ b/src/main/java/net/minecraft/server/level/ServerLevel.java @@ -1374,15 +1374,17 @@ public class ServerLevel extends Level implements WorldGenLevel { @@ -62,19 +62,19 @@ index 454e07a47d35b8dc8e5f1fb38da74669b4f7cdc7..15787afad42f9299638a1c9e57d26678 if (event.isCancelled()) { return InteractionResult.PASS; diff --git a/src/main/java/net/minecraft/world/item/BucketItem.java b/src/main/java/net/minecraft/world/item/BucketItem.java -index 24272b384b96bb98a8231fe8583f404ad0c96de5..7c3e94c6bf8337ef660473d8ed451606d56082a5 100644 +index 5870023250ed2dba16b2fa5c6a8be6f36cebc640..650b59b69eb12112bc71e5ff164767e3118e1c2a 100644 --- a/src/main/java/net/minecraft/world/item/BucketItem.java +++ b/src/main/java/net/minecraft/world/item/BucketItem.java -@@ -71,7 +71,7 @@ public class BucketItem extends Item implements DispensibleContainerItem { - BucketPickup ifluidsource = (BucketPickup) iblockdata.getBlock(); +@@ -72,7 +72,7 @@ public class BucketItem extends Item implements DispensibleContainerItem { // CraftBukkit start ItemStack dummyFluid = ifluidsource.pickupBlock(DummyGeneratorAccess.INSTANCE, blockposition, iblockdata); + if (dummyFluid.isEmpty()) return InteractionResultHolder.fail(itemstack); // Don't fire event if the bucket won't be filled. - PlayerBucketFillEvent event = CraftEventFactory.callPlayerBucketFillEvent((ServerLevel) world, user, blockposition, blockposition, movingobjectpositionblock.getDirection(), itemstack, dummyFluid.getItem()); + PlayerBucketFillEvent event = CraftEventFactory.callPlayerBucketFillEvent((ServerLevel) world, user, blockposition, blockposition, movingobjectpositionblock.getDirection(), itemstack, dummyFluid.getItem(), hand); // Paper - add enumhand if (event.isCancelled()) { ((ServerPlayer) user).connection.send(new ClientboundBlockUpdatePacket(world, blockposition)); // SPIGOT-5163 (see PlayerInteractManager) -@@ -102,7 +102,7 @@ public class BucketItem extends Item implements DispensibleContainerItem { +@@ -103,7 +103,7 @@ public class BucketItem extends Item implements DispensibleContainerItem { iblockdata = world.getBlockState(blockposition); BlockPos blockposition2 = iblockdata.getBlock() instanceof LiquidBlockContainer && this.content == Fluids.WATER ? blockposition : blockposition1; @@ -83,7 +83,7 @@ index 24272b384b96bb98a8231fe8583f404ad0c96de5..7c3e94c6bf8337ef660473d8ed451606 this.checkExtraContent(user, world, itemstack, blockposition2); if (user instanceof ServerPlayer) { CriteriaTriggers.PLACED_BLOCK.trigger((ServerPlayer) user, blockposition2, itemstack); -@@ -129,10 +129,12 @@ public class BucketItem extends Item implements DispensibleContainerItem { +@@ -130,10 +130,12 @@ public class BucketItem extends Item implements DispensibleContainerItem { @Override public boolean emptyContents(@Nullable Player player, Level world, BlockPos pos, @Nullable BlockHitResult hitResult) { @@ -98,7 +98,7 @@ index 24272b384b96bb98a8231fe8583f404ad0c96de5..7c3e94c6bf8337ef660473d8ed451606 // CraftBukkit end if (!(this.content instanceof FlowingFluid)) { return false; -@@ -145,7 +147,7 @@ public class BucketItem extends Item implements DispensibleContainerItem { +@@ -146,7 +148,7 @@ public class BucketItem extends Item implements DispensibleContainerItem { // CraftBukkit start if (flag1 && entityhuman != null) { @@ -107,7 +107,7 @@ index 24272b384b96bb98a8231fe8583f404ad0c96de5..7c3e94c6bf8337ef660473d8ed451606 if (event.isCancelled()) { ((ServerPlayer) entityhuman).connection.send(new ClientboundBlockUpdatePacket(world, blockposition)); // SPIGOT-4238: needed when looking through entity ((ServerPlayer) entityhuman).getBukkitEntity().updateInventory(); // SPIGOT-4541 -@@ -154,7 +156,7 @@ public class BucketItem extends Item implements DispensibleContainerItem { +@@ -155,7 +157,7 @@ public class BucketItem extends Item implements DispensibleContainerItem { } // CraftBukkit end if (!flag1) { @@ -117,7 +117,7 @@ index 24272b384b96bb98a8231fe8583f404ad0c96de5..7c3e94c6bf8337ef660473d8ed451606 int i = blockposition.getX(); int j = blockposition.getY(); diff --git a/src/main/java/net/minecraft/world/level/Level.java b/src/main/java/net/minecraft/world/level/Level.java -index 1fef077a6d5efc8bdc171b5c6e2a49129f8589ce..ac46dac8be79953720fab6485caf677f2c3ad87b 100644 +index 17f596e6059334114ce3ee17fbde1ce3d14c5ca1..96c685ffbf6058b69f0c573a1255a9e8596365bf 100644 --- a/src/main/java/net/minecraft/world/level/Level.java +++ b/src/main/java/net/minecraft/world/level/Level.java @@ -292,6 +292,17 @@ public abstract class Level implements LevelAccessor, AutoCloseable { @@ -139,7 +139,7 @@ index 1fef077a6d5efc8bdc171b5c6e2a49129f8589ce..ac46dac8be79953720fab6485caf677f 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 ce01df5dbb4913b9620a1bab3c0a251defb99f75..0ddd9de39a0d67529a8f973f5dfaf5ff53f5eb66 100644 +index b7fbbe39bc36f5315abe658b00704836a40d34ca..732a6f247e25e245909829d9fa784fced1d3cca2 100644 --- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java +++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java @@ -222,7 +222,7 @@ public class CraftEventFactory { diff --git a/patches/server/0245-Add-Early-Warning-Feature-to-WatchDog.patch b/patches/server/0245-Add-Early-Warning-Feature-to-WatchDog.patch index d21dceabc6..c973f0f614 100644 --- a/patches/server/0245-Add-Early-Warning-Feature-to-WatchDog.patch +++ b/patches/server/0245-Add-Early-Warning-Feature-to-WatchDog.patch @@ -36,10 +36,10 @@ index 7e4ac2699eca8aebba675f3ffdac3a4dad422e4c..96366bfb03e1bc57a10154c13341a80c public static int tabSpamLimit = 500; private static void tabSpamLimiters() { diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java -index 2bbed2eb8f992764deac2cd5e08471aa0f967606..d0d524bfe7ae90f6d2edefa4063bf009cddee17b 100644 +index cc90827ca284c058f6f209cf7c9cc6ca8b8be29d..f043bc485e2813706bce53f10775d295bb2dd5e7 100644 --- a/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java -@@ -1084,6 +1084,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop WorldDataServer - public ServerLevel(MinecraftServer minecraftserver, Executor executor, LevelStorageSource.LevelStorageAccess convertable_conversionsession, ServerLevelData iworlddataserver, ResourceKey resourcekey, DimensionType dimensionmanager, ChunkProgressListener worldloadlistener, ChunkGenerator chunkgenerator, boolean flag, long i, List list, boolean flag1, org.bukkit.World.Environment env, org.bukkit.generator.ChunkGenerator gen) { + public ServerLevel(MinecraftServer minecraftserver, Executor executor, LevelStorageSource.LevelStorageAccess convertable_conversionsession, ServerLevelData iworlddataserver, ResourceKey resourcekey, DimensionType dimensionmanager, ChunkProgressListener worldloadlistener, ChunkGenerator chunkgenerator, boolean flag, long i, List list, boolean flag1, org.bukkit.World.Environment env, org.bukkit.generator.ChunkGenerator gen, org.bukkit.generator.BiomeProvider biomeProvider) { // Objects.requireNonNull(minecraftserver); // CraftBukkit - decompile error @@ -277,6 +350,8 @@ public class ServerLevel extends Level implements WorldGenLevel { @@ -3619,10 +3619,10 @@ index e5e138fb23d03eb63e547e74d3e14ec9d96d8107..90f7b06bd2c558be35c4577044fa033e + // Paper end } diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -index 9128b6db3f28f168864345ca354707e37a77faaa..8a244988f984e7cb9df7308b21aec1524fbef3f1 100644 +index d99d019df02f8defb6c5c9082b8c650231c20775..5d0e56a2c8fb6f801643928f8b75e06cdff83a52 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -@@ -2471,6 +2471,34 @@ public class CraftWorld implements World { +@@ -1784,6 +1784,34 @@ public class CraftWorld extends CraftRegionAccessor implements World { public DragonBattle getEnderDragonBattle() { return (this.getHandle().dragonFight() == null) ? null : new CraftDragonBattle(this.getHandle().dragonFight()); } @@ -3658,7 +3658,7 @@ index 9128b6db3f28f168864345ca354707e37a77faaa..8a244988f984e7cb9df7308b21aec152 // Spigot start @Override diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java -index 50e2cbade05dd299ef60bea4f835f9bf6df88f44..7e0986e085895ad046685771acb9e4374c5cfe89 100644 +index 8b776445716e483e040be165c18118593a63d694..3980197b7e876ffea27c183121a8e58409ecc4a7 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java @@ -15,6 +15,7 @@ import net.minecraft.network.chat.Component; diff --git a/patches/server/0261-Add-ray-tracing-methods-to-LivingEntity.patch b/patches/server/0261-Add-ray-tracing-methods-to-LivingEntity.patch index 885e211efd..17d3b5836d 100644 --- a/patches/server/0261-Add-ray-tracing-methods-to-LivingEntity.patch +++ b/patches/server/0261-Add-ray-tracing-methods-to-LivingEntity.patch @@ -28,7 +28,7 @@ index 49fd3486a6c595749f33bbe1c1bec0454e4725c5..5c290f263fc2b643987c96ea75729bf1 switch (enumDirection) { case DOWN: diff --git a/src/main/java/net/minecraft/world/entity/LivingEntity.java b/src/main/java/net/minecraft/world/entity/LivingEntity.java -index 91a0699ba30fa1e9c8172e07f034ea1fabee9d11..616d6404a966153f89ae63b559b5b66cbb832104 100644 +index bfec0ae49c74ec5f6762140199cbfaf9e87a047c..4bc467f5c0fd261a01fd4ecc49015b6e7d6b6ef9 100644 --- a/src/main/java/net/minecraft/world/entity/LivingEntity.java +++ b/src/main/java/net/minecraft/world/entity/LivingEntity.java @@ -3689,6 +3689,23 @@ public abstract class LivingEntity extends Entity { @@ -56,10 +56,10 @@ index 91a0699ba30fa1e9c8172e07f034ea1fabee9d11..616d6404a966153f89ae63b559b5b66c public int getShieldBlockingDelay() { diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java -index 0391f0d240b8846806b60adfb1e3589ac4cbe893..856860c502a3bf91faf9d075326c9ea39db44d9e 100644 +index 918f87cc79062602e1db41d9368921c0092b1840..873b70c36d145a14632102c9e92d501745064fa4 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java -@@ -190,6 +190,28 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity { +@@ -198,6 +198,28 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity { return blocks.get(0); } diff --git a/patches/server/0265-Mob-Pathfinding-API.patch b/patches/server/0265-Mob-Pathfinding-API.patch index 45626c1dcf..ebe42603c8 100644 --- a/patches/server/0265-Mob-Pathfinding-API.patch +++ b/patches/server/0265-Mob-Pathfinding-API.patch @@ -163,10 +163,10 @@ index 31d4431a60e742e2ca3b1a2abcce33954f599488..f4b6c2bf74884c0b53956788dcfcca78 public Path(List nodes, BlockPos target, boolean reachesTarget) { this.nodes = nodes; diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftMob.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftMob.java -index 71872fdfafca82cf745eecee4bf984726d49f5a4..9c9fa83615cd06539ce5e4e3d4feaa69f65b7931 100644 +index ee84ae1baf959a496a4228edab89b9c0079bc615..140672d03dd2563d2b1fb905d79164ff53cf0b76 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftMob.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftMob.java -@@ -11,8 +11,11 @@ import org.bukkit.loot.LootTable; +@@ -12,8 +12,11 @@ import org.bukkit.loot.LootTable; public abstract class CraftMob extends CraftLivingEntity implements Mob { public CraftMob(CraftServer server, net.minecraft.world.entity.Mob entity) { super(server, entity); @@ -177,4 +177,4 @@ index 71872fdfafca82cf745eecee4bf984726d49f5a4..9c9fa83615cd06539ce5e4e3d4feaa69 + @Override public com.destroystokyo.paper.entity.Pathfinder getPathfinder() { return paperPathfinder; } // Paper @Override public void setTarget(LivingEntity target) { - net.minecraft.world.entity.Mob entity = this.getHandle(); + Preconditions.checkState(!this.getHandle().generation, "Cannot set target during world generation"); diff --git a/patches/server/0275-Add-sun-related-API.patch b/patches/server/0275-Add-sun-related-API.patch index 99d1f75970..dada21da53 100644 --- a/patches/server/0275-Add-sun-related-API.patch +++ b/patches/server/0275-Add-sun-related-API.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Add sun related API diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -index 03a7e5d61d8888e1e836bd5a69ee9443b723f72c..01e63133d769e3d5c33944907a04ce4def8bbb45 100644 +index 5d0e56a2c8fb6f801643928f8b75e06cdff83a52..4edfe886ae753f1c9e90be2bff69483c330287ae 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -@@ -868,6 +868,13 @@ public class CraftWorld implements World { +@@ -662,6 +662,13 @@ public class CraftWorld extends CraftRegionAccessor implements World { } } @@ -23,10 +23,10 @@ index 03a7e5d61d8888e1e836bd5a69ee9443b723f72c..01e63133d769e3d5c33944907a04ce4d public long getGameTime() { return world.levelData.getGameTime(); diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftMob.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftMob.java -index 9c9fa83615cd06539ce5e4e3d4feaa69f65b7931..317b6abd2764cf34ef5c42bdbf48ab0bc5a03d27 100644 +index 140672d03dd2563d2b1fb905d79164ff53cf0b76..e0022ea4bf228eef8384f20cfc717076c5ca5c99 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftMob.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftMob.java -@@ -77,4 +77,11 @@ public abstract class CraftMob extends CraftLivingEntity implements Mob { +@@ -80,4 +80,11 @@ public abstract class CraftMob extends CraftLivingEntity implements Mob { public long getSeed() { return this.getHandle().lootTableSeed; } diff --git a/patches/server/0276-Add-LivingEntity-getTargetEntity.patch b/patches/server/0276-Add-LivingEntity-getTargetEntity.patch index 914f17da9f..7d60e82072 100644 --- a/patches/server/0276-Add-LivingEntity-getTargetEntity.patch +++ b/patches/server/0276-Add-LivingEntity-getTargetEntity.patch @@ -5,7 +5,7 @@ Subject: [PATCH] Add LivingEntity#getTargetEntity diff --git a/src/main/java/net/minecraft/world/entity/LivingEntity.java b/src/main/java/net/minecraft/world/entity/LivingEntity.java -index 676d24a1c57b5d3d14c3599d09196da128b6e19e..ef3b47c30e9fa0a41268b61d3008507587999aa6 100644 +index 82d6d56d6e1bc6f98811a4a9b2a9d80a62c61292..1c97ba35c9588b98d66e82ca83e4c48615b9e01b 100644 --- a/src/main/java/net/minecraft/world/entity/LivingEntity.java +++ b/src/main/java/net/minecraft/world/entity/LivingEntity.java @@ -116,6 +116,7 @@ import net.minecraft.world.level.storage.loot.LootTable; @@ -56,7 +56,7 @@ index 676d24a1c57b5d3d14c3599d09196da128b6e19e..ef3b47c30e9fa0a41268b61d30085075 public int getShieldBlockingDelay() { diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java -index 856860c502a3bf91faf9d075326c9ea39db44d9e..e9795e569b5aa8aa639d6a4e0b6789f9681cd73d 100644 +index 873b70c36d145a14632102c9e92d501745064fa4..c396ad36084e46c4b812d970e07a9188aed16daf 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java @@ -1,5 +1,6 @@ @@ -66,7 +66,7 @@ index 856860c502a3bf91faf9d075326c9ea39db44d9e..e9795e569b5aa8aa639d6a4e0b6789f9 import com.google.common.base.Preconditions; import com.google.common.collect.Sets; import java.util.ArrayList; -@@ -210,6 +211,33 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity { +@@ -218,6 +219,33 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity { new com.destroystokyo.paper.block.TargetBlockInfo(org.bukkit.craftbukkit.block.CraftBlock.at(getHandle().level, ((net.minecraft.world.phys.BlockHitResult)rayTrace).getBlockPos()), net.minecraft.server.MCUtil.toBukkitBlockFace(((net.minecraft.world.phys.BlockHitResult)rayTrace).getDirection())); } diff --git a/patches/server/0280-Add-Velocity-IP-Forwarding-Support.patch b/patches/server/0280-Add-Velocity-IP-Forwarding-Support.patch index 7f2e7d7ae3..f1e0c02c97 100644 --- a/patches/server/0280-Add-Velocity-IP-Forwarding-Support.patch +++ b/patches/server/0280-Add-Velocity-IP-Forwarding-Support.patch @@ -225,10 +225,10 @@ index 39bdda56aaa5503efc15207261634127b462c3e7..3fd913f3e963cf2da849a52364356e3b } diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index f1e50f3f6d0e4876aa54b72dd474d238cd91f9b6..e388a319a311e81dcddf83d3984af35b55f0c6ab 100644 +index f18a48b83e848a166a7d99f1937493df25d3e11d..a2acf9c1969fd3d365276421d63aae6617a52dc4 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -688,7 +688,7 @@ public final class CraftServer implements Server { +@@ -694,7 +694,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/0287-Improve-Server-Thread-Pool-and-Thread-Priorities.patch b/patches/server/0287-Improve-Server-Thread-Pool-and-Thread-Priorities.patch index 3eb97aa04b..187dcb9ec2 100644 --- a/patches/server/0287-Improve-Server-Thread-Pool-and-Thread-Priorities.patch +++ b/patches/server/0287-Improve-Server-Thread-Pool-and-Thread-Priorities.patch @@ -67,10 +67,10 @@ index 65e0ca442980f273d2fe5f131e174cd92f80da20..81f4f26a6b83079d36acd1fd86dede0e return executorService; } diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java -index 7671731bee6df3766127448e0ee983970b94230e..18e272de9238c0b0cbc2182b18bfcb98f6218d17 100644 +index a727b0305b2dfb92c763ea1b31d85769868cfed2..8b81f618598a4a95e4cb19c3e65b7e6d03459530 100644 --- a/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java -@@ -314,6 +314,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop extends CraftBlockStat @@ -17,7 +17,7 @@ index 972d4aa11a0a119e8e6703af99d93bcd3cddc6d8..315690d72c5ba07b9bb6e7dd997b8f5a this.tileEntityClass = tileEntityClass; // get tile entity from block: -@@ -38,6 +40,14 @@ public class CraftBlockEntityState extends CraftBlockStat +@@ -37,6 +39,14 @@ public class CraftBlockEntityState extends CraftBlockStat this.load(this.snapshot); } // Paper end diff --git a/patches/server/0341-Do-less-work-if-we-have-a-custom-Bukkit-generator.patch b/patches/server/0341-Do-less-work-if-we-have-a-custom-Bukkit-generator.patch index e9c0d7a4e2..310c3acc10 100644 --- a/patches/server/0341-Do-less-work-if-we-have-a-custom-Bukkit-generator.patch +++ b/patches/server/0341-Do-less-work-if-we-have-a-custom-Bukkit-generator.patch @@ -7,10 +7,10 @@ If the Bukkit generator already has a spawn, use it immediately instead of spending time generating one that we won't use diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java -index 01969206a55f332126169cd1e9c89abde01309e9..a1b19ba18620931ddf471579f365bb8082e4deac 100644 +index 76795ba9ee83b9461b60fb607b419344122be57e..fad88282b3b865cfb0a9a308d9c93cd8dc53b0d4 100644 --- a/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java -@@ -674,12 +674,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop= 0; --r) { -- if (r <= random.nextInt(5)) { -+ if (r <= (chunk.generateFlatBedrock() ? 0 : random.nextInt(5))) { // Paper - Configurable flat bedrock floor - chunk.setBlockState(mutableBlockPos.set(blockPos.getX(), l + r, blockPos.getZ()), Blocks.BEDROCK.defaultBlockState(), false); + if (flag2) { + for (l1 = 4; l1 >= 0; --l1) { +- if (l1 <= random.nextInt(5)) { ++ if (l1 <= (chunk.generateFlatBedrock() ? 0 : random.nextInt(5))) { // Paper - Configurable flat bedrock floor{ + chunk.setBlockState(blockposition_mutableblockposition.set(blockposition.getX(), l + l1, blockposition.getZ()), Blocks.BEDROCK.defaultBlockState(), false); } } -@@ -309,14 +309,14 @@ public final class NoiseBasedChunkGenerator extends ChunkGenerator { - if (l <= 0) { - return CompletableFuture.completedFuture(chunk); - } else { -- int m = chunk.getSectionIndex(l * this.cellHeight - 1 + i); -+ int mStart = chunk.getSectionIndex(l * this.cellHeight - 1 + i); // Paper - decompile fix - int n = chunk.getSectionIndex(i); - return CompletableFuture.supplyAsync(() -> { - Set set = Sets.newHashSet(); - - ChunkAccess var16; - try { -- for(int m = m; m >= n; --m) { -+ for(int m = mStart; m >= n; --m) { // Paper - decompile fix - LevelChunkSection levelChunkSection = chunk.getOrCreateSection(m); - levelChunkSection.acquire(); - set.add(levelChunkSection); diff --git a/patches/server/0346-Fix-spawning-of-hanging-entities-that-are-not-ItemFr.patch b/patches/server/0346-Fix-spawning-of-hanging-entities-that-are-not-ItemFr.patch index d3b2b589d0..2aca94e8ee 100644 --- a/patches/server/0346-Fix-spawning-of-hanging-entities-that-are-not-ItemFr.patch +++ b/patches/server/0346-Fix-spawning-of-hanging-entities-that-are-not-ItemFr.patch @@ -5,11 +5,11 @@ Subject: [PATCH] Fix spawning of hanging entities that are not ItemFrames and can not face UP or DOWN -diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -index 479693f9703f743c8e64bb6b949b2803109f4fa0..2c4ffaa4e9ce7759e6782547300ec6f457530c3b 100644 ---- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -+++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -@@ -1883,7 +1883,12 @@ public class CraftWorld implements World { +diff --git a/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java b/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java +index aea3fafb093814bfb1e010aa70d138eecc07af93..def6668424af23ad3a16fa726919f7c06ec20295 100644 +--- a/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java ++++ b/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java +@@ -816,7 +816,12 @@ public abstract class CraftRegionAccessor implements RegionAccessor { height = 9; } @@ -17,9 +17,9 @@ index 479693f9703f743c8e64bb6b949b2803109f4fa0..2c4ffaa4e9ce7759e6782547300ec6f4 + // Paper start - In addition to d65a2576e40e58c8e446b330febe6799d13a604f do not check UP/DOWN for non item frames + // BlockFace[] faces = new BlockFace[]{BlockFace.EAST, BlockFace.NORTH, BlockFace.WEST, BlockFace.SOUTH, BlockFace.UP, BlockFace.DOWN}; + BlockFace[] faces = (ItemFrame.class.isAssignableFrom(clazz)) -+ ? new BlockFace[]{BlockFace.EAST, BlockFace.NORTH, BlockFace.WEST, BlockFace.SOUTH, BlockFace.UP, BlockFace.DOWN} -+ : new BlockFace[]{BlockFace.EAST, BlockFace.NORTH, BlockFace.WEST, BlockFace.SOUTH}; ++ ? new BlockFace[]{BlockFace.EAST, BlockFace.NORTH, BlockFace.WEST, BlockFace.SOUTH, BlockFace.UP, BlockFace.DOWN} ++ : new BlockFace[]{BlockFace.EAST, BlockFace.NORTH, BlockFace.WEST, BlockFace.SOUTH}; + // Paper end final BlockPos pos = new BlockPos(x, y, z); for (BlockFace dir : faces) { - net.minecraft.world.level.block.state.BlockState nmsBlock = this.world.getBlockState(pos.relative(CraftBlock.blockFaceToNotch(dir))); + net.minecraft.world.level.block.state.BlockState nmsBlock = this.getHandle().getBlockState(pos.relative(CraftBlock.blockFaceToNotch(dir))); diff --git a/patches/server/0353-Optimize-Hoppers.patch b/patches/server/0353-Optimize-Hoppers.patch index d0b023f442..8c6d3c1bff 100644 --- a/patches/server/0353-Optimize-Hoppers.patch +++ b/patches/server/0353-Optimize-Hoppers.patch @@ -32,10 +32,10 @@ index 9860f5a0ddff83f1393ee13a96b38c3b14077512..bf704993d0abd50dba91682a7fbb575e } diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java -index a1b19ba18620931ddf471579f365bb8082e4deac..677966d14c56d121bc39ba0a1fb358f6b7610c4e 100644 +index fad88282b3b865cfb0a9a308d9c93cd8dc53b0d4..cc764bb6d7460fd7fc649dd0b7ec61329866dc70 100644 --- a/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java -@@ -1424,6 +1424,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop 0; // Paper @@ -117,7 +117,7 @@ index a05acf709735b40ca86f978508c63a86065fd405..71dd26ca6626631b94d53818cd06b93f double getLevelY(); diff --git a/src/main/java/net/minecraft/world/level/block/entity/HopperBlockEntity.java b/src/main/java/net/minecraft/world/level/block/entity/HopperBlockEntity.java -index 0ec16d554c2b51a64614c73783505c7b06ff02c7..3b1442bf4c83650369e925d76f07dc67c6cbbc83 100644 +index 3e2832087e8c2c0e2c45f18b0da49299611e76ad..08c4a0996410a42418d4a5da3ed1f4db2f171dd2 100644 --- a/src/main/java/net/minecraft/world/level/block/entity/HopperBlockEntity.java +++ b/src/main/java/net/minecraft/world/level/block/entity/HopperBlockEntity.java @@ -3,7 +3,6 @@ package net.minecraft.world.level.block.entity; @@ -424,17 +424,17 @@ index 0ec16d554c2b51a64614c73783505c7b06ff02c7..3b1442bf4c83650369e925d76f07dc67 itemEntity.level.getCraftServer().getPluginManager().callEvent(event); if (event.isCancelled()) { return false; -@@ -393,7 +588,9 @@ public class HopperBlockEntity extends RandomizableContainerBlockEntity implemen - boolean flag1 = to.isEmpty(); - - if (itemstack1.isEmpty()) { +@@ -398,7 +593,9 @@ public class HopperBlockEntity extends RandomizableContainerBlockEntity implemen + stack = stack.split(to.getMaxStackSize()); + } + // Spigot end + IGNORE_TILE_UPDATES = true; // Paper to.setItem(slot, stack); + IGNORE_TILE_UPDATES = false; // Paper stack = ItemStack.EMPTY; flag = true; } else if (HopperBlockEntity.canMergeItems(itemstack1, stack)) { -@@ -444,18 +641,23 @@ public class HopperBlockEntity extends RandomizableContainerBlockEntity implemen +@@ -449,18 +646,23 @@ public class HopperBlockEntity extends RandomizableContainerBlockEntity implemen } public static List getItemsAtAndAbove(Level world, Hopper hopper) { @@ -463,7 +463,7 @@ index 0ec16d554c2b51a64614c73783505c7b06ff02c7..3b1442bf4c83650369e925d76f07dc67 Object object = null; BlockPos blockposition = new BlockPos(x, y, z); if ( !world.hasChunkAt( blockposition ) ) return null; // Spigot -@@ -475,7 +677,7 @@ public class HopperBlockEntity extends RandomizableContainerBlockEntity implemen +@@ -480,7 +682,7 @@ public class HopperBlockEntity extends RandomizableContainerBlockEntity implemen } } diff --git a/patches/server/0358-Optimise-IEntityAccess-getPlayerByUUID.patch b/patches/server/0358-Optimise-IEntityAccess-getPlayerByUUID.patch index 0128944cb8..56e1e0349d 100644 --- a/patches/server/0358-Optimise-IEntityAccess-getPlayerByUUID.patch +++ b/patches/server/0358-Optimise-IEntityAccess-getPlayerByUUID.patch @@ -6,7 +6,7 @@ Subject: [PATCH] Optimise IEntityAccess#getPlayerByUUID Use the world entity map instead of iterating over all players diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java -index 92de3821e8b510012736468b880ad18c0eb153a0..ae2606215a43a49b5e65052c407df715f260e400 100644 +index 3f96d2a8bb11727ec7e197410f20aa535f19b9d4..993617e87c71320fe51adf24bef691aa978d42e3 100644 --- a/src/main/java/net/minecraft/server/level/ServerLevel.java +++ b/src/main/java/net/minecraft/server/level/ServerLevel.java @@ -280,6 +280,14 @@ public class ServerLevel extends Level implements WorldGenLevel { @@ -22,5 +22,5 @@ index 92de3821e8b510012736468b880ad18c0eb153a0..ae2606215a43a49b5e65052c407df715 + // Paper end + // Add env and gen to constructor, WorldData -> WorldDataServer - public ServerLevel(MinecraftServer minecraftserver, Executor executor, LevelStorageSource.LevelStorageAccess convertable_conversionsession, ServerLevelData iworlddataserver, ResourceKey resourcekey, DimensionType dimensionmanager, ChunkProgressListener worldloadlistener, ChunkGenerator chunkgenerator, boolean flag, long i, List list, boolean flag1, org.bukkit.World.Environment env, org.bukkit.generator.ChunkGenerator gen) { + public ServerLevel(MinecraftServer minecraftserver, Executor executor, LevelStorageSource.LevelStorageAccess convertable_conversionsession, ServerLevelData iworlddataserver, ResourceKey resourcekey, DimensionType dimensionmanager, ChunkProgressListener worldloadlistener, ChunkGenerator chunkgenerator, boolean flag, long i, List list, boolean flag1, org.bukkit.World.Environment env, org.bukkit.generator.ChunkGenerator gen, org.bukkit.generator.BiomeProvider biomeProvider) { // Objects.requireNonNull(minecraftserver); // CraftBukkit - decompile error diff --git a/patches/server/0363-Add-effect-to-block-break-naturally.patch b/patches/server/0363-Add-effect-to-block-break-naturally.patch index 1c0c9e907b..6bdcc42710 100644 --- a/patches/server/0363-Add-effect-to-block-break-naturally.patch +++ b/patches/server/0363-Add-effect-to-block-break-naturally.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Add effect to block break naturally diff --git a/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java b/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java -index 29c5f752ec2df0be757a58392d9e33b72dc1a2ec..d33c56ac47884ebcce98494377af26cc77f8d5f6 100644 +index bfacffcb39d0c4e6992df282b5b28bd7ca8d5398..f92e8a53e327779d4e30a5f6806825a2a21b547a 100644 --- a/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java +++ b/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java -@@ -630,6 +630,13 @@ public class CraftBlock implements Block { +@@ -634,6 +634,13 @@ public class CraftBlock implements Block { @Override public boolean breakNaturally(ItemStack item) { @@ -22,7 +22,7 @@ index 29c5f752ec2df0be757a58392d9e33b72dc1a2ec..d33c56ac47884ebcce98494377af26cc // 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(); -@@ -639,6 +646,7 @@ public class CraftBlock implements Block { +@@ -643,6 +650,7 @@ 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/0364-Entity-Activation-Range-2.0.patch b/patches/server/0364-Entity-Activation-Range-2.0.patch index 837e006813..3c2191da82 100644 --- a/patches/server/0364-Entity-Activation-Range-2.0.patch +++ b/patches/server/0364-Entity-Activation-Range-2.0.patch @@ -14,7 +14,7 @@ Adds flying monsters to control ghast and phantoms Adds villagers as separate config diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java -index ae2606215a43a49b5e65052c407df715f260e400..60de95d72ca4e4b2e12a2b3363c59a08b75d0aae 100644 +index 993617e87c71320fe51adf24bef691aa978d42e3..7eec9afc5782d5d588f029cf7451c354a52f176a 100644 --- a/src/main/java/net/minecraft/server/level/ServerLevel.java +++ b/src/main/java/net/minecraft/server/level/ServerLevel.java @@ -2,7 +2,6 @@ package net.minecraft.server.level; @@ -124,10 +124,10 @@ index ae2606215a43a49b5e65052c407df715f260e400..60de95d72ca4e4b2e12a2b3363c59a08 } 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 1d8eb407c892e4c635f11070036013587a9264cb..4510c7da6dcc07a11904579f70dab80151acb80e 100644 +index 508e83183bafacac0fa7469ae50123ed26898120..67d149bbe80bd86ab8e62b584aac48a7382c6bb7 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -326,6 +326,8 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n +@@ -327,6 +327,8 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n public final org.spigotmc.ActivationRange.ActivationType activationType = org.spigotmc.ActivationRange.initializeEntityActivationType(this); public final boolean defaultActivationState; public long activatedTick = Integer.MIN_VALUE; @@ -136,7 +136,7 @@ index 1d8eb407c892e4c635f11070036013587a9264cb..4510c7da6dcc07a11904579f70dab801 public boolean spawnedViaMobSpawner; // Paper - Yes this name is similar to above, upstream took the better one protected int numCollisions = 0; // Paper public void inactiveTick() { } -@@ -767,6 +769,8 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n +@@ -768,6 +770,8 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n } else { this.wasOnFire = this.isOnFire(); if (movementType == MoverType.PISTON) { @@ -145,7 +145,7 @@ index 1d8eb407c892e4c635f11070036013587a9264cb..4510c7da6dcc07a11904579f70dab801 movement = this.limitPistonMovement(movement); if (movement.equals(Vec3.ZERO)) { return; -@@ -779,6 +783,13 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n +@@ -780,6 +784,13 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n this.stuckSpeedMultiplier = Vec3.ZERO; this.setDeltaMovement(Vec3.ZERO); } @@ -319,7 +319,7 @@ index 0ba4e6111726a1ca3cc5b6ce21e0500cc57a4aa3..cbec6decd12dae4f1b9f05f863b493d7 super.customServerAiStep(); } diff --git a/src/main/java/net/minecraft/world/level/Level.java b/src/main/java/net/minecraft/world/level/Level.java -index af0dd46e352115d1984f07fff746c7ad41486ac2..fb6da4bccd33b9e079f4bcf84f8ff59ad24a5fe6 100644 +index 44b88af588f233943ab183ad45b97b051db73aab..fac722d2f5bbd86cbeacc7da4bb45155257ae97f 100644 --- a/src/main/java/net/minecraft/world/level/Level.java +++ b/src/main/java/net/minecraft/world/level/Level.java @@ -155,6 +155,12 @@ public abstract class Level implements LevelAccessor, AutoCloseable { @@ -344,8 +344,8 @@ index 9b631698d1c736f61e07a5a1253127f4081dc90d..f18b20f94b4d2d7f07a70414834b3b28 entity.setDeltaMovement(e, g, h); + // Paper - EAR items stuck in in slime pushed by a piston -+ entity.activatedTick = Math.max(entity.activatedTick, net.minecraft.server.MinecraftServer.currentTick + 10); -+ entity.activatedImmunityTick = Math.max(entity.activatedImmunityTick, net.minecraft.server.MinecraftServer.currentTick + 10); ++ entity.activatedTick = Math.max(entity.activatedTick, net.minecraft.server.MinecraftServer.currentTick + 10); ++ entity.activatedImmunityTick = Math.max(entity.activatedImmunityTick, net.minecraft.server.MinecraftServer.currentTick + 10); + // Paper end break; } diff --git a/patches/server/0365-Increase-Light-Queue-Size.patch b/patches/server/0365-Increase-Light-Queue-Size.patch index 3c238a67da..7737d11ff1 100644 --- a/patches/server/0365-Increase-Light-Queue-Size.patch +++ b/patches/server/0365-Increase-Light-Queue-Size.patch @@ -29,10 +29,10 @@ index bf704993d0abd50dba91682a7fbb575e3696be62..a91a7d8f56a068b18d50a8b987b71510 } diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java -index 677966d14c56d121bc39ba0a1fb358f6b7610c4e..ce438760cbc92c08c079d06a8b97eaeda1018491 100644 +index cc764bb6d7460fd7fc649dd0b7ec61329866dc70..ce5cb696dfa2ff9a07ab9e7547ba54920e58f53a 100644 --- a/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java -@@ -828,7 +828,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop WorldDataServer - public ServerLevel(MinecraftServer minecraftserver, Executor executor, LevelStorageSource.LevelStorageAccess convertable_conversionsession, ServerLevelData iworlddataserver, ResourceKey resourcekey, DimensionType dimensionmanager, ChunkProgressListener worldloadlistener, ChunkGenerator chunkgenerator, boolean flag, long i, List list, boolean flag1, org.bukkit.World.Environment env, org.bukkit.generator.ChunkGenerator gen) { + public ServerLevel(MinecraftServer minecraftserver, Executor executor, LevelStorageSource.LevelStorageAccess convertable_conversionsession, ServerLevelData iworlddataserver, ResourceKey resourcekey, DimensionType dimensionmanager, ChunkProgressListener worldloadlistener, ChunkGenerator chunkgenerator, boolean flag, long i, List list, boolean flag1, org.bukkit.World.Environment env, org.bukkit.generator.ChunkGenerator gen, org.bukkit.generator.BiomeProvider biomeProvider) { // Objects.requireNonNull(minecraftserver); // CraftBukkit - decompile error -- super(iworlddataserver, resourcekey, dimensionmanager, minecraftserver::getProfiler, false, flag, i, gen, env); -+ super(iworlddataserver, resourcekey, dimensionmanager, minecraftserver::getProfiler, false, flag, i, gen, env, executor); // Paper - Anti-Xray - Pass executor +- super(iworlddataserver, resourcekey, dimensionmanager, minecraftserver::getProfiler, false, flag, i, gen, biomeProvider, env); ++ super(iworlddataserver, resourcekey, dimensionmanager, minecraftserver::getProfiler, false, flag, i, gen, biomeProvider, env, executor); // Paper - Anti-Xray - Pass executor this.pvpMode = minecraftserver.isPvpAllowed(); this.convertable = convertable_conversionsession; this.uuid = WorldUUID.getUUID(convertable_conversionsession.levelPath.toFile()); @@ -1139,7 +1139,7 @@ index 8659df9d2e9d8b3b0cd992efc9a1f3b2d958e9c8..3f7919f4e8f5a5b79bf4e541ea5f4ce4 public void destroyAndAck(BlockPos pos, ServerboundPlayerActionPacket.Action action, String reason) { diff --git a/src/main/java/net/minecraft/world/level/Level.java b/src/main/java/net/minecraft/world/level/Level.java -index fb6da4bccd33b9e079f4bcf84f8ff59ad24a5fe6..2007b0b04e7037e1444b5d1964638ccd06e7a2df 100644 +index fac722d2f5bbd86cbeacc7da4bb45155257ae97f..d050d60900a6829a9409ef944d7e4fceb5248dc1 100644 --- a/src/main/java/net/minecraft/world/level/Level.java +++ b/src/main/java/net/minecraft/world/level/Level.java @@ -165,6 +165,7 @@ public abstract class Level implements LevelAccessor, AutoCloseable { @@ -1154,8 +1154,8 @@ index fb6da4bccd33b9e079f4bcf84f8ff59ad24a5fe6..2007b0b04e7037e1444b5d1964638ccd return this.typeKey; } -- protected Level(WritableLevelData worlddatamutable, ResourceKey resourcekey, final DimensionType dimensionmanager, Supplier supplier, boolean flag, boolean flag1, long i, org.bukkit.generator.ChunkGenerator gen, org.bukkit.World.Environment env) { -+ protected Level(WritableLevelData worlddatamutable, ResourceKey resourcekey, final DimensionType dimensionmanager, Supplier supplier, boolean flag, boolean flag1, long i, org.bukkit.generator.ChunkGenerator gen, org.bukkit.World.Environment env, java.util.concurrent.Executor executor) { // Paper - Anti-Xray - Pass executor +- protected Level(WritableLevelData worlddatamutable, ResourceKey resourcekey, final DimensionType dimensionmanager, Supplier supplier, boolean flag, boolean flag1, long i, org.bukkit.generator.ChunkGenerator gen, org.bukkit.generator.BiomeProvider biomeProvider, org.bukkit.World.Environment env) { ++ protected Level(WritableLevelData worlddatamutable, ResourceKey resourcekey, final DimensionType dimensionmanager, Supplier supplier, boolean flag, boolean flag1, long i, org.bukkit.generator.ChunkGenerator gen, org.bukkit.generator.BiomeProvider biomeProvider, org.bukkit.World.Environment env, java.util.concurrent.Executor executor) { // Paper - Anti-Xray - Pass executor this.spigotConfig = new org.spigotmc.SpigotWorldConfig(((net.minecraft.world.level.storage.PrimaryLevelData) worlddatamutable).getLevelName()); // Spigot this.paperConfig = new com.destroystokyo.paper.PaperWorldConfig(((net.minecraft.world.level.storage.PrimaryLevelData) worlddatamutable).getLevelName(), this.spigotConfig); // Paper this.generator = gen; @@ -1426,28 +1426,28 @@ index 17c2f2dca587b350dc3e48f01dc62025a12d83c0..1ba393e2b47cca45bfa8e4ff4ef2438f blockids.read(data.getList("Palette", CraftMagicNumbers.NBT.TAG_COMPOUND), data.getLongArray("BlockStates")); sectionBlockIDs[i] = blockids; -diff --git a/src/main/java/org/bukkit/craftbukkit/generator/CraftChunkData.java b/src/main/java/org/bukkit/craftbukkit/generator/CraftChunkData.java -index c587007de724f165c031a18ab59edd0623a045f3..45e5dfeef92e9756b0fa63d8fc66a4cf96ae7d9a 100644 ---- a/src/main/java/org/bukkit/craftbukkit/generator/CraftChunkData.java -+++ b/src/main/java/org/bukkit/craftbukkit/generator/CraftChunkData.java -@@ -23,9 +23,11 @@ public final class CraftChunkData implements ChunkGenerator.ChunkData { - private LevelChunkSection[] sections; +diff --git a/src/main/java/org/bukkit/craftbukkit/generator/OldCraftChunkData.java b/src/main/java/org/bukkit/craftbukkit/generator/OldCraftChunkData.java +index 7bfd803d11976dba9ace79edc76bb083a2eccf38..a48c659c02c6c33a8efdac6daf9c9a0708f05071 100644 +--- a/src/main/java/org/bukkit/craftbukkit/generator/OldCraftChunkData.java ++++ b/src/main/java/org/bukkit/craftbukkit/generator/OldCraftChunkData.java +@@ -25,9 +25,11 @@ public final class OldCraftChunkData implements ChunkGenerator.ChunkData { + private final LevelChunkSection[] sections; private Set tiles; private final Set lights = new HashSet<>(); + private World world; // Paper - Anti-Xray - Add parameters - public CraftChunkData(World world) { + public OldCraftChunkData(World world) { this(world.getMinHeight(), world.getMaxHeight()); + this.world = world; // Paper - Anti-Xray - Add parameters } - /* pp for tests */ CraftChunkData(int minHeight, int maxHeight) { -@@ -170,7 +172,7 @@ public final class CraftChunkData implements ChunkGenerator.ChunkData { + /* pp for tests */ OldCraftChunkData(int minHeight, int maxHeight) { +@@ -177,7 +179,7 @@ public final class OldCraftChunkData implements ChunkGenerator.ChunkData { int offset = (y - this.minHeight) >> 4; LevelChunkSection section = this.sections[offset]; if (create && section == null) { - this.sections[offset] = section = new LevelChunkSection(offset + (this.minHeight >> 4)); -+ this.sections[offset] = section = new LevelChunkSection(offset + (this.minHeight >> 4), null, this.world instanceof org.bukkit.craftbukkit.CraftWorld ? ((org.bukkit.craftbukkit.CraftWorld) this.world).getHandle() : null, true); // Paper - Anti-Xray - Add parameters ++ this.sections[offset] = section = new LevelChunkSection(offset + (this.minHeight >> 4), null, world instanceof org.bukkit.craftbukkit.CraftWorld ? ((org.bukkit.craftbukkit.CraftWorld) this.world).getHandle() : null, true); // Paper - Anti-Xray - Add parameters } return section; } diff --git a/patches/server/0368-No-Tick-view-distance-implementation.patch b/patches/server/0368-No-Tick-view-distance-implementation.patch index 8b1f8f1805..d6eeba3320 100644 --- a/patches/server/0368-No-Tick-view-distance-implementation.patch +++ b/patches/server/0368-No-Tick-view-distance-implementation.patch @@ -23,7 +23,7 @@ index ee53453440177537fc653ea156785d7591498614..cfe293881f68c8db337c3a48948362bb })); diff --git a/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java b/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java -index b8ca1f73b2451307c3711076eaa43e2adb34d92e..45e30c0d78b7625a6a55e6d7d60a823b674b75db 100644 +index 9e16c9e6b6e84d84028821f2ade103dbced66470..fd1064b08e61c0547cad092e009635ab708b8962 100644 --- a/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java +++ b/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java @@ -487,6 +487,11 @@ public class PaperWorldConfig { @@ -563,7 +563,7 @@ index 4ba978af436cb114aa5274df5cd8bd25ff7be2c9..10eb562d2089dc20c9ec33956c3e2f98 while (iterator.hasNext()) { diff --git a/src/main/java/net/minecraft/world/level/Level.java b/src/main/java/net/minecraft/world/level/Level.java -index 2007b0b04e7037e1444b5d1964638ccd06e7a2df..fa8cf70d7d24a82757326ff8f7f240cff3dcbe73 100644 +index d050d60900a6829a9409ef944d7e4fceb5248dc1..a49fdaa7b7a0ed82e4a1ebab0a4fb086e86b8e36 100644 --- a/src/main/java/net/minecraft/world/level/Level.java +++ b/src/main/java/net/minecraft/world/level/Level.java @@ -528,8 +528,13 @@ public abstract class Level implements LevelAccessor, AutoCloseable { @@ -658,10 +658,10 @@ index 515e28eea8cbab261320352ee0db9b877807f3ed..83ed84f89a036d3768b22a36bc8a0bfc this.postProcessing[i].clear(); diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -index b57e5ffca725b10570aa10a870b992e6b767c2ec..4c439246f476225e6a1c6a2e758cf6d6d0fdf7a9 100644 +index 2a5d4e4efe9ea9fcac4c6079c28a020b4c2df118..d347f8f3bfe7ed0492dd0cd593837ee2246527aa 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -@@ -2587,10 +2587,39 @@ public class CraftWorld implements World { +@@ -1895,10 +1895,39 @@ public class CraftWorld extends CraftRegionAccessor implements World { // Spigot start @Override public int getViewDistance() { @@ -703,7 +703,7 @@ index b57e5ffca725b10570aa10a870b992e6b767c2ec..4c439246f476225e6a1c6a2e758cf6d6 private final org.bukkit.World.Spigot spigot = new org.bukkit.World.Spigot() { diff --git a/src/main/java/org/spigotmc/ActivationRange.java b/src/main/java/org/spigotmc/ActivationRange.java -index 2ab585a018290996e7fa9ca6f3ad7d734cd7beaa..a08583863f9fa08016bdfc7949a273eaa4429927 100644 +index 2574ccd92c43f56e8be71f1bf6857c761a72a510..951e8ba1e05436aa0afcd0a72358550422afa791 100644 --- a/src/main/java/org/spigotmc/ActivationRange.java +++ b/src/main/java/org/spigotmc/ActivationRange.java @@ -188,7 +188,7 @@ public class ActivationRange diff --git a/patches/server/0371-Fix-items-vanishing-through-end-portal.patch b/patches/server/0371-Fix-items-vanishing-through-end-portal.patch index 9b062259ad..227e6757db 100644 --- a/patches/server/0371-Fix-items-vanishing-through-end-portal.patch +++ b/patches/server/0371-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 4510c7da6dcc07a11904579f70dab80151acb80e..9a96db211fe19e92f4fae8b007e8be2d899d8f09 100644 +index 67d149bbe80bd86ab8e62b584aac48a7382c6bb7..635607e8fb58b7e9a5eca7d43ad028cf8815f67b 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -3009,6 +3009,9 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n +@@ -3010,6 +3010,9 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n BlockPos blockposition1; if (flag1) { diff --git a/patches/server/0379-Entity-Jump-API.patch b/patches/server/0379-Entity-Jump-API.patch index bc86bc9feb..9ac135ab85 100644 --- a/patches/server/0379-Entity-Jump-API.patch +++ b/patches/server/0379-Entity-Jump-API.patch @@ -5,7 +5,7 @@ Subject: [PATCH] Entity Jump API diff --git a/src/main/java/net/minecraft/world/entity/LivingEntity.java b/src/main/java/net/minecraft/world/entity/LivingEntity.java -index 560236c33d2afe289a534c8cd1d1df413eb5d78d..7caa240343a06a3956a7d75e2ccf16814076a6b4 100644 +index 9f108e1327f09d5c4876b096b50c62866c2fd6d4..36592baae26dce299980060d941730e6dd853cef 100644 --- a/src/main/java/net/minecraft/world/entity/LivingEntity.java +++ b/src/main/java/net/minecraft/world/entity/LivingEntity.java @@ -3165,8 +3165,10 @@ public abstract class LivingEntity extends Entity { @@ -34,10 +34,10 @@ index 2d59eab846db2c0a624cf6d06a570b2313aa6b13..851ee58e52c6003d6ae7b58c9b6b9a9a } diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java -index e9795e569b5aa8aa639d6a4e0b6789f9681cd73d..5e10cca36c0469fd576e8aa916bba540ea090e61 100644 +index c396ad36084e46c4b812d970e07a9188aed16daf..e617e4ecd3763dea795d524b92f8a979fd7d3c48 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java -@@ -797,5 +797,19 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity { +@@ -820,5 +820,19 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity { public org.bukkit.inventory.EquipmentSlot getHandRaised() { return getHandle().getUsedItemHand() == net.minecraft.world.InteractionHand.MAIN_HAND ? org.bukkit.inventory.EquipmentSlot.HAND : org.bukkit.inventory.EquipmentSlot.OFF_HAND; } diff --git a/patches/server/0380-Add-option-to-nerf-pigmen-from-nether-portals.patch b/patches/server/0380-Add-option-to-nerf-pigmen-from-nether-portals.patch index ca449a4917..8a23addf4a 100644 --- a/patches/server/0380-Add-option-to-nerf-pigmen-from-nether-portals.patch +++ b/patches/server/0380-Add-option-to-nerf-pigmen-from-nether-portals.patch @@ -5,7 +5,7 @@ Subject: [PATCH] Add option to nerf pigmen from nether portals diff --git a/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java b/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java -index f2e4939c8144b9bc7441130302ab3e2358c42063..3d14a7dbcc6bc46141596a7e04f790bfe8f560c6 100644 +index 7dc740d392becc622e98a5a83be332adf6fcc4e8..9e1263804f1a07400a21e5ce705c24b2b771219c 100644 --- a/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java +++ b/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java @@ -482,6 +482,11 @@ public class PaperWorldConfig { @@ -21,10 +21,10 @@ index f2e4939c8144b9bc7441130302ab3e2358c42063..3d14a7dbcc6bc46141596a7e04f790bf private void lightQueueSize() { lightQueueSize = getInt("light-queue-size", lightQueueSize); diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index 9a96db211fe19e92f4fae8b007e8be2d899d8f09..8ac6bf93ab35062a1325b099a695fea1ba154a1d 100644 +index 635607e8fb58b7e9a5eca7d43ad028cf8815f67b..9e692c816bb8173dba7314866e3321bfa24e577e 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -329,6 +329,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n +@@ -330,6 +330,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n public long activatedImmunityTick = Integer.MIN_VALUE; // Paper public boolean isTemporarilyActive = false; // Paper public boolean spawnedViaMobSpawner; // Paper - Yes this name is similar to above, upstream took the better one @@ -32,7 +32,7 @@ index 9a96db211fe19e92f4fae8b007e8be2d899d8f09..8ac6bf93ab35062a1325b099a695fea1 protected int numCollisions = 0; // Paper public void inactiveTick() { } // Spigot end -@@ -1886,6 +1887,9 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n +@@ -1887,6 +1888,9 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n if (spawnedViaMobSpawner) { nbt.putBoolean("Paper.FromMobSpawner", true); } @@ -42,7 +42,7 @@ index 9a96db211fe19e92f4fae8b007e8be2d899d8f09..8ac6bf93ab35062a1325b099a695fea1 // Paper end return nbt; } catch (Throwable throwable) { -@@ -2027,6 +2031,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n +@@ -2028,6 +2032,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n } spawnedViaMobSpawner = nbt.getBoolean("Paper.FromMobSpawner"); // Restore entity's from mob spawner status diff --git a/patches/server/0388-Optimise-TickListServer-by-rewriting-it.patch b/patches/server/0388-Optimise-TickListServer-by-rewriting-it.patch index 77c11cd797..a078a59e1b 100644 --- a/patches/server/0388-Optimise-TickListServer-by-rewriting-it.patch +++ b/patches/server/0388-Optimise-TickListServer-by-rewriting-it.patch @@ -949,7 +949,7 @@ index 5891d79abc5dc0b8ab85cc40819249f399fd1251..6f33d4f4ca86bfcad907b451a56e71de public ServerChunkCache(ServerLevel world, LevelStorageSource.LevelStorageAccess session, DataFixer dataFixer, StructureManager structureManager, Executor workerExecutor, ChunkGenerator chunkGenerator, int viewDistance, boolean flag, ChunkProgressListener worldGenerationProgressListener, ChunkStatusUpdateListener chunkstatusupdatelistener, Supplier supplier) { this.level = world; diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java -index 00a064305dd8c671566dc32b8cd85f593ad139a3..4e654eda235d05ba96bacc6d9c14ce6428e60d07 100644 +index 54008a97cc88ac431c3517c19160903408ee9255..dba04e84015cecd4db36dc5c28f1547f9c2db2e6 100644 --- a/src/main/java/net/minecraft/server/level/ServerLevel.java +++ b/src/main/java/net/minecraft/server/level/ServerLevel.java @@ -291,6 +291,15 @@ public class ServerLevel extends Level implements WorldGenLevel { @@ -966,7 +966,7 @@ index 00a064305dd8c671566dc32b8cd85f593ad139a3..4e654eda235d05ba96bacc6d9c14ce64 + // Paper end - rewrite ticklistserver + // Add env and gen to constructor, WorldData -> WorldDataServer - public ServerLevel(MinecraftServer minecraftserver, Executor executor, LevelStorageSource.LevelStorageAccess convertable_conversionsession, ServerLevelData iworlddataserver, ResourceKey resourcekey, DimensionType dimensionmanager, ChunkProgressListener worldloadlistener, ChunkGenerator chunkgenerator, boolean flag, long i, List list, boolean flag1, org.bukkit.World.Environment env, org.bukkit.generator.ChunkGenerator gen) { + public ServerLevel(MinecraftServer minecraftserver, Executor executor, LevelStorageSource.LevelStorageAccess convertable_conversionsession, ServerLevelData iworlddataserver, ResourceKey resourcekey, DimensionType dimensionmanager, ChunkProgressListener worldloadlistener, ChunkGenerator chunkgenerator, boolean flag, long i, List list, boolean flag1, org.bukkit.World.Environment env, org.bukkit.generator.ChunkGenerator gen, org.bukkit.generator.BiomeProvider biomeProvider) { // Objects.requireNonNull(minecraftserver); // CraftBukkit - decompile error @@ -307,13 +316,19 @@ public class ServerLevel extends Level implements WorldGenLevel { DefaultedRegistry registryblocks = Registry.BLOCK; diff --git a/patches/server/0396-Optimize-PlayerChunkMap-memory-use-for-visibleChunks.patch b/patches/server/0396-Optimize-PlayerChunkMap-memory-use-for-visibleChunks.patch index e774a7b27f..3ddff39d3e 100644 --- a/patches/server/0396-Optimize-PlayerChunkMap-memory-use-for-visibleChunks.patch +++ b/patches/server/0396-Optimize-PlayerChunkMap-memory-use-for-visibleChunks.patch @@ -246,10 +246,10 @@ index 6f33d4f4ca86bfcad907b451a56e71de0d4585d5..228ff4b52a017e8af987f60d84b7906c Collections.shuffle(list); //Paper start - call player naturally spawn event diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -index a4d05aeccc142808981f1ecebd001c905ae721ed..e6b7302554b2a54363d55e149744237679262174 100644 +index d347f8f3bfe7ed0492dd0cd593837ee2246527aa..059b901e79cf0e2d152375453d36437a43c4f244 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -@@ -288,6 +288,7 @@ public class CraftWorld implements World { +@@ -146,6 +146,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { @Override public int getTileEntityCount() { @@ -257,7 +257,7 @@ index a4d05aeccc142808981f1ecebd001c905ae721ed..e6b7302554b2a54363d55e1497442376 // We don't use the full world tile entity list, so we must iterate chunks Long2ObjectLinkedOpenHashMap chunks = world.getChunkSource().chunkMap.visibleChunkMap; int size = 0; -@@ -299,6 +300,7 @@ public class CraftWorld implements World { +@@ -157,6 +158,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { size += chunk.blockEntities.size(); } return size; @@ -265,7 +265,7 @@ index a4d05aeccc142808981f1ecebd001c905ae721ed..e6b7302554b2a54363d55e1497442376 } @Override -@@ -308,6 +310,7 @@ public class CraftWorld implements World { +@@ -166,6 +168,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { @Override public int getChunkCount() { @@ -273,7 +273,7 @@ index a4d05aeccc142808981f1ecebd001c905ae721ed..e6b7302554b2a54363d55e1497442376 int ret = 0; for (ChunkHolder chunkHolder : world.getChunkSource().chunkMap.visibleChunkMap.values()) { -@@ -316,7 +319,7 @@ public class CraftWorld implements World { +@@ -174,7 +177,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { } } @@ -282,7 +282,7 @@ index a4d05aeccc142808981f1ecebd001c905ae721ed..e6b7302554b2a54363d55e1497442376 } @Override -@@ -443,6 +446,14 @@ public class CraftWorld implements World { +@@ -302,6 +305,14 @@ public class CraftWorld extends CraftRegionAccessor implements World { @Override public Chunk[] getLoadedChunks() { diff --git a/patches/server/0397-Mid-Tick-Chunk-Tasks-Speed-up-processing-of-chunk-lo.patch b/patches/server/0397-Mid-Tick-Chunk-Tasks-Speed-up-processing-of-chunk-lo.patch index f522b46db7..6551716f63 100644 --- a/patches/server/0397-Mid-Tick-Chunk-Tasks-Speed-up-processing-of-chunk-lo.patch +++ b/patches/server/0397-Mid-Tick-Chunk-Tasks-Speed-up-processing-of-chunk-lo.patch @@ -56,10 +56,10 @@ index 2fcb923b8aa0e891de9f86c4c55a4af8969c04cd..04b402084d847ba75b8282b25054d7df + } } diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java -index ce438760cbc92c08c079d06a8b97eaeda1018491..0115ffe84356468ddc254d8d5bdd719bc5e7e3f8 100644 +index ce5cb696dfa2ff9a07ab9e7547ba54920e58f53a..3c299bae9095ddc3732f1817c2d52f8d8a6987db 100644 --- a/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java -@@ -1120,6 +1120,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop { @@ -108,7 +108,7 @@ index ce438760cbc92c08c079d06a8b97eaeda1018491..0115ffe84356468ddc254d8d5bdd719b return !this.canOversleep(); }); isOversleep = false;MinecraftTimings.serverOversleep.stopTiming(); -@@ -1381,13 +1400,16 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop processQueue = new java.util.concurrent.ConcurrentLinkedQueue(); public int autosavePeriod; public Commands vanillaCommandDispatcher; @@ -83,7 +83,7 @@ index def1edb961ba41819ce30c427b1616578a513433..736cbb3430ba1d8c00ea43a80c978949 // CraftBukkit end // Spigot start public static final int TPS = 20; -@@ -307,6 +307,9 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop S spin(Function serverFactory) { AtomicReference atomicreference = new AtomicReference(); Thread thread = new Thread(() -> { -@@ -916,6 +919,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop> 4, (int) Math.floor(this.getZ()) >> 4); // CraftBukkit -+ if (valid) this.level.getChunk((int) Math.floor(this.getX()) >> 4, (int) Math.floor(this.getZ()) >> 4); // CraftBukkit // Paper - } - - public void moveTo(Vec3 pos) { diff --git a/patches/server/0419-Move-player-to-spawn-point-if-spawn-in-unloaded-worl.patch b/patches/server/0419-Move-player-to-spawn-point-if-spawn-in-unloaded-worl.patch index c43c97f6a6..176afca770 100644 --- a/patches/server/0419-Move-player-to-spawn-point-if-spawn-in-unloaded-worl.patch +++ b/patches/server/0419-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 ebf7a58c6af5f5573d97c730c50c69a9f8140a6d..a6e90cfaae38b9e4db812b7338dd0738608cae27 100644 +index b331d83b2d92af2e1c5641765ba41d6d62a50a3b..e629e40285d09ffca71db3215941f302704463a3 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -2004,9 +2004,11 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n +@@ -2005,9 +2005,11 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n bworld = server.getWorld(worldName); } diff --git a/patches/server/0424-Fix-numerous-item-duplication-issues-and-teleport-is.patch b/patches/server/0424-Fix-numerous-item-duplication-issues-and-teleport-is.patch index 2bfc42729a..c30f021136 100644 --- a/patches/server/0424-Fix-numerous-item-duplication-issues-and-teleport-is.patch +++ b/patches/server/0424-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 a6e90cfaae38b9e4db812b7338dd0738608cae27..9c5a475c221261482bcfe6495a53d76ffa7c1e5c 100644 +index e629e40285d09ffca71db3215941f302704463a3..143b6a5b9f3d481a693ed0b9ae96aef8b9d517d5 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -2153,11 +2153,12 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n +@@ -2154,11 +2154,12 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n } 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 a6e90cfaae38b9e4db812b7338dd0738608cae27..9c5a475c221261482bcfe6495a53d76f entityitem.setDefaultPickUpDelay(); // CraftBukkit start -@@ -2899,6 +2900,12 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n +@@ -2900,6 +2901,12 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n @Nullable public Entity teleportTo(ServerLevel worldserver, BlockPos location) { // CraftBukkit end @@ -47,7 +47,7 @@ index a6e90cfaae38b9e4db812b7338dd0738608cae27..9c5a475c221261482bcfe6495a53d76f if (this.level instanceof ServerLevel && !this.isRemoved()) { this.level.getProfiler().push("changeDimension"); // CraftBukkit start -@@ -2919,6 +2926,11 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n +@@ -2920,6 +2927,11 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n // CraftBukkit end this.level.getProfiler().popPush("reloading"); @@ -59,7 +59,7 @@ index a6e90cfaae38b9e4db812b7338dd0738608cae27..9c5a475c221261482bcfe6495a53d76f Entity entity = this.getType().create((Level) worldserver); if (entity != null) { -@@ -2932,10 +2944,6 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n +@@ -2933,10 +2945,6 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n // CraftBukkit start - Forward the CraftEntity to the new entity this.getBukkitEntity().setHandle(entity); entity.bukkitEntity = this.getBukkitEntity(); @@ -70,7 +70,7 @@ index a6e90cfaae38b9e4db812b7338dd0738608cae27..9c5a475c221261482bcfe6495a53d76f // CraftBukkit end } -@@ -3060,7 +3068,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n +@@ -3061,7 +3069,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n } public boolean canChangeDimensions() { diff --git a/patches/server/0428-Expose-game-version.patch b/patches/server/0428-Expose-game-version.patch index c13733dc36..451b6002f8 100644 --- a/patches/server/0428-Expose-game-version.patch +++ b/patches/server/0428-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 57e37048e896eec47fdd9585d40cb1b82a3775a2..1a1d4f6deadd2faf811ad16d5548c94786ecc84d 100644 +index d1661f7f527765a847a057902acad31954896557..b499675f6d94203924cdaebcb2b06db20fe0ed14 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -526,6 +526,13 @@ public final class CraftServer implements Server { +@@ -532,6 +532,13 @@ public final class CraftServer implements Server { return this.bukkitVersion; } diff --git a/patches/server/0431-Implement-Mob-Goal-API.patch b/patches/server/0431-Implement-Mob-Goal-API.patch index 487cde7282..d9a39f4cb1 100644 --- a/patches/server/0431-Implement-Mob-Goal-API.patch +++ b/patches/server/0431-Implement-Mob-Goal-API.patch @@ -899,10 +899,10 @@ index 8c2ec30a35e86f2b30863045b586a67e485c624b..848cac4426346b6d2ed575f33bf01c0e LOOK, JUMP, diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 1a1d4f6deadd2faf811ad16d5548c94786ecc84d..464cf287cf2bad787207f29946c97c9709a699e9 100644 +index b499675f6d94203924cdaebcb2b06db20fe0ed14..1279e1d3bafac03cbc31807d0934e80e47d4f759 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -2473,5 +2473,11 @@ public final class CraftServer implements Server { +@@ -2532,5 +2532,11 @@ public final class CraftServer implements Server { public boolean isStopping() { return net.minecraft.server.MinecraftServer.getServer().hasStopped(); } diff --git a/patches/server/0432-Use-distance-map-to-optimise-entity-tracker.patch b/patches/server/0432-Use-distance-map-to-optimise-entity-tracker.patch index b0de5a152c..4366c81031 100644 --- a/patches/server/0432-Use-distance-map-to-optimise-entity-tracker.patch +++ b/patches/server/0432-Use-distance-map-to-optimise-entity-tracker.patch @@ -288,7 +288,7 @@ index e7c78106aa34d948a77cf72d5716e17d10beae72..073aa637fcaf14a5ae8b203604d75b74 } } diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index 9c5a475c221261482bcfe6495a53d76ffa7c1e5c..e07011898143b04090cb7ea4b3f4fd9c255209de 100644 +index 143b6a5b9f3d481a693ed0b9ae96aef8b9d517d5..35107dceb201817597e84da47e4a7506ac9336b2 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java @@ -50,6 +50,7 @@ import net.minecraft.network.syncher.EntityDataSerializers; @@ -299,7 +299,7 @@ index 9c5a475c221261482bcfe6495a53d76ffa7c1e5c..e07011898143b04090cb7ea4b3f4fd9c import net.minecraft.server.MinecraftServer; import net.minecraft.server.level.ServerLevel; import net.minecraft.server.level.ServerPlayer; -@@ -344,6 +345,21 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n +@@ -345,6 +346,21 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n } // CraftBukkit end diff --git a/patches/server/0434-Add-villager-reputation-API.patch b/patches/server/0434-Add-villager-reputation-API.patch index f67d85d30b..22bcc36142 100644 --- a/patches/server/0434-Add-villager-reputation-API.patch +++ b/patches/server/0434-Add-villager-reputation-API.patch @@ -62,7 +62,7 @@ index 3eb1d640f53e0b8be53fa78aaa7bca6a7963d912..01df536b3b61281828ca2be03ac1bbb6 static class GossipEntry { diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftVillager.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftVillager.java -index 0e247979b5ced02c1de422547fc8ebf7067006ee..f7067789b0473bb8c2ec83b9c77e0cedb81cf0ca 100644 +index 83b7b136794ad855eb0faf839edfcf4a024b2c2a..1c2a086445b1dd59299eef89056990bc3d1152f8 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftVillager.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftVillager.java @@ -16,6 +16,13 @@ import org.bukkit.entity.Villager; @@ -79,7 +79,7 @@ index 0e247979b5ced02c1de422547fc8ebf7067006ee..f7067789b0473bb8c2ec83b9c77e0ced public class CraftVillager extends CraftAbstractVillager implements Villager { public CraftVillager(CraftServer server, net.minecraft.world.entity.npc.Villager entity) { -@@ -130,4 +137,45 @@ public class CraftVillager extends CraftAbstractVillager implements Villager { +@@ -132,4 +139,45 @@ public class CraftVillager extends CraftAbstractVillager implements Villager { public static VillagerProfession bukkitToNmsProfession(Profession bukkit) { return Registry.VILLAGER_PROFESSION.get(CraftNamespacedKey.toMinecraft(bukkit.getKey())); } diff --git a/patches/server/0437-Fix-PotionEffect-ignores-icon-flag.patch b/patches/server/0437-Fix-PotionEffect-ignores-icon-flag.patch index edff22f0a4..b9e0ada09f 100644 --- a/patches/server/0437-Fix-PotionEffect-ignores-icon-flag.patch +++ b/patches/server/0437-Fix-PotionEffect-ignores-icon-flag.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Fix PotionEffect ignores icon flag diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java -index 5e10cca36c0469fd576e8aa916bba540ea090e61..ae0e55e938f34e3d7fb25bbdb1f3e83067f5d9cf 100644 +index e617e4ecd3763dea795d524b92f8a979fd7d3c48..0d64e930f0a30e15b180cd845a692d3ff61c8927 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java -@@ -400,7 +400,7 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity { +@@ -412,7 +412,7 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity { @Override public boolean addPotionEffect(PotionEffect effect, boolean force) { diff --git a/patches/server/0440-Wait-for-Async-Tasks-during-shutdown.patch b/patches/server/0440-Wait-for-Async-Tasks-during-shutdown.patch index a97ad677e9..7381b537cd 100644 --- a/patches/server/0440-Wait-for-Async-Tasks-during-shutdown.patch +++ b/patches/server/0440-Wait-for-Async-Tasks-during-shutdown.patch @@ -10,10 +10,10 @@ Adds a 5 second grace period for any async tasks to finish and warns if any are still running after that delay just as reload does. diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java -index 736cbb3430ba1d8c00ea43a80c978949108d8b6c..d285967a60903a73608a1f9cdc306e63066824ab 100644 +index dad662d1b252cfb77ff6646deb88514e3b563ea3..a5ef695a57e44a32da415320f6ee9ff5233c6ca4 100644 --- a/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java -@@ -953,6 +953,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop { net.minecraft.world.level.chunk.LevelChunk chunk = (net.minecraft.world.level.chunk.LevelChunk) either.left().orElse(null); diff --git a/patches/server/0456-incremental-chunk-saving.patch b/patches/server/0456-incremental-chunk-saving.patch index 311e3c6c70..4e3c2137fc 100644 --- a/patches/server/0456-incremental-chunk-saving.patch +++ b/patches/server/0456-incremental-chunk-saving.patch @@ -5,7 +5,7 @@ Subject: [PATCH] incremental chunk saving diff --git a/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java b/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java -index 9e5810eb0085ad956f0bd1cd69fa88909d9d638a..77e90a6b7d29ad989fd961e00a6fd97c7e5ec4fe 100644 +index e1f6190a8ea8606404060b3d2ebc5ceea6665a6e..acb4fe32835bca485cfb2ec509370c9f596d6a0f 100644 --- a/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java +++ b/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java @@ -44,6 +44,21 @@ public class PaperWorldConfig { @@ -31,10 +31,10 @@ index 9e5810eb0085ad956f0bd1cd69fa88909d9d638a..77e90a6b7d29ad989fd961e00a6fd97c config.addDefault("world-settings.default." + path, def); return config.getBoolean("world-settings." + worldName + "." + path, config.getBoolean("world-settings.default." + path)); diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java -index d285967a60903a73608a1f9cdc306e63066824ab..a36fa61313baf9ab260b8805860ac4bce24bc3c6 100644 +index a5ef695a57e44a32da415320f6ee9ff5233c6ca4..e477ccf2f17ffad0a3720f7ef7ccfe23b91bff3a 100644 --- a/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java -@@ -296,6 +296,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop processQueue = new java.util.concurrent.ConcurrentLinkedQueue(); public int autosavePeriod; @@ -42,7 +42,7 @@ index d285967a60903a73608a1f9cdc306e63066824ab..a36fa61313baf9ab260b8805860ac4bc public Commands vanillaCommandDispatcher; public boolean forceTicks; // Paper // CraftBukkit end -@@ -1413,14 +1414,23 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop tiles; + private final Set lights = new HashSet<>(); + private World world; // Paper - Anti-Xray - Add parameters +@@ -195,4 +195,10 @@ public final class OldCraftChunkData implements ChunkGenerator.ChunkData { + Set getLights() { + return this.lights; } - ++ + // Paper start + public void setRawChunkData(LevelChunkSection[] sections) { + this.sections = sections; + } + // Paper end -+ - Set getTiles() { - return this.tiles; - } + } diff --git a/patches/server/0499-Add-missing-strikeLighting-call-to-World-spigot-stri.patch b/patches/server/0499-Add-missing-strikeLighting-call-to-World-spigot-stri.patch index ff5b446cbe..814e628101 100644 --- a/patches/server/0499-Add-missing-strikeLighting-call-to-World-spigot-stri.patch +++ b/patches/server/0499-Add-missing-strikeLighting-call-to-World-spigot-stri.patch @@ -6,10 +6,10 @@ Subject: [PATCH] Add missing strikeLighting call to diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -index 32c24f9e37262f2a854556787f61cd7b7336da11..6bcc1a7ddfcdd0da157a65d2d866b28c390e3b41 100644 +index 496bb91da1138fb6a4e004da1eab43e588c82592..f45e92fd85bdb99e072d95ee76ef926bda99f733 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -@@ -2669,6 +2669,7 @@ public class CraftWorld implements World { +@@ -1977,6 +1977,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { lightning.moveTo( loc.getX(), loc.getY(), loc.getZ() ); lightning.visualOnly = true; lightning.isSilent = isSilent; diff --git a/patches/server/0500-Incremental-player-saving.patch b/patches/server/0500-Incremental-player-saving.patch index 89c0a3aa98..cff8769910 100644 --- a/patches/server/0500-Incremental-player-saving.patch +++ b/patches/server/0500-Incremental-player-saving.patch @@ -25,10 +25,10 @@ index de8b9be11b996f9d1eff30fa037cfa1823eff21b..b0fe3f0ac4c706c4b64f2778fcb8d6c2 + } } diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java -index 3ac5ab881913a90d5b59610e81d598e121320930..2c0b2bb254e9f4d39b526f170c11f481805d43d1 100644 +index 01394284fca2f56c1808e75f70a64c4cc2a196ea..de2c21486f07bc2dbbaa9598354cd4ed39cb94ca 100644 --- a/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java -@@ -963,7 +963,6 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop 0 && this.tickCount % this.autosavePeriod == 0) { // CraftBukkit // Paper - move down // MinecraftServer.LOGGER.debug("Autosave started"); // Paper serverAutoSave = (autosavePeriod > 0 && this.tickCount % autosavePeriod == 0); // Paper diff --git a/patches/server/0506-Add-setMaxPlayers-API.patch b/patches/server/0506-Add-setMaxPlayers-API.patch index 622f250204..e8124fb470 100644 --- a/patches/server/0506-Add-setMaxPlayers-API.patch +++ b/patches/server/0506-Add-setMaxPlayers-API.patch @@ -18,10 +18,10 @@ index e990c9d936b9b2b510dd9c7f5a507b4ba9e79965..518c93b7aa7a77c19d0256f3d9c24e3b private boolean allowCheatsForAllPlayers; private static final boolean ALLOW_LOGOUTIVATOR = false; diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index df20ac811d673c205695d563f84382d1bf1e82e1..c664c4fc1280fd57c3b7e8580294b3823b98eae9 100644 +index 50f85ab4f3ba97728f873cb2facb92a60e5ea765..509f662fcaa02a83b8dd508acce3b8276052d213 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -621,6 +621,13 @@ public final class CraftServer implements Server { +@@ -627,6 +627,13 @@ public final class CraftServer implements Server { return this.playerList.getMaxPlayers(); } diff --git a/patches/server/0507-Add-playPickupItemAnimation-to-LivingEntity.patch b/patches/server/0507-Add-playPickupItemAnimation-to-LivingEntity.patch index db89ce2d9b..985e34f4fb 100644 --- a/patches/server/0507-Add-playPickupItemAnimation-to-LivingEntity.patch +++ b/patches/server/0507-Add-playPickupItemAnimation-to-LivingEntity.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Add playPickupItemAnimation to LivingEntity diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java -index ae0e55e938f34e3d7fb25bbdb1f3e83067f5d9cf..b6f9dff2b634ca40fda6a9ed82cd472e29d1ce0d 100644 +index 0d64e930f0a30e15b180cd845a692d3ff61c8927..d740442a054327d88c5fdda20d10b41a7d322f0e 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java -@@ -811,5 +811,10 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity { +@@ -834,5 +834,10 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity { ((Mob) getHandle()).getJumpControl().jump(); } } diff --git a/patches/server/0509-Fix-SpawnChangeEvent-not-firing-for-all-use-cases.patch b/patches/server/0509-Fix-SpawnChangeEvent-not-firing-for-all-use-cases.patch index aea9770fdd..3efd75cf92 100644 --- a/patches/server/0509-Fix-SpawnChangeEvent-not-firing-for-all-use-cases.patch +++ b/patches/server/0509-Fix-SpawnChangeEvent-not-firing-for-all-use-cases.patch @@ -5,7 +5,7 @@ Subject: [PATCH] Fix SpawnChangeEvent not firing for all use-cases diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java -index ac9020467cef648c72ccb350d26f90545f5afb56..e60d2ef3482c002b082ee84f34b9e681447fa09e 100644 +index 2653a55d3c947577ea153f3060d9b98acdf31c07..7d97ca9449b123a82b41937353d8fd0b2c98ea4e 100644 --- a/src/main/java/net/minecraft/server/level/ServerLevel.java +++ b/src/main/java/net/minecraft/server/level/ServerLevel.java @@ -1621,6 +1621,7 @@ public class ServerLevel extends Level implements WorldGenLevel { @@ -17,10 +17,10 @@ index ac9020467cef648c72ccb350d26f90545f5afb56..e60d2ef3482c002b082ee84f34b9e681 // if this keepSpawnInMemory is false a plugin has already removed our tickets, do not re-add this.removeTicketsForSpawn(this.paperConfig.keepLoadedRange, prevSpawn); diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -index 6bcc1a7ddfcdd0da157a65d2d866b28c390e3b41..bf7ba6d7f1527d4bf8533c655316865f81cde75f 100644 +index f45e92fd85bdb99e072d95ee76ef926bda99f733..a6d04ddfc49eab2cabeab1af95635139a2cfdecd 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -@@ -387,11 +387,13 @@ public class CraftWorld implements World { +@@ -246,11 +246,13 @@ public class CraftWorld extends CraftRegionAccessor implements World { public boolean setSpawnLocation(int x, int y, int z, float angle) { try { Location previousLocation = this.getSpawnLocation(); diff --git a/patches/server/0510-Add-moon-phase-API.patch b/patches/server/0510-Add-moon-phase-API.patch index 3e4e60b223..7eda41c206 100644 --- a/patches/server/0510-Add-moon-phase-API.patch +++ b/patches/server/0510-Add-moon-phase-API.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Add moon phase API diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -index bf7ba6d7f1527d4bf8533c655316865f81cde75f..2bef1c8524944e0327260542a9ebed2d8aa854e0 100644 +index a6d04ddfc49eab2cabeab1af95635139a2cfdecd..2ed3f753fe2e353815cc3201d2dc363639ca85f1 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -@@ -326,6 +326,11 @@ public class CraftWorld implements World { +@@ -184,6 +184,11 @@ public class CraftWorld extends CraftRegionAccessor implements World { public int getPlayerCount() { return world.players().size(); } diff --git a/patches/server/0520-Add-methods-to-get-translation-keys.patch b/patches/server/0520-Add-methods-to-get-translation-keys.patch index d8cb4bd7cb..a618b250b5 100644 --- a/patches/server/0520-Add-methods-to-get-translation-keys.patch +++ b/patches/server/0520-Add-methods-to-get-translation-keys.patch @@ -6,10 +6,10 @@ Subject: [PATCH] Add methods to get translation keys 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 d33c56ac47884ebcce98494377af26cc77f8d5f6..a1cac393ece249e5f18fbc0db6a7ad9f14dfb3a1 100644 +index f92e8a53e327779d4e30a5f6806825a2a21b547a..ab47da233bd06cff0c5c9109e615e1cb9a39ebf0 100644 --- a/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java +++ b/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java -@@ -772,5 +772,15 @@ public class CraftBlock implements Block { +@@ -776,5 +776,15 @@ public class CraftBlock implements Block { public com.destroystokyo.paper.block.BlockSoundGroup getSoundGroup() { return new com.destroystokyo.paper.block.CraftBlockSoundGroup(getNMS().getBlock().defaultBlockState().getSoundType()); } diff --git a/patches/server/0522-Cache-block-data-strings.patch b/patches/server/0522-Cache-block-data-strings.patch index c7c201a261..5371382855 100644 --- a/patches/server/0522-Cache-block-data-strings.patch +++ b/patches/server/0522-Cache-block-data-strings.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Cache block data strings diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java -index 2c0b2bb254e9f4d39b526f170c11f481805d43d1..ffec95cde36b961545a3fe1bc5fc9f0cb1d38c65 100644 +index de2c21486f07bc2dbbaa9598354cd4ed39cb94ca..a183452adf5ca5c86fd9739ba776f4df87161426 100644 --- a/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java -@@ -2039,6 +2039,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop= level; } -@@ -1544,6 +1545,13 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n +@@ -1545,6 +1546,13 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n } public void moveTo(double x, double y, double z, float yaw, float pitch) { @@ -69,10 +69,10 @@ index b9e738542692aba7b78fc514ae8e3248df9998ea..c601b8b12756682a4cb300be8ebed431 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 33bcc85c438ef3eb5310321353e1bfdc6c63ae99..8ae4e824ecb5d039848e574d352c019935f7093f 100644 +index 17ad49994499982a08c1e8a4b4635647d669986a..187504b19f0194c700b5e498be191cf58b8d34ad 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java -@@ -565,7 +565,7 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity { +@@ -567,7 +567,7 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity { } // entity.setLocation() throws no event, and so cannot be cancelled diff --git a/patches/server/0528-Expose-the-Entity-Counter-to-allow-plugins-to-use-va.patch b/patches/server/0528-Expose-the-Entity-Counter-to-allow-plugins-to-use-va.patch index b5c16234f1..65dfec3a4e 100644 --- a/patches/server/0528-Expose-the-Entity-Counter-to-allow-plugins-to-use-va.patch +++ b/patches/server/0528-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 bdcdf3fc5f471d0a5db7f892537cfb596bf83136..6e0e4ff1ed9594d7f4fb9c78f7c02975c8741806 100644 +index bf1f22ee4e2a38b0fe2430dbeb20ae9f544ea423..eab21c1a6fb0b0a5d3ecbf6cf580a8fa9d0c6b4b 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -3934,4 +3934,10 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n +@@ -3935,4 +3935,10 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n void accept(Entity entity, double x, double y, double z); } diff --git a/patches/server/0530-Entity-isTicking.patch b/patches/server/0530-Entity-isTicking.patch index 298fda2053..277dd3c853 100644 --- a/patches/server/0530-Entity-isTicking.patch +++ b/patches/server/0530-Entity-isTicking.patch @@ -5,7 +5,7 @@ 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 6e0e4ff1ed9594d7f4fb9c78f7c02975c8741806..33eb15d2b42331808334bd584de7b15b035ae7ed 100644 +index eab21c1a6fb0b0a5d3ecbf6cf580a8fa9d0c6b4b..65f26b0d3fa43a09a9d20052f01aadc78206370b 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java @@ -52,6 +52,7 @@ import net.minecraft.resources.ResourceKey; @@ -16,7 +16,7 @@ index 6e0e4ff1ed9594d7f4fb9c78f7c02975c8741806..33eb15d2b42331808334bd584de7b15b import net.minecraft.server.level.ServerLevel; import net.minecraft.server.level.ServerPlayer; import net.minecraft.server.level.TicketType; -@@ -3939,5 +3940,9 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n +@@ -3940,5 +3941,9 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n public static int nextEntityId() { return ENTITY_COUNTER.incrementAndGet(); } @@ -27,10 +27,10 @@ index 6e0e4ff1ed9594d7f4fb9c78f7c02975c8741806..33eb15d2b42331808334bd584de7b15b // 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 8ae4e824ecb5d039848e574d352c019935f7093f..85ca30aef0703db6859e66c62781ecfd334426e7 100644 +index 187504b19f0194c700b5e498be191cf58b8d34ad..fd210462479ce869b769fae928b9b6f950f71007 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java -@@ -1220,5 +1220,9 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity { +@@ -1225,5 +1225,9 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity { public boolean isInLava() { return getHandle().isInLava(); } diff --git a/patches/server/0531-Fix-deop-kicking-non-whitelisted-player-when-white-l.patch b/patches/server/0531-Fix-deop-kicking-non-whitelisted-player-when-white-l.patch index 7a76efb155..93a57b6bf8 100644 --- a/patches/server/0531-Fix-deop-kicking-non-whitelisted-player-when-white-l.patch +++ b/patches/server/0531-Fix-deop-kicking-non-whitelisted-player-when-white-l.patch @@ -6,10 +6,10 @@ Subject: [PATCH] Fix deop kicking non-whitelisted player when white list is diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java -index ffec95cde36b961545a3fe1bc5fc9f0cb1d38c65..abc6ed89ffaa9c70a25265d1fee271ec841bc586 100644 +index a183452adf5ca5c86fd9739ba776f4df87161426..89507877b3a1c4305d09b7b2af611255c3481cfa 100644 --- a/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java -@@ -2105,6 +2105,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop implem +@@ -34,7 +34,7 @@ public class CraftBeacon extends CraftBlockEntityState implem if (tileEntity instanceof BeaconBlockEntity) { BeaconBlockEntity beacon = (BeaconBlockEntity) tileEntity; @@ -107,7 +107,7 @@ index 5abf219e86c6b4cf0c6b2e8ea72d7ed7b4f612e3..59a6a3d78d41d86c0e52510a2f81265d Collection bukkit = new ArrayList(nms.size()); for (Player human : nms) { -@@ -108,4 +108,21 @@ public class CraftBeacon extends CraftBlockEntityState implem +@@ -111,4 +111,21 @@ public class CraftBeacon extends CraftBlockEntityState implem public void setLock(String key) { this.getSnapshot().lockKey = (key == null) ? LockCode.NO_LOCK : new LockCode(key); } diff --git a/patches/server/0555-Expose-world-spawn-angle.patch b/patches/server/0555-Expose-world-spawn-angle.patch index a93a787688..a7a684d167 100644 --- a/patches/server/0555-Expose-world-spawn-angle.patch +++ b/patches/server/0555-Expose-world-spawn-angle.patch @@ -18,10 +18,10 @@ index 5188f62a581276847695cc457f6fe86d47ec2af5..523a6163c9ac3eadebdd185d291aad21 Player respawnPlayer = entityplayer1.getBukkitEntity(); diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -index 2bef1c8524944e0327260542a9ebed2d8aa854e0..fb82c861a457c07dfef0365fa56b4e2a8d2e1650 100644 +index 2ed3f753fe2e353815cc3201d2dc363639ca85f1..d556da8c2703746d8eff95b57fc41f9e6c21863d 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -@@ -378,7 +378,7 @@ public class CraftWorld implements World { +@@ -237,7 +237,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { @Override public Location getSpawnLocation() { BlockPos spawn = this.world.getSharedSpawnPos(); diff --git a/patches/server/0556-Add-Destroy-Speed-API.patch b/patches/server/0556-Add-Destroy-Speed-API.patch index be1109ffbd..1df49d8a14 100644 --- a/patches/server/0556-Add-Destroy-Speed-API.patch +++ b/patches/server/0556-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 9e5dce23121b4fc3e32f2b2702c0c6959dcd18cf..354ed68bad64277a9566d4dfdd8808260f145458 100644 +index 564aaa0c01a120ed9035e664702a32822dc3076e..ffbe3d5af03b5e6b6cf1fe6212f5a0f7396babb3 100644 --- a/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java +++ b/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java -@@ -782,5 +782,23 @@ public class CraftBlock implements Block { +@@ -786,5 +786,23 @@ public class CraftBlock implements Block { public String translationKey() { return org.bukkit.Bukkit.getUnsafe().getTranslationKey(this); } diff --git a/patches/server/0558-Add-LivingEntity-clearActiveItem.patch b/patches/server/0558-Add-LivingEntity-clearActiveItem.patch index 15a2a5d752..10e20b4163 100644 --- a/patches/server/0558-Add-LivingEntity-clearActiveItem.patch +++ b/patches/server/0558-Add-LivingEntity-clearActiveItem.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Add LivingEntity#clearActiveItem diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java -index b6f9dff2b634ca40fda6a9ed82cd472e29d1ce0d..904c864250b3f17f3840051a2e898ef74021e2ad 100644 +index d740442a054327d88c5fdda20d10b41a7d322f0e..eb97c5a8ffe6873bc16f852dd1bd5ded3cd9b3de 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java -@@ -778,6 +778,13 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity { +@@ -801,6 +801,13 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity { return getHandle().getUseItem().asBukkitMirror(); } diff --git a/patches/server/0561-Climbing-should-not-bypass-cramming-gamerule.patch b/patches/server/0561-Climbing-should-not-bypass-cramming-gamerule.patch index 3ddf1f8c76..6cc4f01429 100644 --- a/patches/server/0561-Climbing-should-not-bypass-cramming-gamerule.patch +++ b/patches/server/0561-Climbing-should-not-bypass-cramming-gamerule.patch @@ -5,7 +5,7 @@ Subject: [PATCH] Climbing should not bypass cramming gamerule diff --git a/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java b/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java -index 935bb237f8ecd63ca4cec64a7c7a341c9d3358e5..208690ceca2485b54acde5123ba494d71367791b 100644 +index 79229cb327e931443d23255720cb4d0716831c69..eb8d3d911f3fc5b6fc6ac892a95ae12e58d0540d 100644 --- a/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java +++ b/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java @@ -74,6 +74,11 @@ public class PaperWorldConfig { @@ -21,10 +21,10 @@ index 935bb237f8ecd63ca4cec64a7c7a341c9d3358e5..208690ceca2485b54acde5123ba494d7 private void keepLoadedRange() { keepLoadedRange = (short) (getInt("keep-spawn-loaded-range", Math.min(spigotConfig.viewDistance, 10)) * 16); diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index 33eb15d2b42331808334bd584de7b15b035ae7ed..025d4922142a5b24d69b93e7f5e0aaf7d2ec5719 100644 +index 65f26b0d3fa43a09a9d20052f01aadc78206370b..5ff6afc2a5fbf9f2bec34621d63a400e2acc1d63 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -1725,6 +1725,12 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n +@@ -1726,6 +1726,12 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n } public boolean isPushable() { diff --git a/patches/server/0568-MC-4-Fix-item-position-desync.patch b/patches/server/0568-MC-4-Fix-item-position-desync.patch index 36984bca8a..dd897574ac 100644 --- a/patches/server/0568-MC-4-Fix-item-position-desync.patch +++ b/patches/server/0568-MC-4-Fix-item-position-desync.patch @@ -41,10 +41,10 @@ index b30c08bfb8c55161543a4ef09f2e462e0a1fe4ae..ec93f5300cc7d423ec0d292f0f8443f9 public Vec3 updateEntityPosition(Vec3 orig) { diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index 025d4922142a5b24d69b93e7f5e0aaf7d2ec5719..7177f6af0f05ed35a6fec1cabdf10fc3512b97fa 100644 +index 5ff6afc2a5fbf9f2bec34621d63a400e2acc1d63..f0ca8889d9e020dd0c20ff35acadeeac35a0957e 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -3761,6 +3761,16 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n +@@ -3762,6 +3762,16 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n } public final void setPosRaw(double x, double y, double z, boolean forceBoundingBoxUpdate) { // Paper end diff --git a/patches/server/0571-Expose-LivingEntity-hurt-direction.patch b/patches/server/0571-Expose-LivingEntity-hurt-direction.patch index 3618755764..0646565914 100644 --- a/patches/server/0571-Expose-LivingEntity-hurt-direction.patch +++ b/patches/server/0571-Expose-LivingEntity-hurt-direction.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Expose LivingEntity hurt direction diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java -index 904c864250b3f17f3840051a2e898ef74021e2ad..ca74884ab4d671beede60f377906a843f5937861 100644 +index eb97c5a8ffe6873bc16f852dd1bd5ded3cd9b3de..7c8dba1c7d65b4b91eb5a83c029bc5b31750775f 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java -@@ -823,5 +823,15 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity { +@@ -846,5 +846,15 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity { public void playPickupItemAnimation(org.bukkit.entity.Item item, int quantity) { getHandle().take(((CraftItem) item).getHandle(), quantity); } diff --git a/patches/server/0576-Additional-Block-Material-API-s.patch b/patches/server/0576-Additional-Block-Material-API-s.patch index f64f7682d7..4961d7d1fe 100644 --- a/patches/server/0576-Additional-Block-Material-API-s.patch +++ b/patches/server/0576-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 354ed68bad64277a9566d4dfdd8808260f145458..ef3d93ba8b4149aa479abc6e9787a8746f60ce1d 100644 +index ffbe3d5af03b5e6b6cf1fe6212f5a0f7396babb3..b78c6bc81474024658857679f943e0bc5553edea 100644 --- a/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java +++ b/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java -@@ -618,6 +618,25 @@ public class CraftBlock implements Block { +@@ -622,6 +622,25 @@ public class CraftBlock implements Block { return this.getNMS().getMaterial().isLiquid(); } diff --git a/patches/server/0588-Added-WorldGameRuleChangeEvent.patch b/patches/server/0588-Added-WorldGameRuleChangeEvent.patch index 80c0fee433..aecdd554b6 100644 --- a/patches/server/0588-Added-WorldGameRuleChangeEvent.patch +++ b/patches/server/0588-Added-WorldGameRuleChangeEvent.patch @@ -64,10 +64,10 @@ index 888d812118c15c212284687ae5842a94f5715d52..e7ca5d6fb8922e7e8065864f736b0605 public int get() { diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -index fb82c861a457c07dfef0365fa56b4e2a8d2e1650..085c6b5252b9b7cf64ba186df72bf233c5b6a58e 100644 +index d556da8c2703746d8eff95b57fc41f9e6c21863d..636e63cf27a685710fd9915372b33f1c76f5b59c 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -@@ -2409,8 +2409,13 @@ public class CraftWorld implements World { +@@ -1717,8 +1717,13 @@ public class CraftWorld extends CraftRegionAccessor implements World { if (!this.isGameRule(rule)) return false; @@ -82,7 +82,7 @@ index fb82c861a457c07dfef0365fa56b4e2a8d2e1650..085c6b5252b9b7cf64ba186df72bf233 handle.onChanged(this.getHandle().getServer()); return true; } -@@ -2445,8 +2450,12 @@ public class CraftWorld implements World { +@@ -1753,8 +1758,12 @@ public class CraftWorld extends CraftRegionAccessor implements World { if (!this.isGameRule(rule.getName())) return false; diff --git a/patches/server/0589-Added-ServerResourcesReloadedEvent.patch b/patches/server/0589-Added-ServerResourcesReloadedEvent.patch index 935c9460fa..31b297c0bf 100644 --- a/patches/server/0589-Added-ServerResourcesReloadedEvent.patch +++ b/patches/server/0589-Added-ServerResourcesReloadedEvent.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Added ServerResourcesReloadedEvent diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java -index abc6ed89ffaa9c70a25265d1fee271ec841bc586..e6da0975b46ef7dbce4dd4025d5f27f990a310bf 100644 +index 89507877b3a1c4305d09b7b2af611255c3481cfa..9f471af9b0e0fe22ebd3b9a0e91b9c2718927d67 100644 --- a/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java -@@ -2018,7 +2018,13 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop completablefuture = CompletableFuture.supplyAsync(() -> { Stream stream = datapacks.stream(); // CraftBukkit - decompile error PackRepository resourcepackrepository = this.packRepository; -@@ -2034,6 +2040,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop) new CraftFluidTag(FluidTags.getAllTags(), key); diff --git a/patches/server/0616-EntityMoveEvent.patch b/patches/server/0616-EntityMoveEvent.patch index 50ed978030..94b9a87c32 100644 --- a/patches/server/0616-EntityMoveEvent.patch +++ b/patches/server/0616-EntityMoveEvent.patch @@ -5,10 +5,10 @@ Subject: [PATCH] EntityMoveEvent diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java -index e6da0975b46ef7dbce4dd4025d5f27f990a310bf..2309d2f307569070ebb4c9b388021c0130d4b168 100644 +index 9f471af9b0e0fe22ebd3b9a0e91b9c2718927d67..c22ad40718c63507c8fdc11a7bd1077abf254aa4 100644 --- a/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java -@@ -1526,6 +1526,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop 0; // Paper @@ -17,7 +17,7 @@ index e6da0975b46ef7dbce4dd4025d5f27f990a310bf..2309d2f307569070ebb4c9b388021c01 this.profiler.push(() -> { diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java -index 4223d4610b4fec588980dba2ea5ec4f04c45d945..fd2b301bda95438bc7e48173bbe74aec49595156 100644 +index 0acbd21f755ba805fd0aba68219e9c3849799375..5157d5f1d04d68446cd91507a314d727cce70c79 100644 --- a/src/main/java/net/minecraft/server/level/ServerLevel.java +++ b/src/main/java/net/minecraft/server/level/ServerLevel.java @@ -196,6 +196,7 @@ public class ServerLevel extends Level implements WorldGenLevel { diff --git a/patches/server/0621-living-entity-allow-attribute-registration.patch b/patches/server/0621-living-entity-allow-attribute-registration.patch index 5161d42b4f..6c6f1d7498 100644 --- a/patches/server/0621-living-entity-allow-attribute-registration.patch +++ b/patches/server/0621-living-entity-allow-attribute-registration.patch @@ -41,10 +41,10 @@ index 46c313d581b9af6aa0a48f97ae3cc800a88535f2..07d700382fc356837045c46d320b7b69 return net.minecraft.core.Registry.ATTRIBUTE.get(CraftNamespacedKey.toMinecraft(attribute.getKey())); } diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java -index ca74884ab4d671beede60f377906a843f5937861..495db8e1ab39a02bc2728b87101168cbca7676c2 100644 +index 7c8dba1c7d65b4b91eb5a83c029bc5b31750775f..88c0e80be343614947bfa3a14e08c5400a2d4ccc 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java -@@ -668,6 +668,13 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity { +@@ -686,6 +686,13 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity { return this.getHandle().craftAttributes.getAttribute(attribute); } diff --git a/patches/server/0624-misc-debugging-dumps.patch b/patches/server/0624-misc-debugging-dumps.patch index e40df07a3c..81a8a36690 100644 --- a/patches/server/0624-misc-debugging-dumps.patch +++ b/patches/server/0624-misc-debugging-dumps.patch @@ -29,10 +29,10 @@ index 0000000000000000000000000000000000000000..2d5494d2813b773e60ddba6790b750a9 + } +} diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java -index 2309d2f307569070ebb4c9b388021c0130d4b168..9feebee9c125642799cf8d3b22616db5ccd2a648 100644 +index c22ad40718c63507c8fdc11a7bd1077abf254aa4..0d3c1cdeab7a95bbac166c27758ed1b57946dfea 100644 --- a/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java -@@ -921,6 +921,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop impl +@@ -85,4 +85,10 @@ public class CraftBeehive extends CraftBlockEntityState impl getSnapshot().addOccupant(((CraftBee) entity).getHandle(), false); } diff --git a/patches/server/0679-Add-basic-Datapack-API.patch b/patches/server/0679-Add-basic-Datapack-API.patch index 004b3d92d2..604b3269e8 100644 --- a/patches/server/0679-Add-basic-Datapack-API.patch +++ b/patches/server/0679-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 210032209b3cdd2cda0e7463e3ee0e0228aa2c93..45ae98058d4207ccf9cc85fe27021356438a08fa 100644 +index eae363f7ea979782d2c3c787706dd8894c992c55..ae5cd5b5964fc66ded0de892e1d8b7074c0af7e6 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -275,6 +275,7 @@ public final class CraftServer implements Server { +@@ -281,6 +281,7 @@ public final class CraftServer implements Server { public boolean ignoreVanillaPermissions = false; private final List playerView; public int reloadCount; @@ -103,7 +103,7 @@ index 210032209b3cdd2cda0e7463e3ee0e0228aa2c93..45ae98058d4207ccf9cc85fe27021356 public static Exception excessiveVelEx; // Paper - Velocity warnings static { -@@ -357,6 +358,7 @@ public final class CraftServer implements Server { +@@ -363,6 +364,7 @@ public final class CraftServer implements Server { TicketType.PLUGIN.timeout = Math.min(20, this.configuration.getInt("chunk-gc.period-in-ticks")); // Paper - cap plugin loads to 1 second this.minimumAPI = this.configuration.getString("settings.minimum-api"); this.loadIcon(); @@ -111,7 +111,7 @@ index 210032209b3cdd2cda0e7463e3ee0e0228aa2c93..45ae98058d4207ccf9cc85fe27021356 } public boolean getCommandBlockOverride(String command) { -@@ -2578,5 +2580,11 @@ public final class CraftServer implements Server { +@@ -2637,5 +2639,11 @@ public final class CraftServer implements Server { public com.destroystokyo.paper.entity.ai.MobGoals getMobGoals() { return mobGoals; } diff --git a/patches/server/0683-More-Enchantment-API.patch b/patches/server/0683-More-Enchantment-API.patch index 2b7991e874..a5467298f2 100644 --- a/patches/server/0683-More-Enchantment-API.patch +++ b/patches/server/0683-More-Enchantment-API.patch @@ -64,10 +64,10 @@ index c536eceef3365a7b726cd970df345ba1d055207d..11c1eb0e0bc326b28dc0cab16f67c413 public net.minecraft.world.item.enchantment.Enchantment getHandle() { diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java -index 495db8e1ab39a02bc2728b87101168cbca7676c2..e91b055e46a2884d91a896366916de140d5ec20c 100644 +index 88c0e80be343614947bfa3a14e08c5400a2d4ccc..20e619baa4bce6a133ade5e5d6a6f04f49a1b176 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java -@@ -840,5 +840,21 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity { +@@ -863,5 +863,21 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity { public void setHurtDirection(float hurtDirection) { getHandle().hurtDir = hurtDirection; } diff --git a/patches/server/0684-Add-command-line-option-to-load-extra-plugin-jars-no.patch b/patches/server/0684-Add-command-line-option-to-load-extra-plugin-jars-no.patch index 245c5c84b2..2b6c503491 100644 --- a/patches/server/0684-Add-command-line-option-to-load-extra-plugin-jars-no.patch +++ b/patches/server/0684-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 45ae98058d4207ccf9cc85fe27021356438a08fa..85d078f7c0e5338315ba8290dd4981e59dbc7956 100644 +index ae5cd5b5964fc66ded0de892e1d8b7074c0af7e6..feb906cab3d1b121ed7dce113ea93cf438a93f69 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -394,8 +394,13 @@ public final class CraftServer implements Server { +@@ -400,8 +400,13 @@ public final class CraftServer implements Server { File pluginFolder = (File) console.options.valueOf("plugins"); @@ -26,7 +26,7 @@ index 45ae98058d4207ccf9cc85fe27021356438a08fa..85d078f7c0e5338315ba8290dd4981e5 for (Plugin plugin : plugins) { try { String message = String.format("Loading %s", plugin.getDescription().getFullName()); -@@ -410,6 +415,18 @@ public final class CraftServer implements Server { +@@ -416,6 +421,18 @@ public final class CraftServer implements Server { } } diff --git a/patches/server/0685-Fix-and-optimise-world-force-upgrading.patch b/patches/server/0685-Fix-and-optimise-world-force-upgrading.patch index f094f6a071..9bcfab5d6d 100644 --- a/patches/server/0685-Fix-and-optimise-world-force-upgrading.patch +++ b/patches/server/0685-Fix-and-optimise-world-force-upgrading.patch @@ -265,10 +265,10 @@ index cf0a74b8a1c31d4bc493eb09a69ee2bd94cb6485..cfd43069ee2b6f79afb12e10d223f6bf Main.LOGGER.info("Forcing world upgrade! {}", session.getLevelId()); // CraftBukkit WorldUpgrader worldupgrader = new WorldUpgrader(session, dataFixer, worlds, eraseCache); diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java -index 2399625457421a1c16d0f22a82cabe6e80ef9b43..f5f1b1741b08344a4247d096d60865cc267bd50f 100644 +index 14f45566d189fb1bff9c344116477f4df18e892a..e66f648b85ead0ab17cb57d9f33189043831d35b 100644 --- a/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java -@@ -559,13 +559,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop list = ImmutableList.of(new PhantomSpawner(), new PatrolSpawner(), new CatSpawner(), new VillageSiege(), new WanderingTraderSpawner(worlddata)); -@@ -1171,6 +1164,14 @@ public final class CraftServer implements Server { - chunkgenerator = worlddimension.generator(); +@@ -1194,6 +1187,14 @@ public final class CraftServer implements Server { + } } + // Paper start - fix and optimise world upgrading diff --git a/patches/server/0686-Add-Mob-lookAt-API.patch b/patches/server/0686-Add-Mob-lookAt-API.patch index b82033a43e..d65c61ac74 100644 --- a/patches/server/0686-Add-Mob-lookAt-API.patch +++ b/patches/server/0686-Add-Mob-lookAt-API.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Add Mob#lookAt API diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftMob.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftMob.java -index 317b6abd2764cf34ef5c42bdbf48ab0bc5a03d27..6549d7c40d6a0ca307fdcb6fd3ca01d2ab732b59 100644 +index e0022ea4bf228eef8384f20cfc717076c5ca5c99..2386edf499cb292241f6ba60c1cdb46f2fe704ff 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftMob.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftMob.java -@@ -83,5 +83,53 @@ public abstract class CraftMob extends CraftLivingEntity implements Mob { +@@ -86,5 +86,53 @@ public abstract class CraftMob extends CraftLivingEntity implements Mob { public boolean isInDaylight() { return getHandle().isSunBurnTick(); } diff --git a/patches/server/0691-Add-cause-to-Weather-ThunderChangeEvents.patch b/patches/server/0691-Add-cause-to-Weather-ThunderChangeEvents.patch index 481530bb85..3f07d5fa51 100644 --- a/patches/server/0691-Add-cause-to-Weather-ThunderChangeEvents.patch +++ b/patches/server/0691-Add-cause-to-Weather-ThunderChangeEvents.patch @@ -5,7 +5,7 @@ Subject: [PATCH] Add cause to Weather/ThunderChangeEvents diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java -index 192b9483a0b6d9129afc3a28fe69eb254a0fdf4c..9da2c0e52618afbfcaf5f7851fa0a5f85f0a12f3 100644 +index bec580b4523bdd1982e6668481e6cb9d2beb7137..7321e33cbc7d8e92ce4954eb1db8e7d5646d559b 100644 --- a/src/main/java/net/minecraft/server/level/ServerLevel.java +++ b/src/main/java/net/minecraft/server/level/ServerLevel.java @@ -386,8 +386,8 @@ public class ServerLevel extends Level implements WorldGenLevel { @@ -107,7 +107,7 @@ diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/jav index 48052de8a7a495743845f1610ed00cafb535bb89..696019dad030d6168a8794d5c5f21f94e58d9082 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -@@ -1457,7 +1457,7 @@ public class CraftWorld implements World { +@@ -1179,7 +1179,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { @Override public void setStorm(boolean hasStorm) { @@ -116,7 +116,7 @@ index 48052de8a7a495743845f1610ed00cafb535bb89..696019dad030d6168a8794d5c5f21f94 this.setWeatherDuration(0); // Reset weather duration (legacy behaviour) this.setClearWeatherDuration(0); // Reset clear weather duration (reset "/weather clear" commands) } -@@ -1479,7 +1479,7 @@ public class CraftWorld implements World { +@@ -1201,7 +1201,7 @@ public class CraftWorld extends CraftRegionAccessor implements World { @Override public void setThundering(boolean thundering) { diff --git a/patches/server/0692-More-Lidded-Block-API.patch b/patches/server/0692-More-Lidded-Block-API.patch index 6ab5311d9d..be136c7624 100644 --- a/patches/server/0692-More-Lidded-Block-API.patch +++ b/patches/server/0692-More-Lidded-Block-API.patch @@ -5,10 +5,10 @@ Subject: [PATCH] More Lidded Block API diff --git a/src/main/java/org/bukkit/craftbukkit/block/CraftBarrel.java b/src/main/java/org/bukkit/craftbukkit/block/CraftBarrel.java -index dcae26b698d31a8b0107b0f9757efa34f53b030a..c0e7ae7ae38d55088e1b6ae6c80b849fd740cb1a 100644 +index 2f3849135e5f335a6eef6e35cf40c8f93ac80124..ae7478b6de1b6e1812d081ec726130388e915337 100644 --- a/src/main/java/org/bukkit/craftbukkit/block/CraftBarrel.java +++ b/src/main/java/org/bukkit/craftbukkit/block/CraftBarrel.java -@@ -59,4 +59,11 @@ public class CraftBarrel extends CraftLootable implements Bar +@@ -63,4 +63,11 @@ public class CraftBarrel extends CraftLootable implements Bar } getTileEntity().openersCounter.opened = false; } @@ -21,10 +21,10 @@ index dcae26b698d31a8b0107b0f9757efa34f53b030a..c0e7ae7ae38d55088e1b6ae6c80b849f + // Paper end - More Lidded Block API } diff --git a/src/main/java/org/bukkit/craftbukkit/block/CraftChest.java b/src/main/java/org/bukkit/craftbukkit/block/CraftChest.java -index 79edaefe8f6c027b5ad67c6bdcc0bb84a0582887..3b90bee227ebfc1b6436319d002b5fd35e4eeda8 100644 +index 4d84bcdfb17a3d1bc79e5ec2b201739fa0db1bd3..bac6385f99d7475c627d69cde972f5a92ab57f4b 100644 --- a/src/main/java/org/bukkit/craftbukkit/block/CraftChest.java +++ b/src/main/java/org/bukkit/craftbukkit/block/CraftChest.java -@@ -79,4 +79,11 @@ public class CraftChest extends CraftLootable implements Chest +@@ -82,4 +82,11 @@ public class CraftChest extends CraftLootable implements Chest } getTileEntity().openersCounter.opened = false; } @@ -75,11 +75,11 @@ index 25add8bee6ea35beeb205dd828759304346e4f48..599f6747dfa140e40fef26ed4d8244bf + // Paper end - More Lidded Block API } diff --git a/src/main/java/org/bukkit/craftbukkit/block/CraftShulkerBox.java b/src/main/java/org/bukkit/craftbukkit/block/CraftShulkerBox.java -index 60f2394547153b2d2553fb88470a00ff99ac2f2d..f3f95aaac02007b5f67ba64df1b5b9b7e82e3325 100644 +index 87395e1000dda3063dcdbc01c9e874ede2ccf5d9..35b05ff905de0f102a60ed3fcf9996fab1f047a6 100644 --- a/src/main/java/org/bukkit/craftbukkit/block/CraftShulkerBox.java +++ b/src/main/java/org/bukkit/craftbukkit/block/CraftShulkerBox.java @@ -61,8 +61,15 @@ public class CraftShulkerBox extends CraftLootable implem - if (getTileEntity().opened) { + if (getTileEntity().opened && getWorldHandle() instanceof net.minecraft.world.level.Level) { Level world = getTileEntity().getLevel(); world.blockEvent(getPosition(), getTileEntity().getBlockState().getBlock(), 1, 0); - world.playSound(null, getPosition(), SoundEvents.SHULKER_BOX_OPEN, SoundSource.BLOCKS, 0.5F, world.random.nextFloat() * 0.1F + 0.9F); diff --git a/patches/server/0695-Add-PlayerKickEvent-causes.patch b/patches/server/0695-Add-PlayerKickEvent-causes.patch index f70458287a..1ac7ea4e81 100644 --- a/patches/server/0695-Add-PlayerKickEvent-causes.patch +++ b/patches/server/0695-Add-PlayerKickEvent-causes.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Add PlayerKickEvent causes diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java -index f5f1b1741b08344a4247d096d60865cc267bd50f..3dded5c491ace6b073a7bc3178976bd70f0b9393 100644 +index e66f648b85ead0ab17cb57d9f33189043831d35b..25c3a96ca88494650d93efcaeecf5ae08ed0810f 100644 --- a/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java -@@ -2126,7 +2126,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop type, Level world) { this.id = Entity.ENTITY_COUNTER.incrementAndGet(); this.passengers = ImmutableList.of(); -@@ -2513,6 +2544,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n +@@ -2514,6 +2545,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n } this.processPortalCooldown(); diff --git a/patches/server/0705-Line-Of-Sight-Changes.patch b/patches/server/0705-Line-Of-Sight-Changes.patch index 6a12efa4cf..a891a71271 100644 --- a/patches/server/0705-Line-Of-Sight-Changes.patch +++ b/patches/server/0705-Line-Of-Sight-Changes.patch @@ -22,7 +22,7 @@ diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/jav index 696019dad030d6168a8794d5c5f21f94e58d9082..6f0334f5162087eff0c64c9bdd47ff6b34a481b7 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -@@ -331,6 +331,18 @@ public class CraftWorld implements World { +@@ -189,6 +189,18 @@ public class CraftWorld extends CraftRegionAccessor implements World { public io.papermc.paper.world.MoonPhase getMoonPhase() { return io.papermc.paper.world.MoonPhase.getPhase(getFullTime() / 24000L); } @@ -42,7 +42,7 @@ index 696019dad030d6168a8794d5c5f21f94e58d9082..6f0334f5162087eff0c64c9bdd47ff6b private static final Random rand = new Random(); diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java -index e91b055e46a2884d91a896366916de140d5ec20c..f9110f682ddc356299ff94e1e536f8e5024378d8 100644 +index 20e619baa4bce6a133ade5e5d6a6f04f49a1b176..1c684244213d04b36589dd50ea66052a9cdad072 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; @@ -55,7 +55,7 @@ index e91b055e46a2884d91a896366916de140d5ec20c..f9110f682ddc356299ff94e1e536f8e5 import org.apache.commons.lang.Validate; import org.bukkit.FluidCollisionMode; import org.bukkit.Location; -@@ -541,6 +544,18 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity { +@@ -557,6 +560,18 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity { return this.getHandle().hasLineOfSight(((CraftEntity) other).getHandle()); } diff --git a/patches/server/0706-add-per-world-spawn-limits.patch b/patches/server/0706-add-per-world-spawn-limits.patch index dbaccb684d..f9a2915b63 100644 --- a/patches/server/0706-add-per-world-spawn-limits.patch +++ b/patches/server/0706-add-per-world-spawn-limits.patch @@ -33,8 +33,8 @@ diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/jav index 6f0334f5162087eff0c64c9bdd47ff6b34a481b7..9d7fc426710183f12f5a8606bef459040d4b33bc 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -@@ -352,6 +352,13 @@ public class CraftWorld implements World { - this.generator = gen; +@@ -211,6 +211,13 @@ public class CraftWorld extends CraftRegionAccessor implements World { + this.biomeProvider = biomeProvider; this.environment = env; + // Paper start - per world spawn limits diff --git a/patches/server/0709-Add-Feature-Generation-API.patch b/patches/server/0709-Add-Feature-Generation-API.patch index 3759ec2d49..c5424f59f0 100644 --- a/patches/server/0709-Add-Feature-Generation-API.patch +++ b/patches/server/0709-Add-Feature-Generation-API.patch @@ -126,12 +126,12 @@ index 0000000000000000000000000000000000000000..69b17fe56f28f8978abc3f363a9e805d +} + diff --git a/src/main/java/org/bukkit/craftbukkit/generator/CustomChunkGenerator.java b/src/main/java/org/bukkit/craftbukkit/generator/CustomChunkGenerator.java -index fc342d2f74077f8f102c731e12f27fc6f2c1bcd4..d333812188b24f228d7d3329da24cba2c9e00e6c 100644 +index 98461949badc8a708c1e7e2f225a93e8d1ca5822..4fa8cce0818a8e461330fc29021e6ff65cb67125 100644 --- a/src/main/java/org/bukkit/craftbukkit/generator/CustomChunkGenerator.java +++ b/src/main/java/org/bukkit/craftbukkit/generator/CustomChunkGenerator.java -@@ -204,6 +204,12 @@ public class CustomChunkGenerator extends InternalChunkGenerator { - if (this.generator.shouldGenerateDecorations()) { - this.delegate.applyBiomeDecoration(region, accessor); +@@ -187,6 +187,12 @@ public class CustomChunkGenerator extends InternalChunkGenerator { + for (BlockPos lightPosition : craftData.getLights()) { + ((ProtoChunk) chunk).addLight(new BlockPos((x << 4) + lightPosition.getX(), lightPosition.getY(), (z << 4) + lightPosition.getZ())); // PAIL rename addLightBlock } + + // Paper start diff --git a/patches/server/0716-Fix-return-value-of-Block-applyBoneMeal-always-being.patch b/patches/server/0716-Fix-return-value-of-Block-applyBoneMeal-always-being.patch index c9cf7f3390..33b6869585 100644 --- a/patches/server/0716-Fix-return-value-of-Block-applyBoneMeal-always-being.patch +++ b/patches/server/0716-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 0b909c0e2137250895b17a0fb5da0c188c402fe1..f20484b74197353adec0a3cd2c42f88aa9fdd4e6 100644 +index 207e6ad42a32396b2b43e1782297e1837ce94d7d..a53a9974a2358fa4b6a7216e4b849bd3ad5023ea 100644 --- a/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java +++ b/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java -@@ -677,7 +677,7 @@ public class CraftBlock implements Block { +@@ -681,7 +681,7 @@ public class CraftBlock implements Block { Direction direction = CraftBlock.blockFaceToNotch(face); UseOnContext context = new UseOnContext(this.getCraftWorld().getHandle(), null, InteractionHand.MAIN_HAND, Items.BONE_MEAL.getDefaultInstance(), new BlockHitResult(Vec3.ZERO, direction, this.getPosition(), false)); diff --git a/patches/server/0727-Stinger-API.patch b/patches/server/0727-Stinger-API.patch index 230a8cc053..bfc4b49704 100644 --- a/patches/server/0727-Stinger-API.patch +++ b/patches/server/0727-Stinger-API.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Stinger API diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java -index f9110f682ddc356299ff94e1e536f8e5024378d8..646ea844ed2cf674569937653f9920e4fdbf62a0 100644 +index 1c684244213d04b36589dd50ea66052a9cdad072..fe71123dc07cb13ffad8f13e57aa9bda1cb0abf5 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java -@@ -311,7 +311,28 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity { +@@ -321,7 +321,28 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity { Preconditions.checkArgument(count >= 0, "New arrow amount must be >= 0"); this.getHandle().getEntityData().set(net.minecraft.world.entity.LivingEntity.DATA_ARROW_COUNT_ID, count); } diff --git a/patches/server/0729-Add-System.out-err-catcher.patch b/patches/server/0729-Add-System.out-err-catcher.patch index 692d2e41b1..1c0a1c5172 100644 --- a/patches/server/0729-Add-System.out-err-catcher.patch +++ b/patches/server/0729-Add-System.out-err-catcher.patch @@ -105,7 +105,7 @@ index 0000000000000000000000000000000000000000..88608afed45f25f822121214f87e9f9b + } +} diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 9954e45c32a4b6d80fe912ed9d55cd4fc8c4e98b..6d7f16fede01c19f638e1dcdae8b07b79cd86dc0 100644 +index ea9f97bc5196a26ae5caaf48fa846bf92e8f6188..41255bc4c03a02e76fbfc3b0b34c907fb3ad05b1 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java @@ -18,6 +18,7 @@ import com.mojang.serialization.Lifecycle; @@ -116,7 +116,7 @@ index 9954e45c32a4b6d80fe912ed9d55cd4fc8c4e98b..6d7f16fede01c19f638e1dcdae8b07b7 import it.unimi.dsi.fastutil.objects.Object2ObjectLinkedOpenHashMap; import java.awt.image.BufferedImage; import java.io.File; -@@ -277,6 +278,7 @@ public final class CraftServer implements Server { +@@ -283,6 +284,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/0736-Make-hoppers-respect-inventory-max-stack-size.patch b/patches/server/0736-Make-hoppers-respect-inventory-max-stack-size.patch index 38272e42b2..b296ea90eb 100644 --- a/patches/server/0736-Make-hoppers-respect-inventory-max-stack-size.patch +++ b/patches/server/0736-Make-hoppers-respect-inventory-max-stack-size.patch @@ -5,26 +5,11 @@ Subject: [PATCH] Make hoppers respect inventory max stack size diff --git a/src/main/java/net/minecraft/world/level/block/entity/HopperBlockEntity.java b/src/main/java/net/minecraft/world/level/block/entity/HopperBlockEntity.java -index 3b1442bf4c83650369e925d76f07dc67c6cbbc83..a3f0e2ab3eeebeb7c43fda3ddb1f16f8696255d3 100644 +index 08c4a0996410a42418d4a5da3ed1f4db2f171dd2..d41851f9119c334cae3fc2c433d6450a3eed9096 100644 --- a/src/main/java/net/minecraft/world/level/block/entity/HopperBlockEntity.java +++ b/src/main/java/net/minecraft/world/level/block/entity/HopperBlockEntity.java -@@ -588,13 +588,22 @@ public class HopperBlockEntity extends RandomizableContainerBlockEntity implemen - boolean flag1 = to.isEmpty(); - - if (itemstack1.isEmpty()) { -+ int originalCount = stack.getCount(); // Paper -+ stack.setCount(Math.min(to.getMaxStackSize(), stack.getCount())); // Paper - IGNORE_TILE_UPDATES = true; // Paper - to.setItem(slot, stack); - IGNORE_TILE_UPDATES = false; // Paper -+ if (originalCount - stack.getCount() == 0) { // Paper +@@ -599,7 +599,7 @@ public class HopperBlockEntity extends RandomizableContainerBlockEntity implemen stack = ItemStack.EMPTY; -+ // Paper start -+ } else { -+ stack = stack.copy(); // Paper - copy stack to return leftover stack -+ stack.setCount(originalCount - stack.getCount()); -+ } -+ // Paper end flag = true; } else if (HopperBlockEntity.canMergeItems(itemstack1, stack)) { - int j = stack.getMaxStackSize() - itemstack1.getCount(); diff --git a/patches/server/0740-Optimize-indirect-passenger-iteration.patch b/patches/server/0740-Optimize-indirect-passenger-iteration.patch index 0cdd6612ef..b791bea914 100644 --- a/patches/server/0740-Optimize-indirect-passenger-iteration.patch +++ b/patches/server/0740-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 f9b88b9d157af8ba7a3501e09ee27631d901407d..cdec0668ecbf9dea2551101cc3054dcc398d282a 100644 +index 225a277e5f327b974ae932ab55117aeb9a230a0d..b129e8a46d1ad2a13f63c841e6edfb61638fc5e2 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -3477,26 +3477,41 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n +@@ -3478,26 +3478,41 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n } private Stream getIndirectPassengersStream() { diff --git a/patches/server/0746-Do-not-fire-PlayerBucketFillEvent-when-no-fluid.patch b/patches/server/0746-Do-not-fire-PlayerBucketFillEvent-when-no-fluid.patch deleted file mode 100644 index dad920ef4f..0000000000 --- a/patches/server/0746-Do-not-fire-PlayerBucketFillEvent-when-no-fluid.patch +++ /dev/null @@ -1,18 +0,0 @@ -From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 -From: Shane Freeder -Date: Tue, 17 Aug 2021 15:42:21 +0100 -Subject: [PATCH] Do not fire PlayerBucketFillEvent when no fluid - - -diff --git a/src/main/java/net/minecraft/world/item/BucketItem.java b/src/main/java/net/minecraft/world/item/BucketItem.java -index 4fdb99240e6ebda946fd2e0a847654d92b7c56a1..fb25e1107db0a01b0803af031c117e57e03dc5c1 100644 ---- a/src/main/java/net/minecraft/world/item/BucketItem.java -+++ b/src/main/java/net/minecraft/world/item/BucketItem.java -@@ -73,6 +73,7 @@ public class BucketItem extends Item implements DispensibleContainerItem { - BucketPickup ifluidsource = (BucketPickup) iblockdata.getBlock(); - // CraftBukkit start - ItemStack dummyFluid = ifluidsource.pickupBlock(DummyGeneratorAccess.INSTANCE, blockposition, iblockdata); -+ if (dummyFluid.isEmpty()) return InteractionResultHolder.fail(itemstack); // Paper - PlayerBucketFillEvent event = CraftEventFactory.callPlayerBucketFillEvent((ServerLevel) world, user, blockposition, blockposition, movingobjectpositionblock.getDirection(), itemstack, dummyFluid.getItem(), hand); // Paper - add enumhand - - if (event.isCancelled()) { diff --git a/patches/server/0747-Set-AsyncAppender-dispatch-thread-to-be-a-daemon-thr.patch b/patches/server/0746-Set-AsyncAppender-dispatch-thread-to-be-a-daemon-thr.patch similarity index 100% rename from patches/server/0747-Set-AsyncAppender-dispatch-thread-to-be-a-daemon-thr.patch rename to patches/server/0746-Set-AsyncAppender-dispatch-thread-to-be-a-daemon-thr.patch diff --git a/patches/server/0748-Respect-despawn-rate-in-item-merge-check.patch b/patches/server/0747-Respect-despawn-rate-in-item-merge-check.patch similarity index 100% rename from patches/server/0748-Respect-despawn-rate-in-item-merge-check.patch rename to patches/server/0747-Respect-despawn-rate-in-item-merge-check.patch diff --git a/patches/server/0749-Move-BlockPistonRetractEvent-to-fix-duplication.patch b/patches/server/0748-Move-BlockPistonRetractEvent-to-fix-duplication.patch similarity index 100% rename from patches/server/0749-Move-BlockPistonRetractEvent-to-fix-duplication.patch rename to patches/server/0748-Move-BlockPistonRetractEvent-to-fix-duplication.patch diff --git a/patches/server/0750-Change-EnderEye-target-without-changing-other-things.patch b/patches/server/0749-Change-EnderEye-target-without-changing-other-things.patch similarity index 100% rename from patches/server/0750-Change-EnderEye-target-without-changing-other-things.patch rename to patches/server/0749-Change-EnderEye-target-without-changing-other-things.patch diff --git a/patches/server/0751-Fix-bed-handling-for-custom-dimensions.patch b/patches/server/0750-Fix-bed-handling-for-custom-dimensions.patch similarity index 100% rename from patches/server/0751-Fix-bed-handling-for-custom-dimensions.patch rename to patches/server/0750-Fix-bed-handling-for-custom-dimensions.patch diff --git a/patches/server/0752-Add-BlockBreakBlockEvent.patch b/patches/server/0751-Add-BlockBreakBlockEvent.patch similarity index 100% rename from patches/server/0752-Add-BlockBreakBlockEvent.patch rename to patches/server/0751-Add-BlockBreakBlockEvent.patch diff --git a/work/Bukkit b/work/Bukkit index 974452512a..ca5b4b1ae6 160000 --- a/work/Bukkit +++ b/work/Bukkit @@ -1 +1 @@ -Subproject commit 974452512a4638f2692cc7baff5baf77401349ba +Subproject commit ca5b4b1ae6c3d22ce76f57bec97d298c8914c466 diff --git a/work/CraftBukkit b/work/CraftBukkit index 61e4ca7b9e..a0a37f416c 160000 --- a/work/CraftBukkit +++ b/work/CraftBukkit @@ -1 +1 @@ -Subproject commit 61e4ca7b9e7dbc0ee899140a7b194248edc3f493 +Subproject commit a0a37f416ca6c9be007f65e1b8ef5efea9b50cb5 diff --git a/work/Spigot b/work/Spigot index ff89b973e6..3c1fc60ae7 160000 --- a/work/Spigot +++ b/work/Spigot @@ -1 +1 @@ -Subproject commit ff89b973e62ca3b6085aeeb474f2568e45ac02be +Subproject commit 3c1fc60ae715a3007908fd34968f5acdf482a46a