let ai continously walk down a path - make AI go back to path if its outside

hello!

First off, thanks for your work helping the community. However your project does not really help me since you do use waypoints, just like I currently have. I hoped that I could replace this waypoint system with something that I have pictured above.

For example, if the AI pawn would get out of his path to chase down an enemy, with your system it would go back to its old waypoint. Now if this enemy would drag it around the map (in my graphic up or down) it would take the way back to its last waypoint whereas I want it to go back straight to the “path” and then walk down in the same direction it always has been.

I have everything working except for the purple “go back to path” AND hoped I could get something better than waypoints for the first thing wich is just walking down its path.

Now with the waypoint system in order to get back in to the path again I would need to do a “for each loop” on the array with waypoints and check the distance to each waypoint wich is kinda expensive. I tried different variations of “ai move to” on a volume that is the path, but it always defaults to the exact world location vector point that the volume is placed and never ever tries to actually get into the volume asap.

For walking down the path waypoints are allright, eventhough I hoped I could make a volume, assign a direction vector and let the ai pawns go with it.