GameServer constructor

GameServer(
  1. Server _io,
  2. IOServer mainServer,
  3. Reader _read,
  4. GameCode _gameId,
  5. void _onGameOver(
    1. GameCode
    ), {
  6. Duration timeout = const Duration(hours: 2),
  7. bool debug = true,
})

Implementation

GameServer(
  IO.Server _io,
  this.mainServer,
  this._read,
  this._gameId,
  this._onGameOver, {
  this.timeout = const Duration(hours: 2),
  this.debug = true,
})  : _socket = _io.of('/$_gameId'),
      _serverLogger = Logger('GameServer $_gameId') {
  _initServer();
}