summaryrefslogtreecommitdiff
path: root/src/resources/item/item.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2016-08-23 22:06:54 +0300
committerAndrei Karas <akaras@inbox.ru>2016-08-23 22:06:54 +0300
commitc81d80b6cd18977f60f8ba19f898a583c055d117 (patch)
tree945b484b790640e21247028c38855706d37be45f /src/resources/item/item.cpp
parent06711faa8e02ca2e65e9e1cf2d38c359728f6ccf (diff)
downloadplus-c81d80b6cd18977f60f8ba19f898a583c055d117.tar.gz
plus-c81d80b6cd18977f60f8ba19f898a583c055d117.tar.bz2
plus-c81d80b6cd18977f60f8ba19f898a583c055d117.tar.xz
plus-c81d80b6cd18977f60f8ba19f898a583c055d117.zip
Add check for cards for existing item id.
Diffstat (limited to 'src/resources/item/item.cpp')
-rw-r--r--src/resources/item/item.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/resources/item/item.cpp b/src/resources/item/item.cpp
index 9d3a1b3f8..4627225f2 100644
--- a/src/resources/item/item.cpp
+++ b/src/resources/item/item.cpp
@@ -181,3 +181,11 @@ void Item::updateColor()
if (serverFeatures && serverFeatures->haveItemColors())
setId(mId, ItemColorManager::getColorFromCards(&mCards[0]));
}
+
+bool Item::isItem(const int id)
+{
+ return id != 0 &&
+ id != CARD0_FORGE &&
+ id != CARD0_CREATE &&
+ id != CARD0_PET;
+}