summaryrefslogtreecommitdiff
path: root/src/flooritem.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/flooritem.cpp')
-rw-r--r--src/flooritem.cpp9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/flooritem.cpp b/src/flooritem.cpp
index 619be25ea..740daf387 100644
--- a/src/flooritem.cpp
+++ b/src/flooritem.cpp
@@ -41,7 +41,8 @@ FloorItem::FloorItem(int id,
int x,
int y,
Map *map,
- int amount):
+ int amount,
+ unsigned char color):
ActorSprite(id),
mItemId(itemId),
mX(x),
@@ -49,7 +50,8 @@ FloorItem::FloorItem(int id,
mMap(map),
// mAlpha(1.0f),
mAmount(amount),
- mPickupCount(0)
+ mPickupCount(0),
+ mColor(color)
{
mDropTime = cur_time;
@@ -69,7 +71,8 @@ FloorItem::FloorItem(int id,
mPos.y = 0;
}
- setupSpriteDisplay(ItemDB::get(itemId).getDisplay(), true, 1);
+ ItemInfo info = ItemDB::get(itemId);
+ setupSpriteDisplay(info.getDisplay(), true, 1, info.getDyeColorsString(mColor));
}
const ItemInfo &FloorItem::getInfo() const