summaryrefslogtreecommitdiff
path: root/src/net/eathena/chatrecv.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/net/eathena/chatrecv.cpp')
-rw-r--r--src/net/eathena/chatrecv.cpp11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/net/eathena/chatrecv.cpp b/src/net/eathena/chatrecv.cpp
index eb6892545..faac6f014 100644
--- a/src/net/eathena/chatrecv.cpp
+++ b/src/net/eathena/chatrecv.cpp
@@ -173,6 +173,17 @@ void ChatRecv::processFormatMessageNumber(Net::MessageIn &msg)
processChatContinue(chatMsg, ChatMsgType::BY_SERVER);
}
+void ChatRecv::processFormatMessageString(Net::MessageIn &msg)
+{
+ const int strLen = msg.readInt16("len") - 6;
+ const int msgId = msg.readInt16("msg id");
+ const std::string message = msg.readString(strLen, "value");
+ // +++ here need load message from configuration file
+ const std::string chatMsg = strprintf(
+ "Message #%d, value: %s", msgId, message.c_str());
+ processChatContinue(chatMsg, ChatMsgType::BY_SERVER);
+}
+
void ChatRecv::processFormatMessageSkill(Net::MessageIn &msg)
{
const int skillId = msg.readInt16("skill id");