Merge pull request #82 from Valorith/copilot/sub-pr-80-again

Fix PutItemInInventoryWithStacking: scan full inventory before placing in empty slot
This commit is contained in:
Vayle 2026-03-19 22:50:13 -04:00 committed by GitHub
commit 24c15b16fe
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -4705,6 +4705,10 @@ bool Client::PutItemInInventoryWithStacking(EQ::ItemInstance *inst)
auto quantity = inst->GetCharges();
for (int i = EQ::invslot::GENERAL_BEGIN; i <= EQ::invslot::GENERAL_END; i++) {
if (quantity == 0) {
break;
}
auto inv_inst = GetInv().GetItem(i);
if (!inv_inst) {
continue;