Пример #1
0
        private void GenerateEnemies()
        {
            Validator.CheckIfHeroExist(Field.Hero);
            BattleField.Enemies = new List <Enemy>();
            bool isAllEnemiesAreKilled = true;

            if (BattleField.AttackedEnemies[EnemyType.Ghoul] < 3)
            {
                BattleField.Enemies.Add(EnemyFactory.Enemy(EnemyType.Ghoul));
                isAllEnemiesAreKilled = false;
            }

            if (BattleField.AttackedEnemies[EnemyType.Hydra] < 3)
            {
                BattleField.Enemies.Add(EnemyFactory.Enemy(EnemyType.Hydra));
                isAllEnemiesAreKilled = false;
            }

            if (BattleField.AttackedEnemies[EnemyType.Supremus] < 3)
            {
                BattleField.Enemies.Add(EnemyFactory.Enemy(EnemyType.Supremus));
                isAllEnemiesAreKilled = false;
            }

            if (BattleField.AttackedEnemies[EnemyType.Rotface] < 3)
            {
                BattleField.Enemies.Add(EnemyFactory.Enemy(EnemyType.Rotface));
                isAllEnemiesAreKilled = false;
            }

            if (BattleField.AttackedEnemies[EnemyType.Lichking] < 3)
            {
                BattleField.Enemies.Add(EnemyFactory.Enemy(EnemyType.Lichking));
                isAllEnemiesAreKilled = false;
            }

            if (isAllEnemiesAreKilled)
            {
                BattleField.Enemies.Add(EnemyFactory.Enemy(EnemyType.Deathwing));
            }
        }