void Update() { if (!LevelManager.isGameOver && this.DetectPlayer()) { FindObjectOfType <LevelManager>().LevelLost(); if (parentEnemy != null) { parentEnemy.GameOver(true); } } if (this.DetectGrappleHand()) { if (parentEnemy != null) { parentEnemy.Alert(player, true); } } }
void Alert() { enemy.Alert(gameObject.transform, true); }