From 2dc2a95e4aa1466f7fd29f41b2b976ab47241259 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Fri, 21 Aug 2015 19:12:35 +0300 Subject: Add tag field into item. --- src/item.cpp | 1 + src/item.h | 7 +++++++ 2 files changed, 8 insertions(+) diff --git a/src/item.cpp b/src/item.cpp index 9a2537b18..50ccf374a 100644 --- a/src/item.cpp +++ b/src/item.cpp @@ -57,6 +57,7 @@ Item::Item(const int id, mRefine(refine), mInvIndex(0), mType(type), + mTag(0), mEquipment(equipment), mEquipped(equipped), mInEquipment(false), diff --git a/src/item.h b/src/item.h index 7df66f4b9..9f0772286 100644 --- a/src/item.h +++ b/src/item.h @@ -215,6 +215,12 @@ class Item notfinal int getType() const A_WARN_UNUSED { return mType; } + void setTag(const int tag) + { mTag = tag; } + + int getTag() const A_WARN_UNUSED + { return mTag; } + void addCard(const int card); void updateColor(); @@ -231,6 +237,7 @@ class Item notfinal uint8_t mRefine; /**< Item refine level. */ int mInvIndex; /**< Inventory index. */ int mType; /**< Item type. */ + int mTag; Equipm mEquipment; /**< Item is equipment. */ Equipped mEquipped; /**< Item is equipped. */ bool mInEquipment; /**< Item is in equipment */ -- cgit v1.2.3-60-g2f50