diff options
Diffstat (limited to 'src/gui')
-rw-r--r-- | src/gui/shortcut/itemshortcut.cpp | 4 | ||||
-rw-r--r-- | src/gui/windows/inventorywindow.cpp | 6 |
2 files changed, 5 insertions, 5 deletions
diff --git a/src/gui/shortcut/itemshortcut.cpp b/src/gui/shortcut/itemshortcut.cpp index 7139fd74e..8c091f8c1 100644 --- a/src/gui/shortcut/itemshortcut.cpp +++ b/src/gui/shortcut/itemshortcut.cpp @@ -160,8 +160,8 @@ void ItemShortcut::useItem(const size_t index) const if (itemId < SPELL_MIN_ID) { const Item *const item = inv->findItem(itemId, itemColor); - if ((item != nullptr) && (item->getQuantity() != 0)) - PlayerInfo::useEquipItem(item, Sfx_true); + if (item != nullptr && item->getQuantity() != 0) + PlayerInfo::useEquipItem(item, 0, Sfx_true); } else if (itemId < SKILL_MIN_ID && (spellManager != nullptr)) { diff --git a/src/gui/windows/inventorywindow.cpp b/src/gui/windows/inventorywindow.cpp index 8a3a70bdc..9fc6b6b38 100644 --- a/src/gui/windows/inventorywindow.cpp +++ b/src/gui/windows/inventorywindow.cpp @@ -470,11 +470,11 @@ void InventoryWindow::action(const ActionEvent &event) if (eventId == "use") { - PlayerInfo::useEquipItem(item, Sfx_true); + PlayerInfo::useEquipItem(item, 0, Sfx_true); } if (eventId == "equip") { - PlayerInfo::useEquipItem2(item, Sfx_true); + PlayerInfo::useEquipItem2(item, 0, Sfx_true); } else if (eventId == "drop") { @@ -672,7 +672,7 @@ void InventoryWindow::mouseClicked(MouseEvent &event) } else { - PlayerInfo::useEquipItem(item, Sfx_true); + PlayerInfo::useEquipItem(item, 0, Sfx_true); } } else |