Пример #1
0
        public Battle()
        {
            _field = new Battlefield();
            _field.Status = Battlefield.BattleStatus.Active;

            _commandManager = new CommandManager(_field);
            _commandManager.CommandEvent += HandleCommand;

            _availableStrategies = new List<MilitaryStrategy>(3);
            LoadAvailableStrategies();
            if (_availableStrategies.Count == 0)
                throw new Exception("No available strategies.");

            _currentStrategy = _availableStrategies[0];

            _interrupt = new BattleInterruptController(_field, 10);
        }
Пример #2
0
 public void ChangeStrategy(Int32 index)
 {
     _currentStrategy = _availableStrategies[index];
 }