# Shape.destroyShape

Destroy a shape

**Kind:** Function

**Environments:** Game

## Game

``` { .lua .api-signature }
shape:destroyShape(
    attackLevel,
    destructionType?,
    destructionPosition?,
    destructionNormal?
)
```

[Open the full Game reference](../Game-Script-Environment/Userdata/Shape.md#destroyshape)

**Availability:** Server only

**Parameters:**

| Name | Type | Description |
| --- | --- | --- |
| `shape` | [Shape](../Game-Script-Environment/Userdata/Shape.md) | The shape. |
| `attackLevel` | integer | Determines which quality level of shape the attack can destroy. Setting it to 0 (default) will destroy any shape. |
| `destructionType` *(optional)* | integer | The type of destruction (Optional). (See [sm.shape.destructionType](../Game-Script-Environment/Static-Functions/sm.shape.md#destructiontype)). (Defaults to sm.shape.destructionType.none) |
| `destructionPosition` *(optional)* | [Vec3](../Game-Script-Environment/Userdata/Vec3.md) | The position of the destruction would hit the shape (Optional) |
| `destructionNormal` *(optional)* | [Vec3](../Game-Script-Environment/Userdata/Vec3.md) | The normal direction of where the destruction would hit the shape (Optional) |
