# ColliderShape.Box record

> A collider shape that's a box, centred on the collider's origin and lined up with its axes. Turn it with the collider's Rotation.

Namespace `EvilEngine.Formats.Collision`, assembly `EvilEngine.Formats`. Engine commit 4ff877b1.

```csharp
public sealed record ColliderShape.Box : ColliderShape
```

A [collider shape](/docs/api/collidershape) that's a box, centred on the collider's origin and lined up with its axes. Turn it with the collider's [Rotation](/docs/api/collider#rotation).

```csharp
new Collider(new ColliderShape.Box(new Vector3(0.8f, 0.8f, 0.8f)), ["solid"])
```

## Members

### ColliderShape.Box (constructor)

```csharp
public ColliderShape.Box(Vector3 Size)
```

Makes a box of `size`.

### Size (property)

```csharp
public Vector3 Size { get; init; }
```

The box's whole width, height and depth along the collider's X, Y and Z axes, in metres, not its half sizes. Each must be above 0 for the collision to be written. A box with a size of 0 adds no volume, so it adds nothing to a body's mass worked out from its volume.
