diff options
author | Andrei Karas <akaras@inbox.ru> | 2017-10-15 18:37:06 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2017-10-18 16:21:43 +0300 |
commit | 8107a607f05176000630e73424cb14beae55a6f8 (patch) | |
tree | 44b384c8d7a08731dcd04a5bbbefa90f98f97801 /src/net/eathena/mail2handler.cpp | |
parent | a499c34b05b70a72572d8e43572def558403338e (diff) | |
download | manaplus-8107a607f05176000630e73424cb14beae55a6f8.tar.gz manaplus-8107a607f05176000630e73424cb14beae55a6f8.tar.bz2 manaplus-8107a607f05176000630e73424cb14beae55a6f8.tar.xz manaplus-8107a607f05176000630e73424cb14beae55a6f8.zip |
Add packets CMSG_MAIL2_OPEN_MAILBOX 0x0ac0, CMSG_MAIL2_REFRESH_MAIL_LIST 0x0ac1.
Diffstat (limited to 'src/net/eathena/mail2handler.cpp')
-rw-r--r-- | src/net/eathena/mail2handler.cpp | 30 |
1 files changed, 26 insertions, 4 deletions
diff --git a/src/net/eathena/mail2handler.cpp b/src/net/eathena/mail2handler.cpp index 2b4de04ab..13a7676d9 100644 --- a/src/net/eathena/mail2handler.cpp +++ b/src/net/eathena/mail2handler.cpp @@ -230,8 +230,19 @@ void Mail2Handler::refreshMailList(const MailOpenTypeT openType, return; } createOutPacket(CMSG_MAIL2_REFRESH_MAIL_LIST); - outMsg.writeInt8(toInt(openType, int8_t), "open type"); - outMsg.writeInt64(mailId, "mail id"); + if (packetVersion >= 20170419) + { + outMsg.writeInt64(mailId, "mail id"); + outMsg.writeInt32(0, "unknown 1"); + outMsg.writeInt32(0, "unknown 2"); + outMsg.writeInt32(0, "unknown 3"); + outMsg.writeInt32(0, "unknown 4"); + } + else + { + outMsg.writeInt8(toInt(openType, int8_t), "open type"); + outMsg.writeInt64(mailId, "mail id"); + } } void Mail2Handler::openMailBox(const MailOpenTypeT openType) const @@ -242,8 +253,19 @@ void Mail2Handler::openMailBox(const MailOpenTypeT openType) const return; } createOutPacket(CMSG_MAIL2_OPEN_MAILBOX); - outMsg.writeInt8(toInt(openType, int8_t), "open type"); - outMsg.writeInt64(0, "mail id"); + if (packetVersion >= 20170419) + { + outMsg.writeInt64(0, "mail id"); + outMsg.writeInt32(0, "unknown 1"); + outMsg.writeInt32(0, "unknown 2"); + outMsg.writeInt32(0, "unknown 3"); + outMsg.writeInt32(0, "unknown 4"); + } + else + { + outMsg.writeInt8(toInt(openType, int8_t), "open type"); + outMsg.writeInt64(0, "mail id"); + } } void Mail2Handler::closeMailBox() const |