From 8d9174b86d85474f3ebd6314232864c8d0c575ce Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Thu, 24 Oct 2013 20:20:20 +0300 Subject: add option to show motd message. Disabled by default. --- src/net/ea/chathandler.cpp | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'src/net/ea/chathandler.cpp') diff --git a/src/net/ea/chathandler.cpp b/src/net/ea/chathandler.cpp index 90c6be5bc..deaef6984 100644 --- a/src/net/ea/chathandler.cpp +++ b/src/net/ea/chathandler.cpp @@ -47,7 +47,8 @@ namespace Ea ChatHandler::ChatHandler() : mSentWhispers(), - mShowAllLang(serverConfig.getValue("showAllLang", 0)) + mShowAllLang(serverConfig.getValue("showAllLang", 0)), + mShowMotd(config.getBoolValue("showmotd")) { } @@ -355,7 +356,10 @@ void ChatHandler::processChat(Net::MessageIn &msg, const bool normalChat, trim(chatMsg); if (player_node) - player_node->setSpeech(chatMsg, channel); + { + if (chatWindow || mShowMotd) + player_node->setSpeech(chatMsg, channel); + } } else if (localChatTab) { -- cgit v1.2.3-70-g09d2