# World.setMiningConfig

Configures the mining loot population. Matched candidates are sent to the

**Kind:** Function

**Environments:** Game

## Game

``` { .lua .api-signature }
world:setMiningConfig( config )
```

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

**Availability:** Server only

world script via the server_onMining callback whenever voxels are removed.

**Parameters:**

| Name | Type | Description |
| --- | --- | --- |
| `world` | [World](../Game-Script-Environment/Userdata/World.md) | The world. |
| `config` | table | Spawn rules keyed by voxel material index (1-8). Each value is an array of rule tables: \{ sizeX, sizeY, sizeZ, seed, spawnId = integers, tunnelType = string (optional), maxDist = number (optional) \}. |
