physics_raycast_2d
Cast a 2D ray to detect the first object hit, returning its position and surface normal for collision queries.
Instructions
Cast a ray in 2D physics space and return the first hit entity, hit point, and normal.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| origin | Yes | ||
| direction | Yes | ||
| layerMask | No | ||
| maxDistance | Yes |