// Update is called once per frame void Update() { RaycastHit hit; if (!visionController.canSeePlayer(out hit, true)) { stateMachine.ActivateState(stateMachine.AlertState); return; } navMeshController.UpdateDestinyPointNavMeshAgent(); }
private void UpdateDestinyWayPoint() { navMeshController.UpdateDestinyPointNavMeshAgent(WayPoints[nextWayPoint].position); }