summaryrefslogtreecommitdiff
path: root/src/game-server/inventory.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/game-server/inventory.h')
-rw-r--r--src/game-server/inventory.h15
1 files changed, 15 insertions, 0 deletions
diff --git a/src/game-server/inventory.h b/src/game-server/inventory.h
index 84981ea3..812c142d 100644
--- a/src/game-server/inventory.h
+++ b/src/game-server/inventory.h
@@ -64,6 +64,15 @@ class Inventory
bool equip(int inventorySlot);
/**
+ * Unequips all the items with the given item if
+ * from given equipment slot.
+ * @param itemId The item Id to unequip.
+ * @returns whether all item id could be unequipped.
+ * @note returns true when no item with given ids were equipped.
+ */
+ bool unequipItem(unsigned int itemId);
+
+ /**
* Unequips item from given equipment slot.
* @param itemInstance The item instance id used to know what to unequip
* @returns Whether it was unequipped.
@@ -71,6 +80,12 @@ class Inventory
bool unequip(unsigned int itemInstance);
/**
+ * Gets the item instance from the given equipment slot.
+ * Return 0 if none.
+ */
+ unsigned int getSlotItemInstance(unsigned int slot);
+
+ /**
* Inserts some items into the inventory.
* @return number of items not inserted (to be dropped on floor?).
*/