summaryrefslogtreecommitdiff
path: root/src/net/eathena/beingrecv.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2016-04-02 01:17:49 +0300
committerAndrei Karas <akaras@inbox.ru>2016-04-02 01:17:49 +0300
commit3e49b4ca2f6de3c1ccc7503489cdbea5614ed673 (patch)
tree984894a3b4c1ab5a2c167f3f64dc635ac6bd713c /src/net/eathena/beingrecv.cpp
parentd16d311387932e62e06bf6940b3ac1be26b8c6af (diff)
downloadmv-3e49b4ca2f6de3c1ccc7503489cdbea5614ed673.tar.gz
mv-3e49b4ca2f6de3c1ccc7503489cdbea5614ed673.tar.bz2
mv-3e49b4ca2f6de3c1ccc7503489cdbea5614ed673.tar.xz
mv-3e49b4ca2f6de3c1ccc7503489cdbea5614ed673.zip
Sort more packets. Add version checks inside packets.
Diffstat (limited to 'src/net/eathena/beingrecv.cpp')
-rw-r--r--src/net/eathena/beingrecv.cpp20
1 files changed, 5 insertions, 15 deletions
diff --git a/src/net/eathena/beingrecv.cpp b/src/net/eathena/beingrecv.cpp
index be49cd625..e037f444d 100644
--- a/src/net/eathena/beingrecv.cpp
+++ b/src/net/eathena/beingrecv.cpp
@@ -1199,7 +1199,11 @@ void BeingRecv::processPlayerStatusChange(Net::MessageIn &msg)
const uint32_t opt1 = msg.readInt16("opt1");
const uint32_t opt2 = msg.readInt16("opt2");
- const uint32_t option = msg.readInt32("option");
+ uint32_t option;
+ if (msg.getVersion() >= 7)
+ option = msg.readInt32("option");
+ else
+ option = msg.readInt16("option");
dstBeing->setKarma(msg.readUInt8("karma"));
dstBeing->setStatusEffectOpitons(option,
@@ -1226,20 +1230,6 @@ void BeingRecv::processPlayerStatusChange2(Net::MessageIn &msg)
dstBeing->setStatusEffectOpiton0(option);
}
-void BeingRecv::processPlayerStatusChangeNoTick(Net::MessageIn &msg)
-{
- const uint16_t status = msg.readInt16("index");
- const BeingId id = msg.readBeingId("account id");
- const Enable flag = fromBool(msg.readUInt8("state")
- ? true : false, Enable);
-
- Being *const dstBeing = actorManager->findBeing(id);
- if (!dstBeing)
- return;
-
- dstBeing->setStatusEffect(status, flag);
-}
-
void BeingRecv::processBeingResurrect(Net::MessageIn &msg)
{
BLOCK_START("BeingRecv::processBeingResurrect")