diff --git a/MinecraftClient/Protocol/Handlers/Protocol17.cs b/MinecraftClient/Protocol/Handlers/Protocol17.cs index 2ab483b7..844d4102 100644 --- a/MinecraftClient/Protocol/Handlers/Protocol17.cs +++ b/MinecraftClient/Protocol/Handlers/Protocol17.cs @@ -595,14 +595,20 @@ namespace MinecraftClient.Protocol.Handlers { protocolversion = atoi(tmp_ver[1]); - // Handle if "name" exists twice, like when connecting to a server with another user logged in. + //Handle if "name" exists twice, eg when connecting to a server with another user logged in. version = (tmp_name.Length == 2) ? tmp_name[1].Split('"')[0] : tmp_name[2].Split('"')[0]; + + //Automatic fix for BungeeCord 1.8 not properly reporting protocol version + if (protocolversion == 0 && version.Split(' ').Contains("1.8")) + protocolversion = ProtocolHandler.MCVer2ProtocolVersion("1.8.0"); + if (result.Contains("modinfo\":")) { //Server is running Forge (which is not supported) version = "Forge " + version; protocolversion = 0; } + ConsoleIO.WriteLineFormatted("ยง8Server version : " + version + " (protocol v" + protocolversion + ")."); return true; }