private IEnumerable <Player> BuildPlayers(GameScope gameScope, GameSpec spec) { return(spec.Players .Select(playerSpec => gameScope.PlayerBuilder.ForSpec(playerSpec)) .Select(dummy => (Player)dummy).ToList()); }
public Game(GameScope gameScope, IEnumerable <Player> players) : this(gameScope.EventAggregator, gameScope.SupplyBuilder, players, gameScope.EndGameConditions, gameScope.Container) { }
public Game Initialize(GameSpec spec, GameScope scope) { scope.SupplyBuilder.WithGameSpec(spec); return(new Game(scope, BuildPlayers(scope, spec))); }