From 9c83387157327c1c1e9aa0caf7ac84636ae488bb Mon Sep 17 00:00:00 2001 From: Bjarne Koll Date: Fri, 25 Oct 2024 13:19:23 +0200 Subject: [PATCH] Compile issues 1 --- ...70-Fix-Per-World-Difficulty-Remembering-Difficulty.patch | 4 ++-- patches/server/0403-Cache-block-data-strings.patch | 2 +- ...x-deop-kicking-non-whitelisted-player-when-white-l.patch | 2 +- patches/server/0457-Add-ServerResourcesReloadedEvent.patch | 2 +- patches/server/0480-Add-EntityMoveEvent.patch | 2 +- ...499-forced-whitelist-use-configurable-kick-message.patch | 2 +- patches/server/0512-More-World-API.patch | 4 ++-- .../0536-Add-cause-to-Weather-ThunderChangeEvents.patch | 2 +- patches/server/0539-Add-PlayerKickEvent-causes.patch | 2 +- patches/server/0549-add-per-world-spawn-limits.patch | 2 +- ...-Add-methods-to-find-targets-for-lightning-strikes.patch | 2 +- patches/server/0593-Improve-and-expand-AsyncCatcher.patch | 2 +- .../0594-Add-paper-mobcaps-and-paper-playermobcaps.patch | 2 +- ...0611-Prevent-softlocked-end-exit-portal-generation.patch | 6 +++--- .../0642-Expose-vanilla-BiomeProvider-from-WorldInfo.patch | 4 ++-- patches/server/0658-Add-GameEvent-tags.patch | 6 +++--- ...ecute-chunk-tasks-fairly-for-worlds-while-waiting-.patch | 2 +- ...tion-to-have-default-CustomSpawners-in-custom-worl.patch | 2 +- ...-Put-world-into-worldlist-before-initing-the-world.patch | 4 ++-- patches/server/0665-Custom-Potion-Mixes.patch | 4 ++-- patches/server/0667-Fix-falling-block-spawn-methods.patch | 2 +- patches/server/0676-Fix-saving-in-unloadWorld.patch | 2 +- patches/server/0688-WorldCreator-keepSpawnLoaded.patch | 2 +- ...Throw-exception-on-world-create-while-being-ticked.patch | 4 ++-- .../0709-Don-t-broadcast-messages-to-command-blocks.patch | 2 +- .../0721-Warn-on-plugins-accessing-faraway-chunks.patch | 2 +- patches/server/0726-Block-Ticking-API.patch | 4 ++-- .../server/0727-Add-Velocity-IP-Forwarding-Support.patch | 2 +- .../server/0729-Fix-plugin-loggers-on-server-shutdown.patch | 2 +- .../0758-ensure-reset-EnderDragon-boss-event-name.patch | 2 +- .../0767-Fix-premature-player-kicks-on-shutdown.patch | 2 +- ...n-t-enforce-icanhasbukkit-default-if-alias-block-e.patch | 2 +- .../server/0837-Folia-scheduler-and-owned-region-API.patch | 4 ++-- patches/server/0840-Only-capture-actual-tree-growth.patch | 2 +- .../server/0843-Use-correct-seed-on-api-world-load.patch | 2 +- patches/server/0847-Bandaid-fix-for-Effect.patch | 2 +- ...precate-and-replace-methods-with-old-StructureType.patch | 2 +- patches/server/0860-More-DragonBattle-API.patch | 2 +- ...-crystal-portal-proximity-check-before-entity-look.patch | 2 +- .../0891-Add-predicate-for-blocks-when-raytracing.patch | 2 +- ...x-strikeLightningEffect-powers-lightning-rods-and-.patch | 2 +- patches/server/0901-Add-Structure-check-API.patch | 2 +- ...Properly-handle-experience-dropping-on-block-break.patch | 2 +- patches/server/0919-Add-Lifecycle-Event-system.patch | 2 +- patches/server/0924-improve-BanList-types.patch | 2 +- patches/server/0929-More-Raid-API.patch | 2 +- ...30-Add-onboarding-message-for-initial-server-start.patch | 2 +- patches/server/0957-Brigadier-based-command-API.patch | 4 ++-- patches/server/0980-Anti-Xray.patch | 4 ++-- patches/server/0984-Optimize-Hoppers.patch | 2 +- patches/server/1021-Add-FeatureFlag-API.patch | 2 +- patches/server/1022-Tag-Lifecycle-Events.patch | 2 +- patches/server/1033-Void-damage-configuration-API.patch | 2 +- 53 files changed, 67 insertions(+), 67 deletions(-) diff --git a/patches/server/0370-Fix-Per-World-Difficulty-Remembering-Difficulty.patch b/patches/server/0370-Fix-Per-World-Difficulty-Remembering-Difficulty.patch index 3be0b64188..06d3e294ce 100644 --- a/patches/server/0370-Fix-Per-World-Difficulty-Remembering-Difficulty.patch +++ b/patches/server/0370-Fix-Per-World-Difficulty-Remembering-Difficulty.patch @@ -8,7 +8,7 @@ makes it so that the server keeps the last difficulty used instead of restoring the server.properties every single load. diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java -index b4eff440e3d9489f99e10a73611421ef877aa871..9109628a48026ceca9dd53a3e75f79510e56c95c 100644 +index b4eff440e3d9489f99e10a73611421ef877aa871..4af87078b6d7fd733d0e4094af2e7cce029c19d3 100644 --- a/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java @@ -852,7 +852,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop { + Preconditions.checkArgument(clazz == org.bukkit.GameEvent.class, "Game Event namespace must have GameEvent type"); + TagKey gameEventTagKey = TagKey.create(net.minecraft.core.registries.Registries.GAME_EVENT, key); -+ if (net.minecraft.core.registries.BuiltInRegistries.GAME_EVENT.getTag(gameEventTagKey).isPresent()) { ++ if (net.minecraft.core.registries.BuiltInRegistries.GAME_EVENT.get(gameEventTagKey).isPresent()) { + return (org.bukkit.Tag) new io.papermc.paper.CraftGameEventTag(net.minecraft.core.registries.BuiltInRegistries.GAME_EVENT, gameEventTagKey); + } + } @@ -73,7 +73,7 @@ index 8d9816f84e551f1257972f467352e9c9ee09473e..b18ad8abb5e3c53b0e13544a6833198a + case org.bukkit.Tag.REGISTRY_GAME_EVENTS -> { + Preconditions.checkArgument(clazz == org.bukkit.GameEvent.class); + net.minecraft.core.Registry gameEvents = net.minecraft.core.registries.BuiltInRegistries.GAME_EVENT; -+ return gameEvents.getTags().map(pair -> (org.bukkit.Tag) new io.papermc.paper.CraftGameEventTag(gameEvents, pair.getFirst())).collect(ImmutableList.toImmutableList()); ++ return gameEvents.getTags().map(pair -> (org.bukkit.Tag) new io.papermc.paper.CraftGameEventTag(gameEvents, pair.key())).collect(ImmutableList.toImmutableList()); + } + // Paper end default -> throw new IllegalArgumentException(); diff --git a/patches/server/0659-Execute-chunk-tasks-fairly-for-worlds-while-waiting-.patch b/patches/server/0659-Execute-chunk-tasks-fairly-for-worlds-while-waiting-.patch index b3d65b12d0..02d3260ae3 100644 --- a/patches/server/0659-Execute-chunk-tasks-fairly-for-worlds-while-waiting-.patch +++ b/patches/server/0659-Execute-chunk-tasks-fairly-for-worlds-while-waiting-.patch @@ -9,7 +9,7 @@ This might result in chunks loading far slower in the nether, for example. diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java -index 15382d7da69967c50007f136e9d17dd2f81166e3..af392711da61a1921be1f82396c2a04dc897d563 100644 +index 7e85d9e00f41abb26fbf0e21e70ab82018f6f2a6..12a3480823722cd907654248ae2a977ca3f7bb0f 100644 --- a/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java @@ -1419,6 +1419,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop(Lnet/minecraft/world/level/Level;DDDLnet/minecraft/world/level/block/state/BlockState;)V diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -index 7dc167950021371b5cf8a7e1e38f013220e1c8a6..9ea74d52112ab4feea3f4bafd82351a72088cbc5 100644 +index da761980a12dc08ca77dadc8773b4467a48637f9..4bcd91f946dd6157a345ae8e7d049bff051911b3 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java @@ -1405,7 +1405,12 @@ public class CraftWorld extends CraftRegionAccessor implements World { diff --git a/patches/server/0676-Fix-saving-in-unloadWorld.patch b/patches/server/0676-Fix-saving-in-unloadWorld.patch index d5a0b6e7c7..f2d01904b1 100644 --- a/patches/server/0676-Fix-saving-in-unloadWorld.patch +++ b/patches/server/0676-Fix-saving-in-unloadWorld.patch @@ -6,7 +6,7 @@ Subject: [PATCH] Fix saving in unloadWorld Change savingDisabled to false to ensure ServerLevel's saving logic gets called when unloadWorld is called with save = true diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index f0eb8284b537014b591e45f034f1498e7e687e54..cc08b56da8a276202da3e85315fdb2ad530c2545 100644 +index b3e5fc3a417be2af8ed6591f67f8d56c4ca86d74..2860aa8f75ec5901023f88047cb4cb96298a99e0 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java @@ -1386,7 +1386,7 @@ public final class CraftServer implements Server { diff --git a/patches/server/0688-WorldCreator-keepSpawnLoaded.patch b/patches/server/0688-WorldCreator-keepSpawnLoaded.patch index 0e11daefe3..2b6c3f2d6e 100644 --- a/patches/server/0688-WorldCreator-keepSpawnLoaded.patch +++ b/patches/server/0688-WorldCreator-keepSpawnLoaded.patch @@ -5,7 +5,7 @@ Subject: [PATCH] WorldCreator#keepSpawnLoaded diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index cc08b56da8a276202da3e85315fdb2ad530c2545..b31f3013ff63bb6ece80a9d10e51641a7e93f3df 100644 +index 2860aa8f75ec5901023f88047cb4cb96298a99e0..d0a72476d36294792550425a8c0646a7c0be75a7 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java @@ -1329,7 +1329,7 @@ public final class CraftServer implements Server { diff --git a/patches/server/0703-Throw-exception-on-world-create-while-being-ticked.patch b/patches/server/0703-Throw-exception-on-world-create-while-being-ticked.patch index a447e15d32..b9e8b476fa 100644 --- a/patches/server/0703-Throw-exception-on-world-create-while-being-ticked.patch +++ b/patches/server/0703-Throw-exception-on-world-create-while-being-ticked.patch @@ -7,7 +7,7 @@ There are no plans to support creating worlds while worlds are being ticked themselvess. diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java -index 9765951d0ed653ca5b4ae4903887ec7ef25cb50a..8030baa8ef189a17502da9c51baace0b7369137b 100644 +index 46495bf3b04187b4cf945f37f128a06aceb83eb7..fe8c05e51b8e4620a10590aaa24017f205466fca 100644 --- a/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java @@ -328,6 +328,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop getDrops(LootParams.Builder builder) { diff --git a/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java b/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java -index a34e888f63ead250c41b6bbe6850a5e5b4254c3d..66ac5d0b6dafd0323b73953cdd633dca624c3bcd 100644 +index 6dceb6082538df6f6147254e861d1cec8af7ec50..5cb69d0b822e11a99a96aef4f59986d083b079f4 100644 --- a/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java +++ b/src/main/java/org/bukkit/craftbukkit/block/CraftBlock.java @@ -509,7 +509,7 @@ public class CraftBlock implements Block { diff --git a/patches/server/0919-Add-Lifecycle-Event-system.patch b/patches/server/0919-Add-Lifecycle-Event-system.patch index fe8a2a22de..e2eaeec2f9 100644 --- a/patches/server/0919-Add-Lifecycle-Event-system.patch +++ b/patches/server/0919-Add-Lifecycle-Event-system.patch @@ -727,7 +727,7 @@ index 2e96308696e131f3f013469a395e5ddda2c5d529..65a66e484c1c39c5f41d97db52f31c67 } catch (Throwable e) { LOGGER.error("Failed to run bootstrapper for %s. This plugin will not be loaded.".formatted(provider.getSource()), e); diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 2934e232c84603224470fdaba0103d42fc06e8b4..4dc64ab006399d62251f4a238d9c2caebd595301 100644 +index dbdf52a306d7018f0bf01fcf6c24a6d1dc269be5..fb55dced981d16a82e4cc233fbf25695850a1b99 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java @@ -1051,6 +1051,11 @@ public final class CraftServer implements Server { diff --git a/patches/server/0924-improve-BanList-types.patch b/patches/server/0924-improve-BanList-types.patch index 24c44ced87..1b56c10b04 100644 --- a/patches/server/0924-improve-BanList-types.patch +++ b/patches/server/0924-improve-BanList-types.patch @@ -5,7 +5,7 @@ Subject: [PATCH] improve BanList types diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 4dc64ab006399d62251f4a238d9c2caebd595301..97850b3111dfa86d15186fa200937b28bec428de 100644 +index fb55dced981d16a82e4cc233fbf25695850a1b99..82a85a4e2dd58d22e6aad797e4bd8f7c5b355caf 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java @@ -2223,6 +2223,21 @@ public final class CraftServer implements Server { diff --git a/patches/server/0929-More-Raid-API.patch b/patches/server/0929-More-Raid-API.patch index 6e3632dd09..daaeb2bdea 100644 --- a/patches/server/0929-More-Raid-API.patch +++ b/patches/server/0929-More-Raid-API.patch @@ -86,7 +86,7 @@ index b8ce1c1c2447f9cff1717bfcfd6eb911ade0d4b3..51f21af9d75769abdcba713b9aa33392 + // Paper end - more Raid API } diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java -index 1675ad5818340f21c7e5b6982af315bcad30240b..149377347fc632358a8bb97e644b1c4ab9be413d 100644 +index 50b3f5c185b8bb7965226c97a37faf714f5beb0a..51b10d9cceb4dfbea5e1d82d0404948c6cdc5944 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java @@ -2326,6 +2326,14 @@ public class CraftWorld extends CraftRegionAccessor implements World { diff --git a/patches/server/0930-Add-onboarding-message-for-initial-server-start.patch b/patches/server/0930-Add-onboarding-message-for-initial-server-start.patch index dd0167082e..df74ef8161 100644 --- a/patches/server/0930-Add-onboarding-message-for-initial-server-start.patch +++ b/patches/server/0930-Add-onboarding-message-for-initial-server-start.patch @@ -29,7 +29,7 @@ index 73e8a524925ed6f2580d3bd01616646fabafda78..450a1cc8f1624dce2daf52210d017e07 return instance; } diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java -index 5699863e790bd5f452a37514d1309fbddec0c64a..2168b8d29e1a53460ab83189ed457d38990c5c89 100644 +index 96fdbdcbe43c22b62f679837409da08fcaeae55e..675cbdf1cbac219a386c0ea5931b569b3027b203 100644 --- a/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java @@ -1151,6 +1151,16 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop void loadContentsFromNetwork( diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java -index 1496bc9fa6fe8b5f3b426f4a70550bb66879dfcc..7dade9a2c0efac0bfb7208f70b16e4e440deebec 100644 +index b37e49bd25ed327e03250415799c0777f95bd57b..6d0cfaaf414931d9fd8eee417f4b70ac6679de10 100644 --- a/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java @@ -2251,7 +2251,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop