From 55cbf74cbe2c40b4592e72621e40f8858fc376d9 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Sun, 17 Jan 2016 18:36:21 +0300 Subject: Move cards constants into separate file. --- src/resources/item/item.cpp | 2 +- src/resources/item/item.h | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) (limited to 'src/resources/item') diff --git a/src/resources/item/item.cpp b/src/resources/item/item.cpp index 3f67585ac..ae31dd94c 100644 --- a/src/resources/item/item.cpp +++ b/src/resources/item/item.cpp @@ -66,7 +66,7 @@ Item::Item(const int id, mFavorite(favorite) { setId(id, color); - for (int f = 0; f < 4; f ++) + for (int f = 0; f < maxCards; f ++) mCards[f] = 0; } diff --git a/src/resources/item/item.h b/src/resources/item/item.h index c287abd8c..9a910c31b 100644 --- a/src/resources/item/item.h +++ b/src/resources/item/item.h @@ -23,6 +23,8 @@ #ifndef RESOURCES_ITEM_ITEM_H #define RESOURCES_ITEM_ITEM_H +#include "const/resources/item/cards.h" + #include "enums/simpletypes/damaged.h" #include "enums/simpletypes/equipm.h" #include "enums/simpletypes/equipped.h" @@ -36,8 +38,6 @@ class Image; -const int maxCards = 4; - /** * Represents one or more instances of a certain item type. */ -- cgit v1.2.3-70-g09d2