I'm interested in knowing that too.
I have done something similar, when the target position is at same elevation:
But I'm not sure how to solve it when the elevations are different.
I'll need to figure it out for something I'm working on at some point, but maybe someone else knows how to do it!?