示例#1
0
 public void OnConnected(SocketError err)
 {
     if (err == SocketError.Success)
     {
         Debug.Log("连接");
         var msg = new mmopb.login_ack();
         msg.error = "Hello!";
         tcpConnection.Send(ProtoHelper.EncodeWithName(msg));
     }
 }
示例#2
0
 public void SendMessage(object o)
 {
     tcpConnection.Send(ProtoHelper.EncodeWithName(o));
 }