summaryrefslogtreecommitdiff
path: root/src/net
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2015-01-22 22:13:52 +0300
committerAndrei Karas <akaras@inbox.ru>2015-01-22 22:13:52 +0300
commitb15ba753670a0a1431f4e89acd76163230ebd9e8 (patch)
tree766232542e25ec649de4f3b2f706720e90bd84cd /src/net
parentfc70de9b9d4ae04b1748a27474cc0e1c03e07f05 (diff)
downloadmv-b15ba753670a0a1431f4e89acd76163230ebd9e8.tar.gz
mv-b15ba753670a0a1431f4e89acd76163230ebd9e8.tar.bz2
mv-b15ba753670a0a1431f4e89acd76163230ebd9e8.tar.xz
mv-b15ba753670a0a1431f4e89acd76163230ebd9e8.zip
eathena: fix packet SMSG_PLAYER_STATUS_CHANGE_NO_TICK.
Diffstat (limited to 'src/net')
-rw-r--r--src/net/eathena/beinghandler.cpp13
1 files changed, 9 insertions, 4 deletions
diff --git a/src/net/eathena/beinghandler.cpp b/src/net/eathena/beinghandler.cpp
index 49fc8cd77..be7899830 100644
--- a/src/net/eathena/beinghandler.cpp
+++ b/src/net/eathena/beinghandler.cpp
@@ -1411,10 +1411,15 @@ void BeingHandler::processPlaterStatusChange2(Net::MessageIn &msg)
void BeingHandler::processPlaterStatusChangeNoTick(Net::MessageIn &msg)
{
- // +++ probably need show some effect?
- msg.readInt16("index");
- msg.readInt32("account id");
- msg.readUInt8("state");
+ const uint16_t status = msg.readInt16("index");
+ const int id = msg.readInt32("account id");
+ const bool flag = msg.readUInt8("state") ? 1 : 0;
+
+ Being *const dstBeing = actorManager->findBeing(id);
+ if (!dstBeing)
+ return;
+
+ dstBeing->setStatusEffect(status, flag);
}
void BeingHandler::processBeingResurrect(Net::MessageIn &msg)