diff options
author | Andrei Karas <akaras@inbox.ru> | 2014-09-05 13:17:59 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2014-09-06 01:18:57 +0300 |
commit | 256d936b71d500fc14ee52c7f55959fc65b289ac (patch) | |
tree | 3ea681387225bfa5c94e251d86ba48ae5afbfb18 /src/net/tmwa/beinghandler.cpp | |
parent | 07d993ed7cfa78bc5316bfb5b3ab27158925326a (diff) | |
download | manaverse-256d936b71d500fc14ee52c7f55959fc65b289ac.tar.gz manaverse-256d936b71d500fc14ee52c7f55959fc65b289ac.tar.bz2 manaverse-256d936b71d500fc14ee52c7f55959fc65b289ac.tar.xz manaverse-256d936b71d500fc14ee52c7f55959fc65b289ac.zip |
Move processBeingStatusChange from ea namespace into eathena and tmwa.
Diffstat (limited to 'src/net/tmwa/beinghandler.cpp')
-rw-r--r-- | src/net/tmwa/beinghandler.cpp | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/src/net/tmwa/beinghandler.cpp b/src/net/tmwa/beinghandler.cpp index af71491d3..426ed7a24 100644 --- a/src/net/tmwa/beinghandler.cpp +++ b/src/net/tmwa/beinghandler.cpp @@ -999,4 +999,24 @@ void BeingHandler::processSkillCasting(Net::MessageIn &msg) const msg.readInt32("cast time"); } +void BeingHandler::processBeingStatusChange(Net::MessageIn &msg) const +{ + BLOCK_START("BeingHandler::processBeingStatusChange") + if (!actorManager) + { + BLOCK_END("BeingHandler::processBeingStatusChange") + return; + } + + // Status change + const uint16_t status = msg.readInt16("status"); + const int id = msg.readInt32("being id"); + const bool flag = msg.readUInt8("flag: 0: stop, 1: start"); + + Being *const dstBeing = actorManager->findBeing(id); + if (dstBeing) + dstBeing->setStatusEffect(status, flag); + BLOCK_END("BeingHandler::processBeingStatusChange") +} + } // namespace TmwAthena |