I am having trouble making an enemy script that will check whether the player is visible or obstructed from its point of view. If it is obstructed, the enemy will roam aimlessly. if it is visible, the enemy will move toward the player.
↧