diff options
author | Andrei Karas <akaras@inbox.ru> | 2015-08-22 23:05:32 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2015-08-22 23:05:32 +0300 |
commit | 31aad897b3bd0951bb9c0eb34bd8636fdfdfa87c (patch) | |
tree | eff25e4c406675e19a6c40c727c828f040a8eeed /src/net/eathena | |
parent | 7f716b84fcad512a49e3122bc1bc49f3c5437cc8 (diff) | |
download | manaverse-31aad897b3bd0951bb9c0eb34bd8636fdfdfa87c.tar.gz manaverse-31aad897b3bd0951bb9c0eb34bd8636fdfdfa87c.tar.bz2 manaverse-31aad897b3bd0951bb9c0eb34bd8636fdfdfa87c.tar.xz manaverse-31aad897b3bd0951bb9c0eb34bd8636fdfdfa87c.zip |
Impliment packet SMSG_IGNORE_NICK_ACK.
Diffstat (limited to 'src/net/eathena')
-rw-r--r-- | src/net/eathena/chathandler.cpp | 46 |
1 files changed, 43 insertions, 3 deletions
diff --git a/src/net/eathena/chathandler.cpp b/src/net/eathena/chathandler.cpp index 5d5e889d9..13dd438d8 100644 --- a/src/net/eathena/chathandler.cpp +++ b/src/net/eathena/chathandler.cpp @@ -378,9 +378,49 @@ void ChatHandler::unIgnore(const std::string &nick) const void ChatHandler::processIgnoreNickAck(Net::MessageIn &msg) { - UNIMPLIMENTEDPACKET; - msg.readUInt8("type"); - msg.readUInt8("flag"); + const int type = msg.readUInt8("type"); + const int flag = msg.readUInt8("flag"); + switch (type) + { + case 0: + switch (flag) + { + case 0: + NotifyManager::notify(NotifyTypes::IGNORE_PLAYER_SUCCESS); + break; + case 1: + NotifyManager::notify(NotifyTypes::IGNORE_PLAYER_FAILURE); + break; + case 2: + NotifyManager::notify(NotifyTypes::IGNORE_PLAYER_TOO_MANY); + break; + default: + NotifyManager::notify(NotifyTypes::IGNORE_PLAYER_UNKNOWN); + break; + } + break; + case 1: + switch (flag) + { + case 0: + NotifyManager::notify( + NotifyTypes::UNIGNORE_PLAYER_SUCCESS); + break; + case 1: + NotifyManager::notify( + NotifyTypes::UNIGNORE_PLAYER_FAILURE); + break; + default: + NotifyManager::notify( + NotifyTypes::UNIGNORE_PLAYER_UNKNOWN); + break; + } + break; + + default: + NotifyManager::notify(NotifyTypes::IGNORE_PLAYER_TYPE_UNKNOWN); + break; + } } void ChatHandler::requestIgnoreList() const |