示例#1
0
文件: Server.cs 项目: clavalle/OCTGN
 // Creates and starts a new server
 public Server(IGameStateEngine stateEngine)
 {
     GameStateEngine.Set(stateEngine);
     _tcp               = new TcpListener(IPAddress.Any, stateEngine.Game.HostUri.Port);
     _handler           = new Handler(stateEngine.Game.GameId, stateEngine.Game.GameVersion);
     _connectionChecker = new Thread(CheckConnections);
     _connectionChecker.Start();
     Start();
 }
示例#2
0
文件: Server.cs 项目: totalgit/OCTGN
 // Creates and starts a new server
 public Server(IGameStateEngine stateEngine)
 {
     GameStateEngine.Set(stateEngine);
     Log.InfoFormat("Creating server {0}", stateEngine.Game.HostUri);
     _tcp               = new TcpListener(IPAddress.Any, stateEngine.Game.HostUri.Port);
     _handler           = new Handler(stateEngine.Game.GameId, stateEngine.Game.GameVersion, stateEngine.Game.Password);
     _connectionChecker = new Thread(CheckConnections);
     _connectionChecker.Start();
     Start();
 }