Closest Point On Spline

Callable
ClosestPointOnSpline

Finds the closest point on a spline to a given world location, returning the point, its distance along the spline, and its input key.

Type: Callable (has execution pins)
Category: Fortuna|Vector & Transform
Keywords: vector & transform

Inputs

NameTypeDefaultDescription
SplineComponentSplineComponentSplineComponent parameter
WorldLocationFVectorWorldLocation parameter

Outputs

NameTypeDescription
ReturnValueFVectorReturnValue output
OutDistancefloatOutDistance output
OutInputKeyfloatOutInputKey output

Example Use Cases

Example 1

Snap an NPC to the nearest point on a patrol path spline.

Example 2

Find how far along a road spline a vehicle currently is.