From 49bd56446fa10931b1c4abf6609055571a4ae105 Mon Sep 17 00:00:00 2001 From: chris Date: Fri, 14 Jun 2024 04:08:27 +0200 Subject: [PATCH] Preliminary 1.21 Spigot support (#521) --- build-logic/src/main/kotlin/Versions.kt | 3 +-- spigot/build.gradle.kts | 4 +++- .../org/geysermc/floodgate/module/SpigotCommandModule.java | 4 ++-- 3 files changed, 6 insertions(+), 5 deletions(-) diff --git a/build-logic/src/main/kotlin/Versions.kt b/build-logic/src/main/kotlin/Versions.kt index d04e0f59..f22b3d80 100644 --- a/build-logic/src/main/kotlin/Versions.kt +++ b/build-logic/src/main/kotlin/Versions.kt @@ -33,8 +33,7 @@ object Versions { const val guiceVersion = "6.0.0" const val nettyVersion = "4.1.49.Final" const val snakeyamlVersion = "1.28" - // TODO move to cloud release once those have 1.20.5 support - const val cloudVersion = "2.0.0-beta.7" // for cloud-minecraft + const val cloudVersion = "2.0.0-SNAPSHOT" // for cloud-minecraft const val cloudCore = "2.0.0-rc.1" const val bstatsVersion = "3.0.2" diff --git a/spigot/build.gradle.kts b/spigot/build.gradle.kts index 6e95bae1..af449d2f 100644 --- a/spigot/build.gradle.kts +++ b/spigot/build.gradle.kts @@ -13,7 +13,9 @@ indra { dependencies { api(projects.core) - implementation("org.incendo", "cloud-paper", Versions.cloudVersion) + //implementation("org.incendo", "cloud-paper", Versions.cloudVersion) + // TODO change back after https://github.com/incendo/cloud-minecraft is merged + implementation("com.github.onebeastchris.cloud-minecraft", "cloud-paper", "jitpack-SNAPSHOT") // hack to make pre 1.12 work implementation("com.google.guava", "guava", guavaVersion) diff --git a/spigot/src/main/java/org/geysermc/floodgate/module/SpigotCommandModule.java b/spigot/src/main/java/org/geysermc/floodgate/module/SpigotCommandModule.java index 959c4ac0..d616181e 100644 --- a/spigot/src/main/java/org/geysermc/floodgate/module/SpigotCommandModule.java +++ b/spigot/src/main/java/org/geysermc/floodgate/module/SpigotCommandModule.java @@ -40,7 +40,7 @@ import org.geysermc.floodgate.player.audience.FloodgateSenderMapper; import org.incendo.cloud.CommandManager; import org.incendo.cloud.execution.ExecutionCoordinator; -import org.incendo.cloud.paper.PaperCommandManager; +import org.incendo.cloud.paper.LegacyPaperCommandManager; @RequiredArgsConstructor public final class SpigotCommandModule extends CommandModule { @@ -56,7 +56,7 @@ protected void configure() { @Singleton @SneakyThrows public CommandManager commandManager(CommandUtil commandUtil) { - CommandManager commandManager = new PaperCommandManager<>( + CommandManager commandManager = new LegacyPaperCommandManager<>( plugin, ExecutionCoordinator.simpleCoordinator(), new FloodgateSenderMapper<>(commandUtil)