summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2018-09-26 03:06:42 +0300
committerAndrei Karas <akaras@inbox.ru>2018-09-26 03:06:42 +0300
commit89068d61b30e19f69f53df05b0542c37c12397ea (patch)
tree629a90c68ab05a8c492aeda1136de62af7866395
parent40895672b5bbb32192c3e36c8fcd3125e2c9baf2 (diff)
downloadplus-89068d61b30e19f69f53df05b0542c37c12397ea.tar.gz
plus-89068d61b30e19f69f53df05b0542c37c12397ea.tar.bz2
plus-89068d61b30e19f69f53df05b0542c37c12397ea.tar.xz
plus-89068d61b30e19f69f53df05b0542c37c12397ea.zip
Add packet SMSG_PARTY_MEMBER_DEAD 0x0ab2.
-rw-r--r--src/net/eathena/packetsin.inc5
-rw-r--r--src/net/eathena/partyrecv.cpp11
-rw-r--r--src/net/eathena/partyrecv.h1
3 files changed, 16 insertions, 1 deletions
diff --git a/src/net/eathena/packetsin.inc b/src/net/eathena/packetsin.inc
index f292dc276..10b4eafbf 100644
--- a/src/net/eathena/packetsin.inc
+++ b/src/net/eathena/packetsin.inc
@@ -1086,13 +1086,15 @@ if (packetVersionRe >= 20170502)
{
packet(SMSG_PARTY_MEMBER_INFO, 0x0a43, 85, &PartyRecv::processPartyMemberInfo, 20170502);
packet(SMSG_PARTY_INFO, 0x0a44, -1, &PartyRecv::processPartyInfo, 20170502);
+ packet(SMSG_PARTY_MEMBER_DEAD, 0x0ab2, 7, &PartyRecv::processPartyMemberDead, 20170502);
}
-// 20170524 re
+// 20170524 main
if (packetVersionMain >= 20170524)
{
packet(SMSG_PARTY_MEMBER_INFO, 0x0a43, 85, &PartyRecv::processPartyMemberInfo, 20170524);
packet(SMSG_PARTY_INFO, 0x0a44, -1, &PartyRecv::processPartyInfo, 20170524);
+ packet(SMSG_PARTY_MEMBER_DEAD, 0x0ab2, 7, &PartyRecv::processPartyMemberDead, 20170524);
}
// 20170315
@@ -1129,6 +1131,7 @@ if (packets_zero == true)
packet(SMSG_MVP_EXP, 0x010b, 6, &ChatRecv::processMVPExp, 20171018);
packet(SMSG_GUILD_EXPULSION2, 0x0a82, 46, &GuildRecv::processGuildExpulsion2, 20171018);
packet(SMSG_GUILD_LEAVE2, 0x0a83, 46, &GuildRecv::processGuildLeave2, 20171018);
+ packet(SMSG_PARTY_MEMBER_DEAD, 0x0ab2, 7, &PartyRecv::processPartyMemberDead, 20171018);
}
// 20171019 zero
diff --git a/src/net/eathena/partyrecv.cpp b/src/net/eathena/partyrecv.cpp
index 93e28e944..21b97dfad 100644
--- a/src/net/eathena/partyrecv.cpp
+++ b/src/net/eathena/partyrecv.cpp
@@ -434,4 +434,15 @@ void PartyRecv::processPartyAutoItemSettingsContinue(Net::MessageIn &msg,
}
}
+void PartyRecv::processPartyMemberDead(Net::MessageIn &msg)
+{
+ const BeingId id = msg.readBeingId("account id");
+ const int isDead = msg.readUInt8("is dead");
+ PartyMember *const member = Ea::taParty->getMember(id);
+ if (member != nullptr && isDead != 0)
+ {
+ member->setHp(0);
+ }
+}
+
} // namespace EAthena
diff --git a/src/net/eathena/partyrecv.h b/src/net/eathena/partyrecv.h
index 5cf7f3868..162108b86 100644
--- a/src/net/eathena/partyrecv.h
+++ b/src/net/eathena/partyrecv.h
@@ -45,6 +45,7 @@ namespace EAthena
void processPartyLeader(Net::MessageIn &msg);
void processPartyInvited(Net::MessageIn &msg);
void processPartyMemberJobLevel(Net::MessageIn &msg);
+ void processPartyMemberDead(Net::MessageIn &msg);
void processPartyAutoItemSettingsContinue(Net::MessageIn &msg,
const PartyShareT item);