For anyone facing this issue, I have added the following line of code to the "surround" script at "OnUpdate" after the destination gets set and the detour part. this should return the next best nearest point on the navmesh: destination = (Vector3)AstarPath.active.GetNearest(destination, NNConstraint.Default).node.position;
I am still testing this method for stability.