summaryrefslogtreecommitdiff
path: root/src/actions/actions.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/actions/actions.cpp')
-rw-r--r--src/actions/actions.cpp16
1 files changed, 16 insertions, 0 deletions
diff --git a/src/actions/actions.cpp b/src/actions/actions.cpp
index 8cd2600b4..da62c6549 100644
--- a/src/actions/actions.cpp
+++ b/src/actions/actions.cpp
@@ -380,6 +380,22 @@ impHandler(dropItemId)
return true;
}
+impHandler(dropItemInv)
+{
+ const Inventory *const inv = PlayerInfo::getInventory();
+ if (!inv)
+ return false;
+
+ Item *const item = inv->getItem(atoi(event.args.c_str()));
+
+ if (item && !PlayerInfo::isItemProtected(item->getId()))
+ {
+ ItemAmountWindow::showWindow(ItemAmountWindow::ItemDrop,
+ inventoryWindow, item);
+ }
+ return true;
+}
+
impHandler(dropItemIdAll)
{
const Inventory *const inv = PlayerInfo::getInventory();