Пример #1
0
 private void DestroyEnemies(EnemyInitialPoint point)
 {
     for (int i = point.enemies.Count - 1; i >= 0; i--)
     {
         point.enemies[i].DestroyRider();
         Destroy(point.enemies[i].gameObject);
         point.enemies.Remove(point.enemies[i]);
     }
 }
Пример #2
0
 private void SpawnEnemies(EnemyInitialPoint point)
 {
     //foreach (EnemyInitialPoint point in EnemyInitialPoints)
     {
         for (int i = 0; i < point.NumberOfEnemies; i++)
         {
             var enemy = gameFactory.CreateEnemy(point.CalculateSpawnPosition());
             point.enemies.Add(enemy);
         }
     }
 }
Пример #3
0
 private void SpawnOnTrigger(EnemyInitialPoint point)
 {
     SpawnEnemies(point);
 }