Hotfix/patch modern forwarding v2 (#727)

This commit is contained in:
Corey Shupe
2022-06-07 21:11:53 -04:00
committed by GitHub
parent d97ed956a7
commit 28b6f6dcef

View File

@@ -171,7 +171,7 @@ public class LoginSessionHandler implements MinecraftSessionHandler {
ByteBuf forwarded = Unpooled.buffer(2048);
try {
int forwardingVersion = version.compareTo(ProtocolVersion.MINECRAFT_1_19) >= 0 && playerKey != null
? VelocityConstants.MODERN_FORWARDING_WITH_KEY : VelocityConstants.MODERN_FORWARDING_DEFAULT;
? VelocityConstants.MODERN_FORWARDING_DEFAULT : VelocityConstants.MODERN_FORWARDING_DEFAULT;
ProtocolUtils.writeVarInt(forwarded, forwardingVersion);
ProtocolUtils.writeString(forwarded, address);