diff options
author | Andrei Karas <akaras@inbox.ru> | 2017-08-09 21:31:02 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2017-08-09 21:31:02 +0300 |
commit | 90705929b29445a4569ff5c9ad13b7efcb304e0a (patch) | |
tree | 0dae1643b0fb33131fb918fe3a1729e879379e26 /src/gui/windows | |
parent | b3fa7a53a29a1001935514a38f140af2b816771a (diff) | |
download | mv-90705929b29445a4569ff5c9ad13b7efcb304e0a.tar.gz mv-90705929b29445a4569ff5c9ad13b7efcb304e0a.tar.bz2 mv-90705929b29445a4569ff5c9ad13b7efcb304e0a.tar.xz mv-90705929b29445a4569ff5c9ad13b7efcb304e0a.zip |
Add different use actions for items.
Can be used from chat or from custom item menu from items.xml
Diffstat (limited to 'src/gui/windows')
-rw-r--r-- | src/gui/windows/inventorywindow.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
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 |