Make chat bot really kick players.

This commit is contained in:
lotodore
2010-07-14 16:13:18 +00:00
parent dad7c694ce
commit 9248f5a15e
3 changed files with 19 additions and 1 deletions
+6 -1
View File
@@ -250,7 +250,12 @@ ChatCleanerManager::HandleMessage(InternalChatCleanerPacket &msg)
else if (msg.GetMsg()->present == ChatCleanerMessage_PR_cleanerChatReplyMessage)
{
CleanerChatReplyMessage_t *netReply = &msg.GetMsg()->choice.cleanerChatReplyMessage;
m_callback.SignalChatBotMessage(string((const char *)netReply->cleanerText->buf, netReply->cleanerText->size));
if (netReply->cleanerText)
m_callback.SignalChatBotMessage(string((const char *)netReply->cleanerText->buf, netReply->cleanerText->size));
if (netReply->cleanerActionType == cleanerActionType_cleanerActionKick)
m_callback.SignalKickPlayer(netReply->playerId);
else if (netReply->cleanerActionType == cleanerActionType_cleanerActionBan)
m_callback.SignalBanPlayer(netReply->playerId);
error = false;
}
return error;