Core/Items: Fix logic in Player::AddItem
Should send client the amount it gave you, not the amount it couldn't give you
This commit is contained in:
1 parent
45363b8216
commit
0267b53813
1 file changed
+1
-1
@@ -25484,7 +25484,7 @@ bool Player::AddItem(uint32 itemId, uint32 count)
|
||||
ItemPosCountVec dest;
|
||||
InventoryResult msg = CanStoreNewItem(NULL_BAG, NULL_SLOT, dest, itemId, count, &noSpaceForCount);
|
||||
if (msg != EQUIP_ERR_OK)
|
||||
count = noSpaceForCount;
|
||||
count -= noSpaceForCount;
|
||||
|
||||
if (count == 0 || dest.empty())
|
||||
{
|
||||
|
||||
Reference in new issue
Block a user