Ejemplo n.º 1
0
 private void REQ_CHAT_TRANSMIT(ConnectController controller, string msg)
 {
     mainVM.AddChatText(controller.UserNickname, controller.UserNicknameColor, controller.UserChatColor, msg);
     // 연결된 클라이언트들 Send Message
     for (int i = 0; i < connectControllers.Count; ++i)
     {
         string message = $"{controller.UserNickname},{controller.UserNicknameColor},{controller.UserChatColor},{msg}";
         MessageUtil.Instance.SendMessage(SEND_TO_CLIENT_DEFINE.SEND_CHAT_TRANSMIT, message, connectControllers[i].transmitStream);
     }
 }
Ejemplo n.º 2
0
 /// <summary>
 /// msg는 닉네임, 닉네임색상, 채팅색상, 채팅내용으로 분리되어 CSV형태로 전달
 /// </summary>
 /// <param name="controller"></param>
 /// <param name="msg"></param>
 private void SEND_CHAT_TRANSMIT(ConnectController controller, string msg)
 {
     string[] splitedMSG = msg.Split(',');
     mainVM.AddChatText(splitedMSG[0], splitedMSG[1], splitedMSG[2], splitedMSG[3]);
 }