From 6d5d21de014f242f1929d6afdc72a52f61655df3 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Sun, 18 Oct 2015 16:57:09 +0300 Subject: Join "option" to opt2 (status effect) for using as effects (hercules) --- src/net/eathena/beingrecv.cpp | 19 +++++++++---------- 1 file changed, 9 insertions(+), 10 deletions(-) (limited to 'src/net') diff --git a/src/net/eathena/beingrecv.cpp b/src/net/eathena/beingrecv.cpp index 690ae2552..23f731c2d 100644 --- a/src/net/eathena/beingrecv.cpp +++ b/src/net/eathena/beingrecv.cpp @@ -261,9 +261,8 @@ void BeingRecv::processBeingVisible(Net::MessageIn &msg) int16_t speed = msg.readInt16("speed"); const uint16_t stunMode = msg.readInt16("opt1"); // probably wrong effect usage - const uint32_t statusEffects = msg.readInt16("opt2"); - msg.readInt32("option"); - + uint32_t statusEffects = msg.readInt16("opt2"); + statusEffects |= (static_cast(msg.readInt32("option"))) << 16; const int16_t job = msg.readInt16("class"); Being *dstBeing = actorManager->findBeing(id); @@ -423,7 +422,7 @@ void BeingRecv::processBeingMove(Net::MessageIn &msg) // { const uint16_t stunMode = msg.readInt16("opt1"); // probably wrong effect usage - const uint32_t statusEffects = msg.readInt16("opt2"); + uint32_t statusEffects = msg.readInt16("opt2"); // } // else // { @@ -431,8 +430,7 @@ void BeingRecv::processBeingMove(Net::MessageIn &msg) // msg.readInt16("body state"); // msg.readInt16("health state"); // } - msg.readInt32("effect state"); - + statusEffects |= (static_cast(msg.readInt32("option"))) << 16; const int16_t job = msg.readInt16("class"); Being *dstBeing = actorManager->findBeing(id); @@ -594,7 +592,7 @@ void BeingRecv::processBeingSpawn(Net::MessageIn &msg) // { const uint16_t stunMode = msg.readInt16("opt1"); // probably wrong effect usage - const uint32_t statusEffects = msg.readInt16("opt2"); + uint32_t statusEffects = msg.readInt16("opt2"); // } // else // { @@ -602,8 +600,7 @@ void BeingRecv::processBeingSpawn(Net::MessageIn &msg) // msg.readInt16("body state"); // msg.readInt16("health state"); // } - msg.readInt32("effect state"); - + statusEffects |= (static_cast(msg.readInt32("option"))) << 16; const int16_t job = msg.readInt16("class"); Being *dstBeing = actorManager->findBeing(id); @@ -1179,7 +1176,7 @@ void BeingRecv::processPlaterStatusChange(Net::MessageIn &msg) const uint16_t stunMode = msg.readInt16("stun mode"); uint32_t statusEffects = msg.readInt16("status effect"); - statusEffects |= (static_cast(msg.readInt32("opt?"))) << 16; + statusEffects |= (static_cast(msg.readInt32("option"))) << 16; dstBeing->setKarma(msg.readUInt8("karma")); dstBeing->setStunMode(stunMode); @@ -1195,6 +1192,8 @@ void BeingRecv::processPlaterStatusChange2(Net::MessageIn &msg) if (!actorManager) return; + // look like this function unused on server + const BeingId id = msg.readBeingId("account id"); Being *const dstBeing = actorManager->findBeing(id); if (!dstBeing) -- cgit v1.2.3-70-g09d2