diff options
author | Andrei Karas <akaras@inbox.ru> | 2014-09-07 21:02:57 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2014-09-07 21:02:57 +0300 |
commit | ade52fa9b4255a9031ab4d567606f0d22ea6089c (patch) | |
tree | 29bd5e0759d967e67f73c0ebb76c05a5d31fe2b5 /src | |
parent | 9ca0103f281a176af021197496fd2bd6f65ba05b (diff) | |
download | manaverse-ade52fa9b4255a9031ab4d567606f0d22ea6089c.tar.gz manaverse-ade52fa9b4255a9031ab4d567606f0d22ea6089c.tar.bz2 manaverse-ade52fa9b4255a9031ab4d567606f0d22ea6089c.tar.xz manaverse-ade52fa9b4255a9031ab4d567606f0d22ea6089c.zip |
eathena: fix packet SMSG_PARTY_MESSAGE 0x0109.
Diffstat (limited to 'src')
-rw-r--r-- | src/net/eathena/partyhandler.cpp | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/net/eathena/partyhandler.cpp b/src/net/eathena/partyhandler.cpp index 265f4cc0e..6748666c0 100644 --- a/src/net/eathena/partyhandler.cpp +++ b/src/net/eathena/partyhandler.cpp @@ -387,8 +387,12 @@ void PartyHandler::processPartyMessage(Net::MessageIn &msg) const if (msgLength <= 0) return; - const int id = msg.readInt32(); - const std::string chatMsg = msg.readString(msgLength); + const int id = msg.readInt32("id"); + std::string chatMsg = msg.readString(msgLength, "message"); + + const size_t pos = chatMsg.find(" : ", 0); + if (pos != std::string::npos) + chatMsg.erase(0, pos + 3); if (Ea::taParty && Ea::partyTab) { |