public void OnDeath() { bossState = FireBossState.Dead; UpdateHealth(0); StartCoroutine("Sink"); Player.stats.defeatedBosses.Add(Element.Fire); }
public void _FireMeteor() { shootAudio.Play(); UpdateHealth(health - attackCost); Vector3 direction = (Player.gameObject.transform.position - cannon.gameObject.transform.position).normalized; projectile.Fire(cannon.transform.position, direction); bossState = FireBossState.MeteorShot; }
public void OnMeteorDestroy() { if (bossState == FireBossState.Recalling) { RecallEnd(); } else if (bossState == FireBossState.MeteorShot) { bossState = FireBossState.Waiting; } if (health == 1) { OnDeath(); } }
public void WakeUp() { animator.SetTrigger("enterarea"); bossState = FireBossState.Waiting; StartCoroutine("AILoop"); }
public void RecallEnd() { animator.SetTrigger("eat_end"); bossState = FireBossState.Waiting; }
public void Recall() { animator.SetTrigger("eat"); bossState = FireBossState.Recalling; }
public void Shoot() { animator.SetTrigger("shoot"); bossState = FireBossState.CannonPreparing; }