ChainGeometry
The geometry of a chain of ChainSegment.
Read time 1 minuteLast updated 6 days ago
Definition
- Type: Struct
- Namespace: Unity.U2D.Physics
- Assembly: UnityEngine.PhysicsCore2DModule
public struct ChainGeometry
Constructors
Constructor | Description |
|---|---|
| ChainGeometry(Unity.Collections.NativeArray{UnityEngine.Vector2}) | Create the geometry of a Chain using the specified vertices. |
Properties
Methods
Method | Description |
|---|---|
| CalculateAABB | Calculate the AABB of the geometry. |
| CastRay | Calculate if a world ray intersects the geometry. See PhysicsQuery.CastResult. |
| CastShape | Calculate if a cast shape intersects the geometry. Initially touching shapes are treated as a miss. You should check for overlap first if initial overlap is required. See PhysicsQuery.CastShapeInput and PhysicsQuery.CastResult. |
| ClosestPoint | Calculate the closest point on this geometry to the specified point. |