mirror of
https://github.com/MCCTeam/Minecraft-Console-Client
synced 2026-08-29 13:04:59 +00:00
parent
084668b621
commit
5b28179444
3 changed files with 47 additions and 6 deletions
|
|
@ -68,6 +68,12 @@ namespace MinecraftClient.Protocol.Handlers
|
|||
handler.SetTerrainEnabled(false);
|
||||
}
|
||||
|
||||
if (handler.GetInventoryEnabled() && protocolversion > MC114Version)
|
||||
{
|
||||
ConsoleIO.WriteLineFormatted("§8Inventories are currently not handled for that MC version.");
|
||||
handler.SetInventoryEnabled(false);
|
||||
}
|
||||
|
||||
if (protocolversion >= MC113Version)
|
||||
{
|
||||
if (protocolVersion > MC1142Version && handler.GetTerrainEnabled())
|
||||
|
|
@ -465,7 +471,7 @@ namespace MinecraftClient.Protocol.Handlers
|
|||
compression_treshold = dataTypes.ReadNextVarInt(packetData);
|
||||
break;
|
||||
case PacketIncomingType.OpenWindow:
|
||||
if (protocolversion < MC1141Version && handler.GetInventoryEnabled())
|
||||
if (handler.GetInventoryEnabled())
|
||||
{
|
||||
byte windowID = dataTypes.ReadNextByte(packetData);
|
||||
string type = dataTypes.ReadNextString(packetData).Replace("minecraft:", "").ToUpper();
|
||||
|
|
@ -478,7 +484,7 @@ namespace MinecraftClient.Protocol.Handlers
|
|||
}
|
||||
break;
|
||||
case PacketIncomingType.CloseWindow:
|
||||
if (protocolversion < MC1141Version && handler.GetInventoryEnabled())
|
||||
if (handler.GetInventoryEnabled())
|
||||
{
|
||||
byte windowID = dataTypes.ReadNextByte(packetData);
|
||||
|
||||
|
|
@ -486,7 +492,7 @@ namespace MinecraftClient.Protocol.Handlers
|
|||
}
|
||||
break;
|
||||
case PacketIncomingType.WindowItems:
|
||||
if (protocolversion < MC1141Version && handler.GetInventoryEnabled())
|
||||
if (handler.GetInventoryEnabled())
|
||||
{
|
||||
byte id = dataTypes.ReadNextByte(packetData);
|
||||
short elements = dataTypes.ReadNextShort(packetData);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue