# CreateShape

> Create a Circle shape, using its default definition, attached to the specified body. See PhysicsBody.CreateShape.

## Definition

* **Type:** Method
* **Namespace:** [Unity.U2D.Physics](/engine/6000.5/script-reference/unity/u2d/physics.md)
* **Assembly:** UnityEngine.PhysicsCore2DModule

## CreateShape(PhysicsBody, CircleGeometry)

Create a Circle shape, using its default definition, attached to the specified body. See [PhysicsBody.CreateShape](/engine/6000.5/script-reference/unity/u2d/physics/physicsbody/createshape.md).

```csharp
public static PhysicsShape CreateShape(PhysicsBody body, CircleGeometry geometry)
```

### Parameters

**** (\[PhysicsBody]\(/engine/6000.5/script-reference/unity/u2d/physics/physicsbody)): The body to attach the shape to.**** (\[CircleGeometry]\(/engine/6000.5/script-reference/unity/u2d/physics/circlegeometry)): The shape geometry to use.

### Returns

| Type                                                                              | Description        |
| --------------------------------------------------------------------------------- | ------------------ |
| [PhysicsShape](/engine/6000.5/script-reference/unity/u2d/physics/physicsshape.md) | The created shape. |

## CreateShape(PhysicsBody, CircleGeometry, PhysicsShapeDefinition)

Create a Circle shape attached to the specified body. See [PhysicsBody.CreateShape](/engine/6000.5/script-reference/unity/u2d/physics/physicsbody/createshape.md).

```csharp
public static PhysicsShape CreateShape(PhysicsBody body, CircleGeometry geometry, PhysicsShapeDefinition definition)
```

### Parameters

**** (\[PhysicsBody]\(/engine/6000.5/script-reference/unity/u2d/physics/physicsbody)): The body to attach the shape to.**** (\[CircleGeometry]\(/engine/6000.5/script-reference/unity/u2d/physics/circlegeometry)): The shape geometry to use.**** (\[PhysicsShapeDefinition]\(/engine/6000.5/script-reference/unity/u2d/physics/physicsshapedefinition)): The shape definition to use.

### Returns

| Type                                                                              | Description        |
| --------------------------------------------------------------------------------- | ------------------ |
| [PhysicsShape](/engine/6000.5/script-reference/unity/u2d/physics/physicsshape.md) | The created shape. |

## CreateShape(PhysicsBody, PolygonGeometry)

Create a Polygon shape, using its default definition, attached to the specified body. See [PhysicsBody.CreateShape](/engine/6000.5/script-reference/unity/u2d/physics/physicsbody/createshape.md).

```csharp
public static PhysicsShape CreateShape(PhysicsBody body, PolygonGeometry geometry)
```

### Parameters

**** (\[PhysicsBody]\(/engine/6000.5/script-reference/unity/u2d/physics/physicsbody)): The body to attach the shape to.**** (\[PolygonGeometry]\(/engine/6000.5/script-reference/unity/u2d/physics/polygongeometry)): The shape geometry to use.

### Returns

| Type                                                                              | Description        |
| --------------------------------------------------------------------------------- | ------------------ |
| [PhysicsShape](/engine/6000.5/script-reference/unity/u2d/physics/physicsshape.md) | The created shape. |

## CreateShape(PhysicsBody, PolygonGeometry, PhysicsShapeDefinition)

Create a Polygon shape attached to the specified body. See [PhysicsBody.CreateShape](/engine/6000.5/script-reference/unity/u2d/physics/physicsbody/createshape.md).

```csharp
public static PhysicsShape CreateShape(PhysicsBody body, PolygonGeometry geometry, PhysicsShapeDefinition definition)
```

### Parameters

**** (\[PhysicsBody]\(/engine/6000.5/script-reference/unity/u2d/physics/physicsbody)): The body to attach the shape to.**** (\[PolygonGeometry]\(/engine/6000.5/script-reference/unity/u2d/physics/polygongeometry)): The shape geometry to use.**** (\[PhysicsShapeDefinition]\(/engine/6000.5/script-reference/unity/u2d/physics/physicsshapedefinition)): The shape definition to use.

### Returns

| Type                                                                              | Description        |
| --------------------------------------------------------------------------------- | ------------------ |
| [PhysicsShape](/engine/6000.5/script-reference/unity/u2d/physics/physicsshape.md) | The created shape. |

## CreateShape(PhysicsBody, CapsuleGeometry)

Create a Capsule shape, using its default definition, attached to the specified body. See [PhysicsBody.CreateShape](/engine/6000.5/script-reference/unity/u2d/physics/physicsbody/createshape.md).

```csharp
public static PhysicsShape CreateShape(PhysicsBody body, CapsuleGeometry geometry)
```

### Parameters

**** (\[PhysicsBody]\(/engine/6000.5/script-reference/unity/u2d/physics/physicsbody)): The body to attach the shape to.**** (\[CapsuleGeometry]\(/engine/6000.5/script-reference/unity/u2d/physics/capsulegeometry)): The shape geometry to use.

### Returns

| Type                                                                              | Description        |
| --------------------------------------------------------------------------------- | ------------------ |
| [PhysicsShape](/engine/6000.5/script-reference/unity/u2d/physics/physicsshape.md) | The created shape. |

## CreateShape(PhysicsBody, CapsuleGeometry, PhysicsShapeDefinition)

Create a Capsule shape attached to the specified body. See [PhysicsBody.CreateShape](/engine/6000.5/script-reference/unity/u2d/physics/physicsbody/createshape.md).

```csharp
public static PhysicsShape CreateShape(PhysicsBody body, CapsuleGeometry geometry, PhysicsShapeDefinition definition)
```

### Parameters

**** (\[PhysicsBody]\(/engine/6000.5/script-reference/unity/u2d/physics/physicsbody)): The body to attach the shape to.**** (\[CapsuleGeometry]\(/engine/6000.5/script-reference/unity/u2d/physics/capsulegeometry)): The shape geometry to use.**** (\[PhysicsShapeDefinition]\(/engine/6000.5/script-reference/unity/u2d/physics/physicsshapedefinition)): The shape definition to use.

### Returns

| Type                                                                              | Description        |
| --------------------------------------------------------------------------------- | ------------------ |
| [PhysicsShape](/engine/6000.5/script-reference/unity/u2d/physics/physicsshape.md) | The created shape. |

## CreateShape(PhysicsBody, SegmentGeometry)

Create a Segment shape, using its default definition, attached to the specified body. See [PhysicsBody.CreateShape](/engine/6000.5/script-reference/unity/u2d/physics/physicsbody/createshape.md).

```csharp
public static PhysicsShape CreateShape(PhysicsBody body, SegmentGeometry geometry)
```

### Parameters

**** (\[PhysicsBody]\(/engine/6000.5/script-reference/unity/u2d/physics/physicsbody)): The body to attach the shape to.**** (\[SegmentGeometry]\(/engine/6000.5/script-reference/unity/u2d/physics/segmentgeometry)): The shape geometry to use.

### Returns

| Type                                                                              | Description        |
| --------------------------------------------------------------------------------- | ------------------ |
| [PhysicsShape](/engine/6000.5/script-reference/unity/u2d/physics/physicsshape.md) | The created shape. |

## CreateShape(PhysicsBody, SegmentGeometry, PhysicsShapeDefinition)

Create a Segment shape attached to the specified body. See [PhysicsBody.CreateShape](/engine/6000.5/script-reference/unity/u2d/physics/physicsbody/createshape.md).

```csharp
public static PhysicsShape CreateShape(PhysicsBody body, SegmentGeometry geometry, PhysicsShapeDefinition definition)
```

### Parameters

**** (\[PhysicsBody]\(/engine/6000.5/script-reference/unity/u2d/physics/physicsbody)): The body to attach the shape to.**** (\[SegmentGeometry]\(/engine/6000.5/script-reference/unity/u2d/physics/segmentgeometry)): The shape geometry to use.**** (\[PhysicsShapeDefinition]\(/engine/6000.5/script-reference/unity/u2d/physics/physicsshapedefinition)): The shape definition to use.

### Returns

| Type                                                                              | Description        |
| --------------------------------------------------------------------------------- | ------------------ |
| [PhysicsShape](/engine/6000.5/script-reference/unity/u2d/physics/physicsshape.md) | The created shape. |

## CreateShape(PhysicsBody, ChainSegmentGeometry, PhysicsShapeDefinition)

Create a Chain Segment shape attached to the specified body. See [PhysicsBody.CreateShape](/engine/6000.5/script-reference/unity/u2d/physics/physicsbody/createshape.md).

```csharp
public static PhysicsShape CreateShape(PhysicsBody body, ChainSegmentGeometry geometry, PhysicsShapeDefinition definition)
```

### Parameters

**** (\[PhysicsBody]\(/engine/6000.5/script-reference/unity/u2d/physics/physicsbody)): The body to attach the shape to.**** (\[ChainSegmentGeometry]\(/engine/6000.5/script-reference/unity/u2d/physics/chainsegmentgeometry)): The shape geometry to use.**** (\[PhysicsShapeDefinition]\(/engine/6000.5/script-reference/unity/u2d/physics/physicsshapedefinition)): The shape definition to use.

### Returns

| Type                                                                              | Description        |
| --------------------------------------------------------------------------------- | ------------------ |
| [PhysicsShape](/engine/6000.5/script-reference/unity/u2d/physics/physicsshape.md) | The created shape. |

## CreateShape(PhysicsBody, ChainSegmentGeometry)

Create a Chain Segment shape, using its default definition, attached to the specified body. See [PhysicsBody.CreateShape](/engine/6000.5/script-reference/unity/u2d/physics/physicsbody/createshape.md).

```csharp
public static PhysicsShape CreateShape(PhysicsBody body, ChainSegmentGeometry geometry)
```

### Parameters

**** (\[PhysicsBody]\(/engine/6000.5/script-reference/unity/u2d/physics/physicsbody)): The body to attach the shape to.**** (\[ChainSegmentGeometry]\(/engine/6000.5/script-reference/unity/u2d/physics/chainsegmentgeometry)): The shape geometry to use.

### Returns

| Type                                                                              | Description        |
| --------------------------------------------------------------------------------- | ------------------ |
| [PhysicsShape](/engine/6000.5/script-reference/unity/u2d/physics/physicsshape.md) | The created shape. |
