CreateShapeProxy
Create a shape proxy from the shape.
Read time 1 minuteLast updated 12 days ago
Definition
- Type: Method
- Namespace: Unity.U2D.Physics
- Assembly: UnityEngine.PhysicsCore2DModule
CreateShapeProxy(bool)
Create a shape proxy from the shape.
public PhysicsShape.ShapeProxy CreateShapeProxy(bool useWorldSpace = false)
Parameters
Whether to create the shape proxy in world-space or not. World-space will transform by the body origin the shape is attached to.
Returns
Type | Description |
|---|---|
| ShapeProxy |
CreateShapeProxy(PhysicsTransform)
Create a shape proxy from the shape, transformed by the specified transform.
public PhysicsShape.ShapeProxy CreateShapeProxy(PhysicsTransform transform)
Parameters
The transform used to position the shape geometry.
Returns
Type | Description |
|---|---|
| ShapeProxy |
CreateShapeProxy(Matrix4x4, bool)
Create a shape proxy from the shape, transformed by the specified transform. The maximum absolute value component from the scale will be used to scale the radius when is true. Shape types without a radius ignore the flag.
scaleRadiuspublic PhysicsShape.ShapeProxy CreateShapeProxy(Matrix4x4 transform, bool scaleRadius)
Parameters
Returns
Type | Description |
|---|---|
| ShapeProxy |