summaryrefslogtreecommitdiff
path: root/src/resources/beinginfo.h
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2015-08-15 13:58:32 +0300
committerAndrei Karas <akaras@inbox.ru>2015-08-16 01:52:14 +0300
commit41cc92f73e39cec5dfea6b1164176610cccc7df4 (patch)
tree22fd3d388084d2c61fe80f0441c3c30ab8ffd33c /src/resources/beinginfo.h
parent7aa637abc8b0bca35aacdb9492e65f557ed32038 (diff)
downloadmv-41cc92f73e39cec5dfea6b1164176610cccc7df4.tar.gz
mv-41cc92f73e39cec5dfea6b1164176610cccc7df4.tar.bz2
mv-41cc92f73e39cec5dfea6b1164176610cccc7df4.tar.xz
mv-41cc92f73e39cec5dfea6b1164176610cccc7df4.zip
Add strong typed int for item color.
Diffstat (limited to 'src/resources/beinginfo.h')
-rw-r--r--src/resources/beinginfo.h7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/resources/beinginfo.h b/src/resources/beinginfo.h
index 0a6330470..3429515e0 100644
--- a/src/resources/beinginfo.h
+++ b/src/resources/beinginfo.h
@@ -28,6 +28,7 @@
#include "enums/resources/map/blocktype.h"
#include "enums/simpletypes/beingtypeid.h"
+#include "enums/simpletypes/itemcolor.h"
#include "resources/beingmenuitem.h"
#include "resources/cursor.h"
@@ -38,7 +39,7 @@ struct Attack;
namespace ColorDB
{
- class ItemColor;
+ class ItemColorData;
}
typedef std::map<int, Attack*> Attacks;
@@ -312,7 +313,7 @@ class BeingInfo final
void setColorsList(const std::string &name);
- std::string getColor(const int idx) const A_WARN_UNUSED;
+ std::string getColor(const ItemColor idx) const A_WARN_UNUSED;
void addMenu(const std::string &name, const std::string &command);
@@ -332,7 +333,7 @@ class BeingInfo final
std::vector<BeingMenuItem> mMenu;
unsigned char mBlockWalkMask;
BlockType::BlockType mBlockType;
- const std::map <int, ColorDB::ItemColor> *mColors;
+ const std::map <ItemColor, ColorDB::ItemColorData> *mColors;
int mTargetOffsetX;
int mTargetOffsetY;
int mNameOffsetX;