Dungeon
A dungeon is a small underground room of cobblestone with a monster spawner at its centre and up to two chests.
Generation
Eight dungeons are attempted in every Overworld chunk, each at a random point anywhere from y=0 to y=127.
The room inside is 5 or 7 blocks long in each direction, chosen separately, and 4 blocks tall. A dungeon is built only where:
- the whole floor layer and the whole ceiling layer are solid;
- the walls have between one and five openings, an opening being a wall space at floor level with air in it and above it.
A sealed room is rejected, so every dungeon opens onto some open space, such as a cave.
Contents
| Part | Made of |
|---|---|
| Walls | |
| Floor | |
| Ceiling | the rock that was already there |
| Centre of the floor | a |
Any wall or floor block with nothing solid beneath it is left out.
Two chests are attempted. Each takes up to three tries at a random floor space against exactly one wall, so a chest never stands in a corner or in the open. A dungeon holds none, one or two.
Chest loot
Each chest is filled by eight draws, each put into a random slot. A later draw can replace an earlier one. Each draw gives one of:
| Item | Amount | Chance per draw |
|---|---|---|
| 1 | 1 in 11 | |
| 1–4 | 1 in 11 | |
| 1 | 1 in 11 | |
| 1–4 | 1 in 11 | |
| 1–4 | 1 in 11 | |
| 1–4 | 1 in 11 | |
| 1 | 1 in 11 | |
| 1 | 1 in 11 | |
| 1–4 | 1 in 22 | |
| 1 | 1 in 110 | |
| 1 | 1 in 1,100 |
A draw gives nothing otherwise.
Usage
A dungeon's floor is the only place moss stone generates.