This function has been deprecated. Use
WorldRoot/Raycast|WorldRoot:Raycast() along with
datatype/RaycastParams for new work.
For thread safety, this property is not safe to read in an unsynchronized thread.
This function is a variant of
WorldRoot/FindPartOnRay with the addition of an ignore list. This lets you ignore certain parts or
Those looking to utilize a whitelist instead should use
- Theoretically, a ray extends infinitely in one direction. However, the max length of the direction vector on Roblox is 5000 studs.
- The length (magnitude) of the directional vector is important, as parts further away than its length will not be tested.
- If the ray does not intersect anything, the return values will be
niland the point at the end of the ray, respectively.
- Parts that are in a
articles/Collision Filtering|collision groupthat does not collide with the “Default” collision group are ignored implicitly.