diff options
author | Andrei Karas <akaras@inbox.ru> | 2014-09-16 15:37:44 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2014-09-16 15:37:44 +0300 |
commit | 6efa9dcfeaba6582ca53739a2c9deb1daab8c65c (patch) | |
tree | de0d7dbabd3aaedd30fdb022cb4f1716a5bce39c /src | |
parent | 279efb073f06175d734126b3ba61453347ec4e45 (diff) | |
download | mv-6efa9dcfeaba6582ca53739a2c9deb1daab8c65c.tar.gz mv-6efa9dcfeaba6582ca53739a2c9deb1daab8c65c.tar.bz2 mv-6efa9dcfeaba6582ca53739a2c9deb1daab8c65c.tar.xz mv-6efa9dcfeaba6582ca53739a2c9deb1daab8c65c.zip |
remove useless check for server version while selecting attack animation.
Diffstat (limited to 'src')
-rw-r--r-- | src/being/being.cpp | 21 |
1 files changed, 7 insertions, 14 deletions
diff --git a/src/being/being.cpp b/src/being/being.cpp index 853fb20d6..68420f742 100644 --- a/src/being/being.cpp +++ b/src/being/being.cpp @@ -1066,22 +1066,15 @@ std::string Being::getWeaponAttackAction(const ItemInfo *const weapon) const if (!weapon) return SpriteAction::ATTACK; - if (serverVersion < 0) - { - return weapon->getAttackAction(); - } - else + if (mMap) { - if (mMap) - { - const unsigned char mask = mMap->getBlockMask(mX, mY); - if (mask & BlockMask::AIR) - return weapon->getSkyAttackAction(); - else if (mask & BlockMask::WATER) - return weapon->getWaterAttackAction(); - } - return weapon->getAttackAction(); + const unsigned char mask = mMap->getBlockMask(mX, mY); + if (mask & BlockMask::AIR) + return weapon->getSkyAttackAction(); + else if (mask & BlockMask::WATER) + return weapon->getWaterAttackAction(); } + return weapon->getAttackAction(); } std::string Being::getAttackAction(const Attack *const attack1) const |