diff options
author | Reid <reidyaro@gmail.com> | 2012-03-01 22:03:01 +0100 |
---|---|---|
committer | Reid <reidyaro@gmail.com> | 2012-03-01 22:03:01 +0100 |
commit | 490862919d79369112c75955a9c36ff8a081efd3 (patch) | |
tree | 6fe89466b9c53ba811f298174e6d787bbae71e09 /src/being.cpp | |
parent | dff814619d63496acd3c4e8730b828b5d4d931fb (diff) | |
parent | d873da3e8e57480016596f714845c1bc7e712e68 (diff) | |
download | manaverse-490862919d79369112c75955a9c36ff8a081efd3.tar.gz manaverse-490862919d79369112c75955a9c36ff8a081efd3.tar.bz2 manaverse-490862919d79369112c75955a9c36ff8a081efd3.tar.xz manaverse-490862919d79369112c75955a9c36ff8a081efd3.zip |
Merge branch 'master' of gitorious.org:manaplus/manaplus
Diffstat (limited to 'src/being.cpp')
-rw-r--r-- | src/being.cpp | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/being.cpp b/src/being.cpp index e1cb9b0ae..664eecd1d 100644 --- a/src/being.cpp +++ b/src/being.cpp @@ -1380,8 +1380,10 @@ void Being::drawEmotion(Graphics *graphics, int offsetX, int offsetY) if (emotionIndex >= 0 && emotionIndex <= EmoteDB::getLast()) { - if (EmoteDB::getAnimation(emotionIndex)) + if (EmoteDB::getAnimation(emotionIndex, true)) EmoteDB::getAnimation(emotionIndex)->draw(graphics, px, py); + else + mEmotion = 0; } } @@ -2320,7 +2322,7 @@ void Being::recalcSpritesOrder() int val = slotRemap.at(slot); int id = 0; - if ((int)mSpriteIDs.size() > val) + if (static_cast<int>(mSpriteIDs.size()) > val) id = mSpriteIDs[val]; int idx = -1; @@ -2525,7 +2527,6 @@ void Being::saveComment(const std::string &name, void Being::setState(Uint8 state) { - mAdvanced = true; bool shop = (state & FLAG_SHOP); bool away = (state & FLAG_AWAY); bool inactive = (state & FLAG_INACTIVE); @@ -2548,6 +2549,7 @@ void Being::setEmote(Uint8 emotion, int emote_time) if ((emotion & FLAG_SPECIAL) == FLAG_SPECIAL) { setState(emotion); + mAdvanced = true; } else { |