cast Ray Closest
expect fun castRayClosest(origin: Vec2, translation: Vec2, filter: QueryFilter = QueryFilter.Default): RayResult
Cast a ray and return the closest hit.
Return
The result of the raycast
Parameters
origin
The starting point of the ray
translation
The ray direction and length (origin + translation = end point)
filter
Query filter to select which shapes to test