summaryrefslogtreecommitdiff
path: root/src/net/eathena/partyrecv.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2017-06-28 01:18:36 +0300
committerAndrei Karas <akaras@inbox.ru>2017-06-28 02:33:43 +0300
commit6c8aa7542d4b133eaeb32855c6ab4a3006d95f8d (patch)
tree11e9ac3c618606fea83108b18981867335616cbf /src/net/eathena/partyrecv.cpp
parente24f650a1271ecabe5ffa0a1f810cf0fa133f395 (diff)
downloadmanaplus-6c8aa7542d4b133eaeb32855c6ab4a3006d95f8d.tar.gz
manaplus-6c8aa7542d4b133eaeb32855c6ab4a3006d95f8d.tar.bz2
manaplus-6c8aa7542d4b133eaeb32855c6ab4a3006d95f8d.tar.xz
manaplus-6c8aa7542d4b133eaeb32855c6ab4a3006d95f8d.zip
Add packet SMSG_PARTY_MEMBER_JOB_LEVEL 0x0abd.
Diffstat (limited to 'src/net/eathena/partyrecv.cpp')
-rw-r--r--src/net/eathena/partyrecv.cpp24
1 files changed, 24 insertions, 0 deletions
diff --git a/src/net/eathena/partyrecv.cpp b/src/net/eathena/partyrecv.cpp
index c3cbd102c..e820a0eac 100644
--- a/src/net/eathena/partyrecv.cpp
+++ b/src/net/eathena/partyrecv.cpp
@@ -37,6 +37,8 @@
#include "net/ea/partyrecv.h"
+#include "utils/checkutils.h"
+
#include "debug.h"
namespace EAthena
@@ -90,6 +92,28 @@ void PartyRecv::processPartyMemberInfo(Net::MessageIn &msg)
}
}
+void PartyRecv::processPartyMemberJobLevel(Net::MessageIn &msg)
+{
+ const BeingId id = msg.readBeingId("account id");
+ msg.readInt16("class");
+ const int level = msg.readInt16("level");
+
+ if (Ea::taParty == nullptr)
+ return;
+
+ PartyMember *const member = Ea::taParty->getMember(id);
+ if (member != nullptr)
+ {
+ member->setOnline(true);
+ if (level != 0)
+ member->setLevel(level);
+ }
+ else
+ {
+ reportAlways("processPartyMemberJobLevel: party member not exists.");
+ }
+}
+
void PartyRecv::processPartySettings(Net::MessageIn &msg)
{
if (partyTab == nullptr)