Пример #1
0
            public void LaunchLoop()
            {
                CombatResults results = new CombatResults();

                do
                {
                    results = _scene.Execute();
                } while (results.Winner == Robot.Team.None);

                Console.Clear();
                Console.WriteLine(results.Winner + " team won.");
                Console.ReadKey(true);
            }
Пример #2
0
        protected override CombatResults Update()
        {
            CombatResults results = new CombatResults();

            foreach (Robot robot in _teamRoster.AllRobots)
            {
                _redTeamTurn.RobotTakeTurn(robot);
                if (CombatTurn.winningTeam != Robot.Team.None)
                {
                    results.Winner = CombatTurn.winningTeam;
                    break;
                }
            }

            return(results);
        }