summaryrefslogtreecommitdiff
path: root/src/net/tmwa/beinghandler.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2014-09-16 21:24:09 +0300
committerAndrei Karas <akaras@inbox.ru>2014-09-16 21:24:09 +0300
commitf91ad9a0c39ae1c537f2769f1fdf4b0a59e8bf91 (patch)
tree2a17b4d8c03215e89ddb00cea1595853fb61dde8 /src/net/tmwa/beinghandler.cpp
parent00a9e49121dfdd706607ceb35fc4dcba4ffbf80c (diff)
downloadmanaplus-f91ad9a0c39ae1c537f2769f1fdf4b0a59e8bf91.tar.gz
manaplus-f91ad9a0c39ae1c537f2769f1fdf4b0a59e8bf91.tar.bz2
manaplus-f91ad9a0c39ae1c537f2769f1fdf4b0a59e8bf91.tar.xz
manaplus-f91ad9a0c39ae1c537f2769f1fdf4b0a59e8bf91.zip
add server feature haveMonsterAttackRange.
Diffstat (limited to 'src/net/tmwa/beinghandler.cpp')
-rw-r--r--src/net/tmwa/beinghandler.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/net/tmwa/beinghandler.cpp b/src/net/tmwa/beinghandler.cpp
index 398d582bd..f39b88979 100644
--- a/src/net/tmwa/beinghandler.cpp
+++ b/src/net/tmwa/beinghandler.cpp
@@ -1133,7 +1133,8 @@ void BeingHandler::processBeingVisible(Net::MessageIn &msg)
msg.readInt16("manner");
dstBeing->setStatusEffectBlock(32, msg.readInt16("opt3"));
- if (serverVersion > 0 && dstBeing->getType() == ActorType::Monster)
+ if (Net::getServerFeatures()->haveMonsterAttackRange()
+ && dstBeing->getType() == ActorType::Monster)
{
const int attackRange = static_cast<int>(
msg.readUInt8("attack range (was karma)"));
@@ -1336,7 +1337,8 @@ void BeingHandler::processBeingMove(Net::MessageIn &msg)
msg.readInt16("manner");
dstBeing->setStatusEffectBlock(32, msg.readInt16("opt3"));
- if (serverVersion > 0 && dstBeing->getType() == ActorType::Monster)
+ if (Net::getServerFeatures()->haveMonsterAttackRange()
+ && dstBeing->getType() == ActorType::Monster)
{
const int attackRange = static_cast<int>(
msg.readUInt8("attack range (was karma)"));