From c741d81017dc9d156091e122f6bf91a84d1b32f3 Mon Sep 17 00:00:00 2001 From: Marc Lorenz <44411062+12xx12@users.noreply.github.com> Date: Tue, 21 Dec 2021 13:21:58 +0100 Subject: fixed bad web merge --- src/Entities/Pickup.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/Entities/Pickup.cpp b/src/Entities/Pickup.cpp index 0e3cf8ef2..4f7462a1f 100644 --- a/src/Entities/Pickup.cpp +++ b/src/Entities/Pickup.cpp @@ -47,6 +47,9 @@ public: { short CombineCount = static_cast(Item.m_ItemCount); if ((CombineCount + static_cast(m_Pickup->GetItem().m_ItemCount)) > static_cast(Item.GetMaxStackSize())) + { + CombineCount = Item.GetMaxStackSize() - m_Pickup->GetItem().m_ItemCount; + } if (CombineCount <= 0) { -- cgit v1.2.3