AddClient() static private method

static private AddClient ( NetworkClient client ) : void
client NetworkClient
return void
 public NetworkClient()
 {
     if (LogFilter.logDev)
     {
         Debug.Log("Client created version " + Version.Current);
     }
     this.m_MsgBuffer = new byte[65535];
     this.m_MsgReader = new NetworkReader(this.m_MsgBuffer);
     NetworkClient.AddClient(this);
 }
Example #2
0
 /// <summary>
 ///   <para>Creates a new NetworkClient instance.</para>
 /// </summary>
 public NetworkClient()
 {
     if (LogFilter.logDev)
     {
         Debug.Log((object)("Client created version " + (object)Version.Current));
     }
     this.m_MsgBuffer = new byte[(int)ushort.MaxValue];
     this.m_MsgReader = new NetworkReader(this.m_MsgBuffer);
     NetworkClient.AddClient(this);
 }
 public NetworkClient(NetworkConnection conn)
 {
     if (LogFilter.logDev)
     {
         Debug.Log("Client created version " + Version.Current);
     }
     this.m_MsgBuffer = new byte[65535];
     this.m_MsgReader = new NetworkReader(this.m_MsgBuffer);
     NetworkClient.AddClient(this);
     NetworkClient.SetActive(true);
     this.m_Connection   = conn;
     this.m_AsyncConnect = NetworkClient.ConnectState.Connected;
     conn.SetHandlers(this.m_MessageHandlers);
     this.RegisterSystemHandlers(false);
 }