diff options
author | Andrei Karas <akaras@inbox.ru> | 2013-04-14 20:09:22 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2013-04-14 23:35:07 +0300 |
commit | 796f7e2c2ace55462acfa50e5085d4d048047e68 (patch) | |
tree | 878c6f36f001774047cc26fa7fb68f474920bbf0 /src/resources/itemdb.cpp | |
parent | 6b5c7e7a5ed32abfc98d9acdebacc50c68a91a1d (diff) | |
download | manaplus-796f7e2c2ace55462acfa50e5085d4d048047e68.tar.gz manaplus-796f7e2c2ace55462acfa50e5085d4d048047e68.tar.bz2 manaplus-796f7e2c2ace55462acfa50e5085d4d048047e68.tar.xz manaplus-796f7e2c2ace55462acfa50e5085d4d048047e68.zip |
add basic client side only support for pets.
now pets cant move and dont have any ai.
pet can be only spawn at player position if equiped item with assigned pet.
Diffstat (limited to 'src/resources/itemdb.cpp')
-rw-r--r-- | src/resources/itemdb.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/resources/itemdb.cpp b/src/resources/itemdb.cpp index befcd621e..973e5c71d 100644 --- a/src/resources/itemdb.cpp +++ b/src/resources/itemdb.cpp @@ -210,6 +210,7 @@ void ItemDB::load() std::string attackAction = XML::getProperty(node, "attack-action", ""); std::string drawBefore = XML::getProperty(node, "drawBefore", ""); std::string drawAfter = XML::getProperty(node, "drawAfter", ""); + const int pet = XML::getProperty(node, "pet", 0); const int maxFloorOffset = XML::getIntProperty( node, "maxFloorOffset", 32, 0, 32); std::string colors; @@ -261,6 +262,7 @@ void ItemDB::load() itemInfo->setDescription(description); itemInfo->setType(itemTypeFromString(typeStr)); itemInfo->addTag(mTags["All"]); + itemInfo->setPet(pet); switch (itemInfo->getType()) { case ITEM_USABLE: |