diff options
author | Andrei Karas <akaras@inbox.ru> | 2015-01-22 22:13:52 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2015-01-22 22:13:52 +0300 |
commit | b15ba753670a0a1431f4e89acd76163230ebd9e8 (patch) | |
tree | 766232542e25ec649de4f3b2f706720e90bd84cd /src/net/eathena/beinghandler.cpp | |
parent | fc70de9b9d4ae04b1748a27474cc0e1c03e07f05 (diff) | |
download | mv-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/eathena/beinghandler.cpp')
-rw-r--r-- | src/net/eathena/beinghandler.cpp | 13 |
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) |