diff options
author | Andrei Karas <akaras@inbox.ru> | 2016-06-21 18:06:28 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2016-06-21 18:06:28 +0300 |
commit | ae351c43eca44c532404deb9f10bf3e4b97406bf (patch) | |
tree | 32a8380404183b1938981c3020c13e09f57291b0 /src/being | |
parent | c04cc2c9270b5a54fae239d0ae60356113bdf70b (diff) | |
download | manaverse-ae351c43eca44c532404deb9f10bf3e4b97406bf.tar.gz manaverse-ae351c43eca44c532404deb9f10bf3e4b97406bf.tar.bz2 manaverse-ae351c43eca44c532404deb9f10bf3e4b97406bf.tar.xz manaverse-ae351c43eca44c532404deb9f10bf3e4b97406bf.zip |
Imrove Being::setTempSprite.
Diffstat (limited to 'src/being')
-rw-r--r-- | src/being/being.cpp | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/src/being/being.cpp b/src/being/being.cpp index c5c68068d..618922fa3 100644 --- a/src/being/being.cpp +++ b/src/being/being.cpp @@ -2944,17 +2944,16 @@ void Being::setTempSprite(const unsigned int slot, mGender, mSubType); int lastTime = 0; int startTime = 0; - const CardsList &cards = beingSlot.cardsId; - std::string color = beingSlot.color; AnimatedSprite *restrict equipmentSprite = nullptr; - ItemColor colorId = ItemColor_one; - if (!cards.isEmpty()) - colorId = ItemColorManager::getColorFromCards(cards); - if (!filename.empty()) { + ItemColor colorId = ItemColor_one; + const CardsList &cards = beingSlot.cardsId; + if (!cards.isEmpty()) + colorId = ItemColorManager::getColorFromCards(cards); + std::string color = beingSlot.color; if (color.empty()) color = info.getDyeColorsString(colorId); |