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RSDSNCMKKQQFH34VPGNFDYNTIML46AC IVVTHLTTLOP5TSULXJWUSSXHOKYWVU3OWKYVK45A7RIB6V34MYQAC All fixed level information resides in various .des files to be found inthe dat directory. If you are interested in adding some vaults, say, startwith the existing ones and modify them. Currently, the following .des filesare in use:
All fixed level information resides in various .des files to be found in thedat directory. If you are interested in adding some vaults, say, start withthe existing ones and modify them. Currently, the following .des files are inuse:
most cases, when the dungeon builder places a vault on a level, the rest of thelevel (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 ofthe level (assuming the vault is not a full-map vault) is generated as
Minivaults are distinguished from normal vaults solely by the absenceof an ORIENT: declaration. Any map without a specified ORIENT: is aminivault.
Minivaults are distinguished from normal vaults solely by the absence of anORIENT: 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 lookat an example - a branch entry for the Ecumenical Temple - to see what a mapdefinition looks like.
Every map consists of a name, a header and the actual map (the orderis not important as long as the name comes first, but stick to thisorder for consistency).
Every map consists of a name, a header and the actual map (the order is notimportant as long as the name comes first, but try to stick to this order forconsistency).
Lines starting with # are comments. The keywords available areexplained briefly after the example map and in detail in the followingsections.
Lines starting with # are comments. The keywords available are explainedbriefly after the example map and in detail in the following sections.
Note: Due to the level maker having seen incremental improvements overthe years, there are some inconsistencies. For examples, dangerousstatues (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 theyears, there are some inconsistencies. For examples, dangerous statues(orange, silver, ice) are now genuine monsters. In particular, you might seemany older vaults still using the deprecated 'H' and 'S' glyphs which shouldotherwise 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') whichcould 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 replacedby KITEM: lines.
(All declarations apart from NAME: are translated to Lua functioncalls behind the scenes. See the Lua reference for more information.)
(All declarations apart from NAME: are translated to Lua function callsbehind the scenes. See the Lua reference for more information.)
LFLAGS: Persistent, changeable per-level flags which affect gamebehavior (FLAGS just controls how the vault is placed); shouldonly be used for vaults with ORIENT encompass or with PLACE.This causes a level's flags to be set when the level is firstcreated. These flags can later be altered using Lua markers;see the slime pit vault in lair.des, and the vaults in hell.desand 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 usedfor vaults with ORIENT encompass or with PLACE. Causes a level'sflags to be set when the level is first created. These flags canlater be altered using Lua markers; for examples, look at the slimepit vault in lair.des, and the vaults in hell.des and elf.des.
Valid flags are: no_tele_control, which prevents the playerfrom using teleport control; not_mappable, which preventsthe player from remembering where they've been (like inthe Abyss), and no_magic_map, which prevents magic mappingfrom working.
Valid flags are: no_tele_control, which prevents the player fromusing teleport control; not_mappable, which prevents the playerfrom remembering where they've been (like in the Abyss), andno_magic_map, which prevents magic mapping from working.
Valid flags are: no_tele_control, which prevents the playerfrom using teleport control; not_mappable, which preventsthe player from remembering where they've been (like inthe Abyss), and no_magic_map, which prevents magic mappingfrom working.
Valid flags are: no_tele_control, which prevents the player fromusing teleport control; not_mappable, which prevents the playerfrom remembering where they've been (like in the Abyss), andno_magic_map, which prevents magic mapping from working.
FLOORCOL: allows you to set the floor colour for the levelthe vault appears in. Should only be used for bazaars andother portal vaults.
FLOORCOL: allows you to set the floor colour for the level thevault appears in. Should only be used for bazaars and otherportal vaults.
ROCKCOL: allows you to set the colour of rock walls for thelevel the vault appears in. Should only be used for bazaars andother portal vaults.
ROCKCOL: allows you to set the colour of rock walls for the levelthe vault appears in. Should only be used for bazaars and otherportal 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 preventthe item from being randomly being made racial. Has no effectif the item can't take that kind of racial setting.NOTE: Can result in a non-racial item if used with "any" andthe 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 usedto prevent the item from getting an ego. The item mustbe 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 anego 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 itemfrom being randomly being made racial. Has no effect if the itemcan't take that kind of racial setting.NOTE: Can result in a non-racial item if used with "any" and thechosen 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 theitem from getting an ego. The item must be fully specified, sotrying "any weapon ego:vorpal" or "any armour ego:positive_energy"will result in an error. Trying to give an ego to something whichcan't accept an ego will also result in an error.
WARNING: While checks are done to make sure that an armourego isn't given to a weapon, a weapon ego to a missile,and so on, and also to make sure that egos are only givento amrours, weapons and missiles, no other checking isdone. Thus it is possible to create a demonic weapon ofholy wrath or a helmet of running.
WARNING: While checks are done to make sure that an armour egoisn't given to a weapon, a weapon ego to a missile, and so on, andalso to make sure that egos are only given to amrours, weapons andmissiles, no other checking is done. Thus it is possible to createa demonic weapon of holy wrath or a helmet of running.
Limitations: You can't specify curse status, specificypluses 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 ornumber of charges, force a randart or give fixedarts. You alsocan't lay down corpses, skeletons, or chunks.
will prevent monsters from randomly being generated on shallowwater squares. Note that if shuffling and substitutions causeW 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, butthat's still a higher degree of control than you get with TAGS.
will prevent monsters from randomly being generated on shallow watersquares. Note that if shuffling and substitutions cause W to end upas water 10% of the time and floor 90% of the time, then those floorsquares will still have no_monster_gen set, but that's still a higherdegree of control than you get with TAGS.
If TAGS has been used to set a mask for the entire vault, youcan 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 useKMASK to remove that mask from particular symbols. For instance:
When the horn is sounded, the stone arch at D becomes theportal 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 toDis, the arch at G becomes the portal to Gehenna. This behaviourapplies only to the Vestibule of Hell.
Lua markers are used for more complex triggers, such as forbazaar and labyrinth gates, rune pickup triggers forthe branches of Hell, fog generators, etc.
Lua markers are used for more complex triggers, such as for bazaarand labyrinth gates, rune pickup triggers for the branches of Hell,fog generators, etc.
For a full explanation of the various paramenters, read theheader of dat/clua/lm_fog.lua.
Feature names used in markers must be names matching the names inthe 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 thenames in the source code. There's a full list of featurenames in section I (Feature names) at the end of thisdocument.An important thing to note with markers is that they arealso considered map transforms along with SUBST, NSUBST andSHUFFLE. You usually want to place a MARKER line after allSUBST, NSUBST and SHUFFLE lines so that the final positionof the marker key is used. For instance, if you want toattach a marker to the rune in a map when you're randomising
An important note about markers is that they are also considered maptransforms along with SUBST, NSUBST and SHUFFLE. You usually wantto place a MARKER line after all SUBST, NSUBST and SHUFFLE lines sothat the final position of the marker key is used. For instance, ifyou want to attach a marker to the rune in a map which randomises
because the marker will be placed at O (the rune), then Omay be shuffled to a different position. The correct orderin this case is:
because the marker will be placed at O (the rune), then O may beshuffled to a different position. The correct order in this case is:
If you're using continuation lines for comma-separated lists of itemsor monsters, split your line after the comma, not before. For example:
If you're using continuation lines for comma-separated lists of monsters oritems, split your line after the comma, not before. For example:
Spaces before the \ of the continued line are significant, leadingspaces of the next (continuing) line are not. In other words, given:
Spaces before the \ of the continued line are significant, leading spaces ofthe next (continuing) line are not. In other words, given:
Crawl translates level (.des) files into Lua code chunks and runsthese chunks to produce the final level that is generated. While youdon't need to use Lua for most levels, using Lua allows you toconditionalise or randomise levels with greater control.
Crawl translates level (.des) files into Lua code chunks and runs these chunksto produce the final level that is generated. While you don't need to use Luafor most levels, using Lua allows you to conditionalise or randomise levelswith greater control.
Now let's say you want A, B, and C to be randomly rock or floor, but Bshould be floor if both A and C are rock. Here's one way to do it (addthese lines to the map definition):
Now let's say you want A, B, and C to be randomly rock or floor, but B shouldbe floor if both A and C are rock. Here's one way to do it (add these linesto the map definition):