少年修仙传客户端代码仓库
client_Wu Xijin
2018-08-24 d4b711bcc9a9e71c5835276f8ac5130329707da5
System/Chat/ChatCtrl.cs
@@ -206,9 +206,51 @@
        ClearAllChatInfo();
    }
    void ChatReport(ChatInfoType chatType, string content, string toPlayer)
    {
        try
        {
            var channelName = string.Empty;
            switch (chatType)
            {
                case ChatInfoType.World:
                    channelName = Language.Get("ChatType_World");
                    break;
                case ChatInfoType.Area:
                    channelName = Language.Get("ChatType_Area");
                    break;
                case ChatInfoType.Team:
                    channelName = Language.Get("ChatType_Team");
                    break;
                case ChatInfoType.Invite:
                    channelName = Language.Get("ChatType_Invite");
                    break;
                case ChatInfoType.Trumpet:
                    channelName = Language.Get("ChatType_Trumpet");
                    break;
                case ChatInfoType.Fairy:
                    channelName = Language.Get("ChatType_Fairy");
                    break;
                case ChatInfoType.Friend:
                    channelName = Language.Get("PlayerDetail_PrivateChat");
                    break;
                default:
                    return;
            }
            OperationLogCollect.Instance.ChatReport(content, channelName, toPlayer);
        }
        catch (Exception e)
        {
            DebugEx.Log(e.Message);
        }
    }
    public void SendChatInfo(ChatInfoType type, string msg, ChatExtraData? info = null)
    {
        bool _dirty = false;
        ChatReport(type, msg, PteChatName);
        if (!ChatCenter.s_VoiceRegex.IsMatch(msg))
        {
            _dirty = DirtyWordConfig.IsDirtWord(msg);