From 2d6117ac8cc31b083827c914e47fa5c8cb7f1694 Mon Sep 17 00:00:00 2001 From: Konicai <71294714+Konicai@users.noreply.github.com> Date: Sun, 4 Aug 2024 20:42:50 -0500 Subject: [PATCH] Don't allow GC to start when Geyser auth-type is offline --- .../org/geysermc/extension/connect/GeyserConnect.java | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/main/java/org/geysermc/extension/connect/GeyserConnect.java b/src/main/java/org/geysermc/extension/connect/GeyserConnect.java index 91f2948..fdceabe 100644 --- a/src/main/java/org/geysermc/extension/connect/GeyserConnect.java +++ b/src/main/java/org/geysermc/extension/connect/GeyserConnect.java @@ -109,9 +109,11 @@ public class GeyserConnect implements Extension { this.logger().warning("Either `passthrough-motd` or `passthrough-player-counts` is enabled in the config, this will likely produce errors"); } - // If we are using floodgate then disable the extension - if (geyserInstance.getConfig().getRemote().authType() == AuthType.FLOODGATE) { - this.logger().error("auth-type set to floodgate in the config, this will break GeyserConnect. Disabling!"); + // If we are using floodgate then disable the extension. + // GeyserConnect also doesn't support the connection sequence that occurs when the default RemoteServer + // auth-type is offline (and there is no reason to change it when GeyserConnect is in use). + if (geyserInstance.getConfig().getRemote().authType() != AuthType.ONLINE) { + this.logger().error("auth-type is not set to 'online' in the Geyser config, this will break GeyserConnect. Disabling!"); this.disable(); } }