Orthogonal Distances

Hello All,

I have a some points in an ordered list. I would like to find the distance along an orthogonal x y path from one point to the next, rather than the direct path that Geometry.DistanceTo provides.

At this point, the Cuboid.ByCorners seemed quite practical, then simply adding the length and width of one side. This eliminated the need for any Trig functions. If I use ol pythag, the vector angle being greater than 90 started adding complications. Not impossible though.

But in either case I have an issue when my points exist along the same x or y axis, providing a null result.

I’ve considered indexing the null result and replacing those with Geometry.DistanceTo node, but it’s going to get messy. I am wondering if I’m overthinking this, which I’m sure I am. Is there a more practical approach I am missing here?

As always, thank you for reading and the assistance.

Distance Generator Testing 3D

Vector.ByTwoPoints
Vector.X + Vector.Y

Solved. Thank you!!