# World.sphereVoxelDensitySubtraction

Modify destructable terrain with a sphere shape

**Kind:** Function

**Environments:** Game

## Game

``` { .lua .api-signature }
world:sphereVoxelDensitySubtraction(
    position,
    radius,
    filter?,
    strength?,
    callback?,
    params?
)
```

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

**Availability:** Server only

**Parameters:**

| Name | Type | Description |
| --- | --- | --- |
| `world` | [World](../Game-Script-Environment/Userdata/World.md) | The world. |
| `position` | [Vec3](../Game-Script-Environment/Userdata/Vec3.md) | The world position of the sphere. |
| `radius` | number | The radius of the sphere. |
| `filter` *(optional)* | integer | The materials the shape can modify. (See [sm.world.voxelFilter](../Game-Script-Environment/Static-Functions/sm.world.md#voxelfilter)). (Defaults to sm.world.voxelFilter.all) |
| `strength` *(optional)* | number | The strength of the modification. (Defaults to radius) |
| `callback` *(optional)* | string | Lua function to call when cell is loaded. Callback parameters are a table of destruction data \{ remDensities = \{integer, ..\}, avgPositions = \{[Vec3](../Game-Script-Environment/Userdata/Vec3.md), ..\} \} and (optional) pass-through params passed to this function. |
| `params` *(optional)* | any | Parameter passed to the callback. (Optional) |
