Skip to content

Commit 831a86c

Browse files
authored
Merge pull request #2864 from DevBobcorn/master
2 parents 2409de2 + 1978198 commit 831a86c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

MinecraftClient/Protocol/Handlers/Protocol18.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2121,7 +2121,7 @@ private bool HandlePlayPackets(int packetId, Queue<byte> packetData)
21212121
{
21222122
var windowId = dataTypes.ReadNextByte(packetData);
21232123
var stateId = -1;
2124-
var elements = 0;
2124+
int elements;
21252125

21262126
if (protocolVersion >= MC_1_17_1_Version)
21272127
{
@@ -2132,7 +2132,7 @@ private bool HandlePlayPackets(int packetId, Queue<byte> packetData)
21322132
else
21332133
{
21342134
// Elements as Short - 1.17.0 and below
2135-
dataTypes.ReadNextShort(packetData);
2135+
elements = dataTypes.ReadNextShort(packetData);
21362136
}
21372137

21382138
Dictionary<int, Item> inventorySlots = new();

0 commit comments

Comments
 (0)