mirror of
https://github.com/MCCTeam/Minecraft-Console-Client
synced 2025-10-14 21:22:49 +00:00
Update version to 1.18 (#1836)
This commit is contained in:
parent
6918a64c47
commit
9a9245f193
7 changed files with 194 additions and 5 deletions
|
|
@ -52,6 +52,7 @@ namespace MinecraftClient.Protocol.Handlers
|
|||
internal const int MC1165Version = 754;
|
||||
internal const int MC117Version = 755;
|
||||
internal const int MC1171Version = 756;
|
||||
internal const int MC118Version = 757;
|
||||
|
||||
private int compression_treshold = 0;
|
||||
private bool autocomplete_received = false;
|
||||
|
|
@ -325,6 +326,8 @@ namespace MinecraftClient.Protocol.Handlers
|
|||
dataTypes.ReadNextString(packetData); // Level Type - 1.15 and below
|
||||
if (protocolversion >= MC114Version)
|
||||
dataTypes.ReadNextVarInt(packetData); // View distance - 1.14 and above
|
||||
if (protocolversion >= MC118Version)
|
||||
dataTypes.ReadNextVarInt(packetData); // Simulation Distance - 1.18 and above
|
||||
if (protocolversion >= MC18Version)
|
||||
dataTypes.ReadNextBool(packetData); // Reduced debug info - 1.8 and above
|
||||
if (protocolversion >= MC115Version)
|
||||
|
|
@ -1609,7 +1612,9 @@ namespace MinecraftClient.Protocol.Handlers
|
|||
if (protocolversion >= MC19Version)
|
||||
fields.AddRange(dataTypes.GetVarInt(mainHand));
|
||||
if (protocolversion >= MC117Version)
|
||||
fields.Add(1);
|
||||
fields.Add(0); // Enables text filtering. Always false
|
||||
if (protocolversion >= MC118Version)
|
||||
fields.Add(1); // 1.18 and above - Allow server listings
|
||||
SendPacket(PacketTypesOut.ClientSettings, fields);
|
||||
}
|
||||
catch (SocketException) { }
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue