Пример #1
0
 public bool Connect(string _host, int _port)
 {
     this.Close();
     host     = _host;
     port     = _port;
     m_socket = this.NewSocket();
     m_socket.Reset(host, port);
     m_state = NetAgentState.Connecting;
     return(m_socket.ConnectAsync(OnSocketOpen, OnSocketRecvData, OnSocketClose));
 }