void EndBattle() { inBossFight = false; inCutscene = true; SeagullFlightController seagullFlight = Seagull.GetComponent <SeagullFlightController>(); seagullFlight.enabled = true; SeagullBossController seagullBoss = Seagull.GetComponent <SeagullBossController>(); seagullBoss.enabled = false; // increment levels Seagull.GetComponent <SeagullFlightController>().currentLevel++; currentLevel++; if (seagullBoss.NUM_OF_ATTACKS < 4) { seagullBoss.NUM_OF_ATTACKS++; } MainCamera.GetComponent <BossFightThirdPersonCameraController>().enabled = false; player.GetComponent <bossControls>().enabled = false; player.GetComponent <movement>().enabled = false; seagullHealthManager.seagullHealth += seagullHealthManager.damageTaken - healthThreshold; seagullHealthManager.damageTaken = 0; Crosshair.SetActive(false); canSpawnCrab = false; DestroyCrabs(); }
void StartBattle() { //ENSURE REMOVAL OF EGGS AND HEALTH TOKENS (TO COMBAT HAVING ONES ON MAP THAT CANT BE REACHED) inCutscene = true; SeagullFlightController seagullFlight = Seagull.GetComponent <SeagullFlightController>(); seagullFlight.enabled = false; SeagullBossController seagullBoss = Seagull.GetComponent <SeagullBossController>(); seagullBoss.enabled = true; //seagullBoss.totalTime = seagullFlight.totalTime; MainCamera.GetComponent <ThirdPersonCameraController>().enabled = false; MainCamera.GetComponent <BossFightThirdPersonCameraController>().enabled = false; MainCamera.GetComponent <Transform>().LookAt(transform); player.transform.position = new Vector3(0, 2, 75); player.transform.LookAt(new Vector3(0, player.transform.position.y, 0)); player.GetComponent <bossControls>().enabled = false; player.GetComponent <movement>().enabled = false; canSpawnCrab = false; DestroyCrabs(); }