raycastsStartInColliders
Do ray/line casts that start inside a Collider(s) detect those Collider(s)?
Read time 1 minuteLast updated 4 days ago
Definition
- Type: Property
- Namespace: UnityEngine
- Assembly: UnityEngine.Physics2DModule
public static bool raycastsStartInColliders { get; set; }
Remarks
When performing a ray/line cast, the start point can begin inside a Collider. When this occurs, this property controls whether these Colliders are returned or not. When set to true, such Colliders are returned.
Additional Resources: Physics2D.Raycast, Physics2D.Linecast.