~ruther/NosSmooth

5abe3757cbd054205a4147029844ded6e4ef60d3 — Rutherther 2 years ago 32f0234
fix(game): parse null inv sub packets correctly
1 files changed, 5 insertions(+), 2 deletions(-)

M Core/NosSmooth.Game/PacketHandlers/Inventory/InventoryInitResponder.cs
M Core/NosSmooth.Game/PacketHandlers/Inventory/InventoryInitResponder.cs => Core/NosSmooth.Game/PacketHandlers/Inventory/InventoryInitResponder.cs +5 -2
@@ 59,9 59,12 @@ public class InventoryInitResponder : IPacketResponder<InvPacket>, IPacketRespon

        var slots = new List<InventorySlot>();

        foreach (var subPacket in packet.InvSubPackets)
        if (packet.InvSubPackets is not null)
        {
            slots.Add(await CreateSlot(subPacket, ct));
            foreach (var subPacket in packet.InvSubPackets)
            {
                slots.Add(await CreateSlot(subPacket, ct));
            }
        }

        void AddItems(Data.Inventory.Inventory inv)

Do not follow this link