From 41cc92f73e39cec5dfea6b1164176610cccc7df4 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Sat, 15 Aug 2015 13:58:32 +0300 Subject: Add strong typed int for item color. --- src/flooritem.h | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'src/flooritem.h') diff --git a/src/flooritem.h b/src/flooritem.h index 33c95c062..fe0bd26ad 100644 --- a/src/flooritem.h +++ b/src/flooritem.h @@ -23,6 +23,8 @@ #ifndef FLOORITEM_H #define FLOORITEM_H +#include "enums/simpletypes/itemcolor.h" + #include "being/actorsprite.h" #include "resources/cursor.h" @@ -49,7 +51,7 @@ class FloorItem final : public ActorSprite const int itemId, const int x, const int y, const int amount, - const unsigned char color); + const ItemColor color); A_DELETE_COPY(FloorItem) @@ -88,7 +90,7 @@ class FloorItem final : public ActorSprite unsigned getPickupCount() const A_WARN_UNUSED { return mPickupCount; } - unsigned char getColor() const A_WARN_UNUSED + ItemColor getColor() const A_WARN_UNUSED { return mColor; } bool getShowMsg() const A_WARN_UNUSED @@ -111,7 +113,7 @@ class FloorItem final : public ActorSprite int mHeightPosDiff; unsigned int mPickupCount; Cursor::Cursor mCursor; - unsigned char mColor; + ItemColor mColor; bool mShowMsg; bool mHighlight; }; -- cgit v1.2.3-60-g2f50