- Home /
Question by
Sam Bigos · Apr 25, 2010 at 02:18 PM ·
pathfindingwaypointpatrol
Patrol routes and returning to them?
I'm a very novice Unity user. For a game I'm making I need to set a path for an enemy to follow, and when the player gets within sight of the enemy, the enemy will follow the player until the player is out of sight, and the enemy will return back to it's patrol route.
I have the sight sorted, I made a transparent object and when the player goes in it, the enemy moves towards them, it's just making the enemy move along a path and then return to it that I don't know how to do, what's the best way to do this?
Comment
Best Answer
Answer by Peter G · Apr 25, 2010 at 02:37 PM
The FPS tutorial AI does exactly what you are explaining very well. I would look into it and either use that or study how it works.