public void OnClientAccepted(object sender, SocketEventArgs e) { Console.WriteLine("[{0}] Accepted connection from {1}.", "Login", e.Socket.RemoteEndPoint.ToString()); Client Client = new Client(e.Socket, 0, 0, "Login"); Client.SessionId = Randomizer.NextLong(); Client.SendHandshake(Constants.MajorVersion, Constants.MinorVersion, Constants.Locale); Clients.Add(Client); }
private void OnClientAccepted(object sender, SocketEventArgs e) { Console.WriteLine("[{0}] Accepted connection from {1}.", Constants.WorldNames[this.Id] + " Channel " + this.Id, e.Socket.RemoteEndPoint.ToString()); Client Client = new Client(e.Socket, WorldId, Id, "Channel"); Client.SendHandshake(Constants.MajorVersion, Constants.MinorVersion, Constants.Locale); Clients.Add(Client); }