Exemplo n.º 1
0
    void Start()
    {
        // Setup
        EnemiesDestroyed = OverallEnemiesToSpawn = 0;
        playerHealth.BeforeObjectDies += () => {
            Debug.Log("Player KIA"); SpaceShooterSceneManager.LoadGameOverScene();
        };
        foreach (var barrage in MissleBarrages)
        {
            barrage.WhenEnemyRocketDiesDelegate = () => { EnemiesDestroyed++; Debug.Log("Enemy Count = " + EnemiesDestroyed); };
            OverallEnemiesToSpawn += barrage.NumberOfEnemiesToSpawn;
        }
        Debug.Log("Count = " + OverallEnemiesToSpawn);

        // -------- Start Level -------- //
        StartCoroutine(StartLevel());
    }
Exemplo n.º 2
0
 void Start()
 {
     playerHealth.BeforeObjectDies += () => { Debug.Log("Player KIA"); SpaceShooterSceneManager.LoadGameOverScene(); };
 }