[To the ZAngband Page] [News]

How to design a level

A level is defined by several lines specifying the layout with simple ASCII symbols.

Example (layout of the "Thieves Hideout"):

D:XXXXXXXXXXXXXXX
D:XT...a....X..TX
D:XT........D..TX
D:X.........Xa..X
D:XXXXX.....XXXXX
D:XT..D.........X
D:XTa.X.........X
D:XXXXX.........X
D:X<..D.........X
D:XXXXXXXXXXXXXXX
Every line starts with D (for Dungeon layout) followed by a colon ":". Then follows the layout of the dungeon row encoded in different letters. Every letter represents a dungeon feature, monster, or object.

You can define yourself what each letter should represent in front of the layout definition.

The definition of the letter looks like this:

F:letter:feature:cave_info:monster:object:ego:artifact:trap:special
Every line starting with a F defines a grid that can be used in the layout of the level. You don't have to write down trailing zero fields ("F:X:61:8:0:0:0:0:0:0" is equivalent to "F:X:61:8").

The different values in the list are:

Example from the "Thieves Hideout" quest:
# Lines starting with # are comments
# Permanent wall
F:X:61:8

# Floor with random object
F:T:1:8:0:*

# Floor
F:.:1:8

# Door
F:D:32:8

# up staircase
F:<:6:8

# Floor with novice rogue
F:a:1:8:38

# Dungeon layout
D:XXXXXXXXXXXXXXX
D:XT...a....X..TX
D:XT........D..TX
D:X.........Xa..X
D:XXXXX.....XXXXX
D:XT..D.........X
D:XTa.X.........X
D:XXXXX.........X
D:X<..D.........X
D:XXXXXXXXXXXXXXX

© 1997/98 by Robert Rühlmann, rr9@thangorodrim.net [News] [To the ZAngband Page]