diff options
-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 |