diff options
author | Kae <80987908+Novaenia@users.noreply.github.com> | 2023-11-02 16:31:35 +1100 |
---|---|---|
committer | Kae <80987908+Novaenia@users.noreply.github.com> | 2023-11-02 16:31:35 +1100 |
commit | 1f5b954eb26c2eb4db946dd6f8161f86db85e9fd (patch) | |
tree | 6e74d3cbbc5cdfe1777e501b20dff5ba2e1107d3 | |
parent | 86f41b8450431405c80270bb5fa78c096aa424fc (diff) |
Fix (vanilla): Item disappearing from action bar after stacking identical item into it
-rw-r--r-- | source/game/StarPlayerInventory.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/source/game/StarPlayerInventory.cpp b/source/game/StarPlayerInventory.cpp index 8ae052c..7c4ca3e 100644 --- a/source/game/StarPlayerInventory.cpp +++ b/source/game/StarPlayerInventory.cpp @@ -539,7 +539,8 @@ void PlayerInventory::shiftSwap(InventorySlot const& slot) { } else if (auto bs = slot.ptr<BagSlot>()) { if (itemAllowedInBag(m_swapSlot, bs->first)) { m_swapSlot = m_bags[bs->first]->swapItems(bs->second, m_swapSlot); - swapCustomBarLinks(SwapSlot(), slot); + if (m_swapSlot && !m_swapSlot->empty()) + swapCustomBarLinks(SwapSlot(), slot); } } |