Example #1
0
        public ClientWrapper(TcpClient client)
        {
            TcpClient = client;
            if (client != null)
            {
                ThreadPool = new MyThreadPool();
                ThreadPool.LaunchThread(ThreadRun);

                var bytes = new byte[8];
                Globals.Rand.NextBytes(bytes);
                ConnectionId = Encoding.ASCII.GetString(bytes).Replace("-", "");
            }
        }
Example #2
0
        public ClientWrapper(TcpClient client)
        {
            TcpClient = client;
            if (client != null)
            {
                ThreadPool = new MyThreadPool();
                ThreadPool.LaunchThread(ThreadRun);

                var bytes = new byte[8];
                Globals.Rand.NextBytes(bytes);
                ConnectionId = Encoding.ASCII.GetString(bytes).Replace("-", "");
            }
        }