summaryrefslogtreecommitdiff
path: root/src/being/being.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2015-11-02 17:23:32 +0300
committerAndrei Karas <akaras@inbox.ru>2015-11-02 17:23:32 +0300
commitf89de74b1ac1cd9a02a70dab9221d601296da8cd (patch)
tree444451eb017720bdc1d3457e6e7976a84e065351 /src/being/being.cpp
parentc2748e2217f0ac69e2f06f39e6411f5e77c11974 (diff)
downloadmv-f89de74b1ac1cd9a02a70dab9221d601296da8cd.tar.gz
mv-f89de74b1ac1cd9a02a70dab9221d601296da8cd.tar.bz2
mv-f89de74b1ac1cd9a02a70dab9221d601296da8cd.tar.xz
mv-f89de74b1ac1cd9a02a70dab9221d601296da8cd.zip
Add intmap defines.
Diffstat (limited to 'src/being/being.cpp')
-rw-r--r--src/being/being.cpp9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/being/being.cpp b/src/being/being.cpp
index 686b73f54..7a937ceaf 100644
--- a/src/being/being.cpp
+++ b/src/being/being.cpp
@@ -2972,7 +2972,7 @@ void Being::recalcSpritesOrder()
return;
std::vector<int> slotRemap;
- std::map<int, int> itemSlotRemap;
+ IntMap itemSlotRemap;
std::vector<int>::iterator it;
int oldHide[20];
@@ -3018,7 +3018,7 @@ void Being::recalcSpritesOrder()
FOR_EACHP (SpriteToItemMapCIter, itr, spriteToItems)
{
const int remSprite = itr->first;
- const std::map<int, int> &itemReplacer = itr->second;
+ const IntMap &itemReplacer = itr->second;
if (remSprite >= 0)
{ // slot known
if (itemReplacer.empty())
@@ -3027,7 +3027,7 @@ void Being::recalcSpritesOrder()
}
else if (mSpriteHide[remSprite] != 1)
{
- std::map<int, int>::const_iterator repIt
+ IntMapCIter repIt
= itemReplacer.find(mSpriteIDs[remSprite]);
if (repIt == itemReplacer.end())
{
@@ -3169,8 +3169,7 @@ void Being::recalcSpritesOrder()
int idx1 = -1;
// logger->log("item %d, id=%d", slot, id);
int reorder = 0;
- const std::map<int, int>::const_iterator
- orderIt = itemSlotRemap.find(id);
+ const IntMapCIter orderIt = itemSlotRemap.find(id);
if (orderIt != itemSlotRemap.end())
reorder = orderIt->second;