Documentation / Node reference / code nodes

code/RayClosestPoint

Outputs the point on a ray nearest a position, and its distance.

Geometry

Outputs the point on a ray nearest a position, and the distance between them. Points behind the ray's start measure to the start. previousRay widens it to the fan swept between the two rays, so a fast stroke misses nothing.

Parameters

Name Type What it does
position Vector3 Position to measure from.
maxSweepAngle Float Wider sweeps than this angle use only the current ray.

This page is generated from the engine, so it describes the release you can download. The same text is in the editor's Help panel next to the node itself.