public UpperRedStationModel(Game game) : base(game, StationLocation.UpperRed)
 {
     if (game.SittingDuck.RedZone.UpperRedStation.InterceptorComponent.Interceptors != null)
     {
         Interceptors = new InterceptorsModel();
     }
 }
Example #2
0
        public PlayerModel(Player player)
        {
            Index           = player.Index;
            StationLocation = player.CurrentStation.StationLocation;
            HasBattleBots   = player.BattleBots != null;
            PlayerColor     = player.PlayerColor;
            if (player.BattleBots != null)
            {
                BattleBots = new BattleBotsModel(player.BattleBots);
            }
            Actions = player.Actions.Select(action => ActionModelFactory.Create(action, player)).ToList();
            if (player.Interceptors != null)
            {
                Interceptors = new InterceptorsModel();
            }
            PlayerSpecialization = player.Specialization;

            //Uncomment this to get battle bots in turn 1 on the client.
            //else if (player.PlayerColor == PlayerColor.Red || player.PlayerColor == PlayerColor.Green)
            //    BattleBots = new BattleBotsModel(new BattleBots());
        }