summaryrefslogtreecommitdiff
path: root/src/resources/itemdb.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2011-01-21 22:12:51 +0200
committerAndrei Karas <akaras@inbox.ru>2011-01-21 22:12:51 +0200
commit05ea95733e9ec89626e08989e0688e73d1408d3a (patch)
tree2351a8f2b6b81eb48a6f5f4dd068a9a13d117fb1 /src/resources/itemdb.cpp
parent7be91e6213aadb0405bdd2fa3a9210598b254041 (diff)
downloadmv-05ea95733e9ec89626e08989e0688e73d1408d3a.tar.gz
mv-05ea95733e9ec89626e08989e0688e73d1408d3a.tar.bz2
mv-05ea95733e9ec89626e08989e0688e73d1408d3a.tar.xz
mv-05ea95733e9ec89626e08989e0688e73d1408d3a.zip
Add floor items attribute for drawing floor items.
Diffstat (limited to 'src/resources/itemdb.cpp')
-rw-r--r--src/resources/itemdb.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/resources/itemdb.cpp b/src/resources/itemdb.cpp
index e2775c8e8..826912b33 100644
--- a/src/resources/itemdb.cpp
+++ b/src/resources/itemdb.cpp
@@ -199,6 +199,7 @@ void ItemDB::load()
std::string name = XML::getProperty(node, "name", "");
std::string image = XML::getProperty(node, "image", "");
+ std::string floor = XML::getProperty(node, "floor", "");
std::string description = XML::getProperty(node, "description", "");
std::string attackAction = XML::getProperty(node, "attack-action", "");
std::string drawBefore = XML::getProperty(node, "drawBefore", "");
@@ -218,6 +219,10 @@ void ItemDB::load()
SpriteDisplay display;
display.image = image;
+ if (floor != "")
+ display.floor = floor;
+ else
+ display.floor = image;
ItemInfo *itemInfo = new ItemInfo;
itemInfo->setId(id);