Global settings and helpers for 2D physics.
| AllLayers | Layer mask constant that includes all layers. | 
|---|---|
| DefaultRaycastLayers | Layer mask constant that includes all layers participating in raycasts by default. | 
| gravity | Acceleration due to gravity. | 
| IgnoreRaycastLayer | Layer mask constant for the default layer that ignores raycasts. | 
| positionIterations | The number of iterations of the physics solver when considering objects' positions. | 
| raycastsHitTriggers | Do raycasts detect Colliders configured as triggers? | 
| velocityIterations | The number of iterations of the physics solver when considering objects' velocities. | 
| GetIgnoreLayerCollision | Should collisions between the specified layers be ignored? | 
|---|---|
| GetRayIntersection | Cast a 3D ray against the colliders in the scene returning the first collider along the ray. | 
| GetRayIntersectionAll | Cast a 3D ray against the colliders in the scene returning all the colliders along the ray. | 
| GetRayIntersectionNonAlloc | Cast a 3D ray against the colliders in the scene returning the colliders along the ray. | 
| IgnoreLayerCollision | Choose whether to detect or ignore collisions between a specified pair of layers. | 
| Linecast | Casts a line against colliders in the scene. | 
| LinecastAll | Casts a line against colliders in the scene. | 
| LinecastNonAlloc | Casts a line against colliders in the scene. | 
| OverlapArea | Check if a collider falls within a rectangular area. | 
| OverlapAreaAll | Get a list of all colliders that fall within a rectangular area. | 
| OverlapAreaNonAlloc | Get a list of all colliders that fall within a specified area. | 
| OverlapCircle | Check if a collider falls within a circular area. | 
| OverlapCircleAll | Get a list of all colliders that fall within a circular area. | 
| OverlapCircleNonAlloc | Get a list of all colliders that fall within a circular area. | 
| OverlapPoint | Check if a collider overlaps a point in space. | 
| OverlapPointAll | Get a list of all colliders that overlap a point in space. | 
| OverlapPointNonAlloc | Get a list of all colliders that overlap a point in space. | 
| Raycast | Casts a ray against colliders in the scene. | 
| RaycastAll | Casts a ray against colliders in the scene, returning all colliders that contact with it. | 
| RaycastNonAlloc | Casts a ray into the scene. |