Esempio n. 1
0
    public void StartBossFight()
    {
        AudioSources.instance.PlayMusic((int)AudiosMusic.CombatTheme);
        Invoke("PlayVoice", 0.9f);
        Debug.Log("start boss fight");
        turretsManager.RestartBossCombat();

        isAwaken = true;
        //if (rocketSpawnManager != null)
        //{
        //    GameObject prefab;
        //    prefab = (GameObject)Instantiate(rocketSpawnManager);
        //    prefab.name = "RocketSpawnManager";
        //}
        UpdateHpSlider();

        canvasGO.SetActive(true);
        if (bossCam)
        {
            bossCam.StartFollowing();
        }
        if (bossPhases.Length > 0)
        {
            currentPhaseId = 0;
            currentPhase   = bossPhases[currentPhaseId];
            currentPhase.StartPhase();
        }
    }
Esempio n. 2
0
 void TerminateCurrentPhase()
 {
     currentPhase.TerminatePhase();
     currentPhaseId++;
     if (currentPhaseId < bossPhases.Length)
     {
         currentPhase = bossPhases[currentPhaseId];
         currentPhase.StartPhase();
     }
     else
     {
         BossDeath();
     }
 }