Beispiel #1
0
 public KNet_Client(IPAddress host, ushort port)
 {
     if (!KNet.SetClient(this))
     {
         isShutdownRequested = true;
         throw new Exception("Cannot start a Client when one already exists!");
     }
     this.host = new IPEndPoint(host, port);
 }
Beispiel #2
0
        public KNet_Client(IPAddress host, ushort port, string username, string passwordHash)
        {
            if (!KNet.SetClient(this))
            {
                isShutdownRequested = true;
                throw new Exception("Cannot start a Client when one already exists!");
            }

            Start(host, port, username, passwordHash);
        }