diff --git a/protocol/src/main/java/net/md_5/bungee/protocol/ProtocolConstants.java b/protocol/src/main/java/net/md_5/bungee/protocol/ProtocolConstants.java index 182614c47..9b3fb5841 100644 --- a/protocol/src/main/java/net/md_5/bungee/protocol/ProtocolConstants.java +++ b/protocol/src/main/java/net/md_5/bungee/protocol/ProtocolConstants.java @@ -45,7 +45,7 @@ public class ProtocolConstants public static final int MINECRAFT_1_20 = 763; public static final int MINECRAFT_1_20_2 = 764; public static final int MINECRAFT_1_20_3 = 765; - public static final int MINECRAFT_1_20_5 = 1073742011; + public static final int MINECRAFT_1_20_5 = 1073742013; public static final List SUPPORTED_VERSIONS; public static final List SUPPORTED_VERSION_IDS; diff --git a/protocol/src/main/java/net/md_5/bungee/protocol/packet/LoginSuccess.java b/protocol/src/main/java/net/md_5/bungee/protocol/packet/LoginSuccess.java index 07fb3d79a..60ff5700c 100644 --- a/protocol/src/main/java/net/md_5/bungee/protocol/packet/LoginSuccess.java +++ b/protocol/src/main/java/net/md_5/bungee/protocol/packet/LoginSuccess.java @@ -37,6 +37,11 @@ public class LoginSuccess extends DefinedPacket { properties = readProperties( buf ); } + if ( protocolVersion >= ProtocolConstants.MINECRAFT_1_20_5 ) + { + // Whether the client should disconnect on its own if it receives invalid data from the server + buf.readBoolean(); + } } @Override @@ -54,6 +59,12 @@ public class LoginSuccess extends DefinedPacket { writeProperties( properties, buf ); } + if ( protocolVersion >= ProtocolConstants.MINECRAFT_1_20_5 ) + { + // Whether the client should disconnect on its own if it receives invalid data from the server + // Vanilla sends true so we also send true + buf.writeBoolean( true ); + } } @Override