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J3MIW2UOW4OZZFYNQRSDSNCMKKQQFH34VPGNFDYNTIML46AC
IVVTHLTTLOP5TSULXJWUSSXHOKYWVU3OWKYVK45A7RIB6V34MYQAC
All fixed level information resides in various .des files to be found in
the dat directory. If you are interested in adding some vaults, say, start
with the existing ones and modify them. Currently, the following .des files
are in use:
All fixed level information resides in various .des files to be found in the
dat directory. If you are interested in adding some vaults, say, start with
the existing ones and modify them. Currently, the following .des files are in
use:
most cases, when the dungeon builder places a vault on a level, the rest of the
level (assuming the vault is not a full-map vault) is generated as
most cases, when the dungeon builder places a vault on a level, the rest of
the level (assuming the vault is not a full-map vault) is generated as
Minivaults are distinguished from normal vaults solely by the absence
of an ORIENT: declaration. Any map without a specified ORIENT: is a
minivault.
Minivaults are distinguished from normal vaults solely by the absence of an
ORIENT: declaration. Any map without a specified ORIENT: is a minivault.
Before going into the technical details of the level-file syntax,
let's look at an example - a branch entry for the Ecumenical Temple -
to see what a map definition looks like.
Before going into the technical details of the level-file syntax, let's look
at an example - a branch entry for the Ecumenical Temple - to see what a map
definition looks like.
Every map consists of a name, a header and the actual map (the order
is not important as long as the name comes first, but stick to this
order for consistency).
Every map consists of a name, a header and the actual map (the order is not
important as long as the name comes first, but try to stick to this order for
consistency).
Lines starting with # are comments. The keywords available are
explained briefly after the example map and in detail in the following
sections.
Lines starting with # are comments. The keywords available are explained
briefly after the example map and in detail in the following sections.
Note: Due to the level maker having seen incremental improvements over
the years, there are some inconsistencies. For examples, dangerous
statues (orange, silver, ice) are now genuine monsters. In particular,
you might see many older vaults still using the deprecated 'H' and 'S'
glyphs which should otherwise be dispensed with.
Note: Due to the level maker having seen incremental improvements over the
years, there are some inconsistencies. For examples, dangerous statues
(orange, silver, ice) are now genuine monsters. In particular, you might see
many older vaults still using the deprecated 'H' and 'S' glyphs which should
otherwise be dispensed with.
Also, the most of the other feature glyphs can be replaced with KFEAT:
lines. The same goes for some item glyphs ('R', 'Z') which
could be replaced by KITEM: lines.
Similarly, the most of the other feature glyphs can be replaced with KFEAT:
lines. The same goes for some item glyphs ('R', 'Z') which could be replaced
by KITEM: lines.
(All declarations apart from NAME: are translated to Lua function
calls behind the scenes. See the Lua reference for more information.)
(All declarations apart from NAME: are translated to Lua function calls
behind the scenes. See the Lua reference for more information.)
LFLAGS: Persistent, changeable per-level flags which affect game
behavior (FLAGS just controls how the vault is placed); should
only be used for vaults with ORIENT encompass or with PLACE.
This causes a level's flags to be set when the level is first
created. These flags can later be altered using Lua markers;
see the slime pit vault in lair.des, and the vaults in hell.des
and elf.des for examples.
LFLAGS: Persistent, changeable per-level flags which affect game behaviour
(FLAGS just controls how the vault is placed); should only be used
for vaults with ORIENT encompass or with PLACE. Causes a level's
flags to be set when the level is first created. These flags can
later be altered using Lua markers; for examples, look at the slime
pit vault in lair.des, and the vaults in hell.des and elf.des.
Valid flags are: no_tele_control, which prevents the player
from using teleport control; not_mappable, which prevents
the player from remembering where they've been (like in
the Abyss), and no_magic_map, which prevents magic mapping
from working.
Valid flags are: no_tele_control, which prevents the player from
using teleport control; not_mappable, which prevents the player
from remembering where they've been (like in the Abyss), and
no_magic_map, which prevents magic mapping from working.
Valid flags are: no_tele_control, which prevents the player
from using teleport control; not_mappable, which prevents
the player from remembering where they've been (like in
the Abyss), and no_magic_map, which prevents magic mapping
from working.
Valid flags are: no_tele_control, which prevents the player from
using teleport control; not_mappable, which prevents the player
from remembering where they've been (like in the Abyss), and
no_magic_map, which prevents magic mapping from working.
FLOORCOL: allows you to set the floor colour for the level
the vault appears in. Should only be used for bazaars and
other portal vaults.
FLOORCOL: allows you to set the floor colour for the level the
vault appears in. Should only be used for bazaars and other
portal vaults.
ROCKCOL: allows you to set the colour of rock walls for the
level the vault appears in. Should only be used for bazaars and
other portal vaults.
ROCKCOL: allows you to set the colour of rock walls for the level
the vault appears in. Should only be used for bazaars and other
portal vaults.
Valid item class names are: gold, weapon, missile, armour,
wand, food, scroll, jewelry, potion, book, staff, orb,
misc, carrion. All of these are usable in map definitions,
apart from "orb" and "carrion".
* "race:race_name", where "race_name" is "elven", "dwarven"
or "orcish"; it can also be "none" or "no_race" to prevent
the item from being randomly being made racial. Has no effect
if the item can't take that kind of racial setting.
NOTE: Can result in a non-racial item if used with "any" and
the chosen item isn't compatible with the desired race.
* "ego:ego_name", where "ego_name" is something like
"running", "fire_resistance", and so on; "none" can be used
to prevent the item from getting an ego. The item must
be fully specified, so trying "any weapon ego:vorpal" or
"any armour ego:positive_energy" will result in an error.
Trying to give an ego to something which can't accept an
ego will also result in an error.
Valid item class names are: gold, weapon, missile, armour, wand,
food, scroll, jewelry, potion, book, staff, orb, misc, carrion.
All of these are usable in map definitions, apart from "orb" and
"carrion".
* "race:race_name", where "race_name" is "elven", "dwarven" or
"orcish"; it can also be "none" or "no_race" to prevent the item
from being randomly being made racial. Has no effect if the item
can't take that kind of racial setting.
NOTE: Can result in a non-racial item if used with "any" and the
chosen item isn't compatible with the desired race.
* "ego:ego_name", where "ego_name" is something like "running" or
"fire_resistance", and so on; "none" can be used to prevent the
item from getting an ego. The item must be fully specified, so
trying "any weapon ego:vorpal" or "any armour ego:positive_energy"
will result in an error. Trying to give an ego to something which
can't accept an ego will also result in an error.
WARNING: While checks are done to make sure that an armour
ego isn't given to a weapon, a weapon ego to a missile,
and so on, and also to make sure that egos are only given
to amrours, weapons and missiles, no other checking is
done. Thus it is possible to create a demonic weapon of
holy wrath or a helmet of running.
WARNING: While checks are done to make sure that an armour ego
isn't given to a weapon, a weapon ego to a missile, and so on, and
also to make sure that egos are only given to amrours, weapons and
missiles, no other checking is done. Thus it is possible to create
a demonic weapon of holy wrath or a helmet of running.
Limitations: You can't specify curse status, specificy
pluses or number of charges, force a randart or give fixedarts.
You also can't lay down corpses, skeletons, or chunks.
Limitations: You can't specify curse status, specificy pluses or
number of charges, force a randart or give fixedarts. You also
can't lay down corpses, skeletons, or chunks.
will prevent monsters from randomly being generated on shallow
water squares. Note that if shuffling and substitutions cause
W to end up as water 10% of the time and floor 90% of the time,
then those floor squares will still have no_monster_gen set, but
that's still a higher degree of control than you get with TAGS.
will prevent monsters from randomly being generated on shallow water
squares. Note that if shuffling and substitutions cause W to end up
as water 10% of the time and floor 90% of the time, then those floor
squares will still have no_monster_gen set, but that's still a higher
degree of control than you get with TAGS.
If TAGS has been used to set a mask for the entire vault, you
can use KMASK to remove that mask from particular symbols.
For instance:
If TAGS has been used to set a mask for the entire vault, you can use
KMASK to remove that mask from particular symbols. For instance:
When the horn is sounded, the stone arch at D becomes the
portal to Dis, the arch at G becomes the portal to Gehenna,
etc. This behaviour applies only to the Vestibule of Hell.
When the horn is sounded, the stone arch at D becomes the portal to
Dis, the arch at G becomes the portal to Gehenna. This behaviour
applies only to the Vestibule of Hell.
Lua markers are used for more complex triggers, such as for
bazaar and labyrinth gates, rune pickup triggers for
the branches of Hell, fog generators, etc.
Lua markers are used for more complex triggers, such as for bazaar
and labyrinth gates, rune pickup triggers for the branches of Hell,
fog generators, etc.
For a full explanation of the various paramenters, read the
header of dat/clua/lm_fog.lua.
Feature names used in markers must be names matching the names in
the source code. There's a full list of feature names in section I
(Feature names) at the end of this document.
Feature names used in markers must be names matching the
names in the source code. There's a full list of feature
names in section I (Feature names) at the end of this
document.
An important thing to note with markers is that they are
also considered map transforms along with SUBST, NSUBST and
SHUFFLE. You usually want to place a MARKER line after all
SUBST, NSUBST and SHUFFLE lines so that the final position
of the marker key is used. For instance, if you want to
attach a marker to the rune in a map when you're randomising
An important note about markers is that they are also considered map
transforms along with SUBST, NSUBST and SHUFFLE. You usually want
to place a MARKER line after all SUBST, NSUBST and SHUFFLE lines so
that the final position of the marker key is used. For instance, if
you want to attach a marker to the rune in a map which randomises
because the marker will be placed at O (the rune), then O
may be shuffled to a different position. The correct order
in this case is:
because the marker will be placed at O (the rune), then O may be
shuffled to a different position. The correct order in this case is:
If you're using continuation lines for comma-separated lists of items
or monsters, split your line after the comma, not before. For example:
If you're using continuation lines for comma-separated lists of monsters or
items, split your line after the comma, not before. For example:
Spaces before the \ of the continued line are significant, leading
spaces of the next (continuing) line are not. In other words, given:
Spaces before the \ of the continued line are significant, leading spaces of
the next (continuing) line are not. In other words, given:
Crawl translates level (.des) files into Lua code chunks and runs
these chunks to produce the final level that is generated. While you
don't need to use Lua for most levels, using Lua allows you to
conditionalise or randomise levels with greater control.
Crawl translates level (.des) files into Lua code chunks and runs these chunks
to produce the final level that is generated. While you don't need to use Lua
for most levels, using Lua allows you to conditionalise or randomise levels
with greater control.
Now let's say you want A, B, and C to be randomly rock or floor, but B
should be floor if both A and C are rock. Here's one way to do it (add
these lines to the map definition):
Now let's say you want A, B, and C to be randomly rock or floor, but B should
be floor if both A and C are rock. Here's one way to do it (add these lines
to the map definition):