From 104452acc2f96f50032dbc675d31796e4f7896eb Mon Sep 17 00:00:00 2001 From: UserNugget Date: Tue, 23 Jan 2024 17:53:32 +0300 Subject: [PATCH 1/2] Velocity b329+ support --- build.gradle | 4 ++-- gradle.properties | 2 +- .../net/elytrium/limboauth/handler/AuthSessionHandler.java | 6 +++--- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/build.gradle b/build.gradle index b78a0e52..806908a7 100644 --- a/build.gradle +++ b/build.gradle @@ -13,8 +13,8 @@ setGroup("net.elytrium") setVersion("1.1.14-SNAPSHOT") java { - setSourceCompatibility(JavaVersion.VERSION_11) - setTargetCompatibility(JavaVersion.VERSION_11) + setSourceCompatibility(JavaVersion.VERSION_17) + setTargetCompatibility(JavaVersion.VERSION_17) } compileJava { diff --git a/gradle.properties b/gradle.properties index 36034476..7ae451a8 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1,5 +1,5 @@ limboapiVersion=1.1.7 -velocityVersion=3.2.0-SNAPSHOT +velocityVersion=3.3.0-SNAPSHOT nettyVersion=4.1.86.Final floodgateVersion=2.2.0-SNAPSHOT fastutilVersion=8.5.11 diff --git a/src/main/java/net/elytrium/limboauth/handler/AuthSessionHandler.java b/src/main/java/net/elytrium/limboauth/handler/AuthSessionHandler.java index e4ad322d..cc12aea2 100644 --- a/src/main/java/net/elytrium/limboauth/handler/AuthSessionHandler.java +++ b/src/main/java/net/elytrium/limboauth/handler/AuthSessionHandler.java @@ -21,7 +21,7 @@ import com.google.common.primitives.Longs; import com.j256.ormlite.dao.Dao; import com.velocitypowered.api.proxy.Player; -import com.velocitypowered.proxy.protocol.packet.PluginMessage; +import com.velocitypowered.proxy.protocol.packet.PluginMessagePacket; import dev.samstevens.totp.code.CodeVerifier; import dev.samstevens.totp.code.DefaultCodeGenerator; import dev.samstevens.totp.code.DefaultCodeVerifier; @@ -271,8 +271,8 @@ public void onChat(String message) { @Override public void onGeneric(Object packet) { - if (Settings.IMP.MAIN.MOD.ENABLED && packet instanceof PluginMessage) { - PluginMessage pluginMessage = (PluginMessage) packet; + if (Settings.IMP.MAIN.MOD.ENABLED && packet instanceof PluginMessagePacket) { + PluginMessagePacket pluginMessage = (PluginMessagePacket) packet; String channel = pluginMessage.getChannel(); if (channel.equals("MC|Brand") || channel.equals("minecraft:brand")) { From 2c60de7d53584703bded58f1b0d6e67053d9d6e4 Mon Sep 17 00:00:00 2001 From: UserNugget Date: Tue, 23 Jan 2024 19:00:33 +0300 Subject: [PATCH 2/2] Fix workflow --- .github/workflows/build.yml | 2 +- .github/workflows/release.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 83eda41e..3269ee60 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -18,7 +18,7 @@ jobs: uses: actions/setup-java@v3.0.0 with: distribution: adopt - java-version: 11 + java-version: 17 - name: Build LimboAuth run: ./gradlew build - name: Upload LimboAuth diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 52481c5f..13b1b011 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -14,7 +14,7 @@ jobs: uses: actions/setup-java@v3.0.0 with: distribution: adopt - java-version: 11 + java-version: 17 - name: Build LimboAuth run: ./gradlew build - name: Upload LimboAuth