//

        private void _socket_OnError(object sender, ErrorEventArgs e)
        {
            MonoHelper.InvokeOnMainThread(() =>
            {
                Debug.LogException(e.Exception);
            });
        }
Exemple #2
0
 private void _socket_OnMessage(object sender, MessageEventArgs e)
 {
     MonoHelper.InvokeOnMainThread(() =>
     {
         ChatModel model = JsonUtility.FromJson <ChatModel>(e.Data);
         OnChat(model);
     });
 }
        private void _socket_OnMessage(object sender, MessageEventArgs e)
        {
            Debug.Log("hgv");
            MonoHelper.InvokeOnMainThread(() =>
            {
                ChatModel model = JsonUtility.FromJson <ChatModel>(e.Data);

                ChatService.call(model);
            });
        }
 private void _socket_OnClose(object sender, CloseEventArgs e)
 {
     MonoHelper.InvokeOnMainThread(OnClose);
 }
 private void _socket_OnOpen(object sender, EventArgs e)
 {
     MonoHelper.InvokeOnMainThread(OnOpen);
 }