summaryrefslogtreecommitdiff
path: root/src/net/eathena/chathandler.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2014-09-07 15:40:45 +0300
committerAndrei Karas <akaras@inbox.ru>2014-09-07 15:42:57 +0300
commit201d66ca502db6602911ce69288d2adb975bba2d (patch)
tree8acab2d3a1c73734f16c2024356d810b01bdfa4a /src/net/eathena/chathandler.cpp
parentee5643e7412f366241568fb206a75715f9902aa3 (diff)
downloadmanaplus-201d66ca502db6602911ce69288d2adb975bba2d.tar.gz
manaplus-201d66ca502db6602911ce69288d2adb975bba2d.tar.bz2
manaplus-201d66ca502db6602911ce69288d2adb975bba2d.tar.xz
manaplus-201d66ca502db6602911ce69288d2adb975bba2d.zip
Move processWhisper from ea namespace into eathena and tmwa.
Diffstat (limited to 'src/net/eathena/chathandler.cpp')
-rw-r--r--src/net/eathena/chathandler.cpp15
1 files changed, 15 insertions, 0 deletions
diff --git a/src/net/eathena/chathandler.cpp b/src/net/eathena/chathandler.cpp
index 1a5006166..f10f8fcfb 100644
--- a/src/net/eathena/chathandler.cpp
+++ b/src/net/eathena/chathandler.cpp
@@ -312,4 +312,19 @@ void ChatHandler::processChat(Net::MessageIn &msg)
BLOCK_END("ChatHandler::processChat")
}
+void ChatHandler::processWhisper(Net::MessageIn &msg) const
+{
+ BLOCK_START("ChatHandler::processWhisper")
+ const int chatMsgLength = msg.readInt16("len") - 28;
+ std::string nick = msg.readString(24, "nick");
+
+ if (chatMsgLength <= 0)
+ {
+ BLOCK_END("ChatHandler::processWhisper")
+ return;
+ }
+
+ processWhisperContinue(nick, msg.readString(chatMsgLength, "message"));
+}
+
} // namespace EAthena