Map Editor:  Automatic Dungeons

Random Dungeons are a quick, easy way to populate your area with leveling areas. They can be placed in your area by using the random_dungeon archetype found in the 'special' category on the archetype browser. The "edit random dungeon" dialog is currently broken, but the random dungeon that you have placed can be edited as follows:

  1. First, place the random dungeon where you want it to go in your map

  2. Second, right-click the stairway that appears when you place the random dungeon. Select 'All Properties' in the pop-up menu.

  3. In this dialog, edit only the properties which are mentioned here. Editing other properties could cause the random dungeon to work improperly or not at all.

  4. Change the door-arch property's value to the door that you want to appear in the random dungeon, such as walls/brickwall_door Only one type of door can appear in each dungeon.

  5. Change the door-hp property's value to the number of hit points that you want the door to have.

  6. Change the dungeon-name property's value to something appropriate, such as 'Minath Ruins.'

  7. Change the floor-arch property's value to an appropriate floor for the dungeon, such as terrain/rock.

  8. Change the terrain-arch property's value to the terrain that is to fill in the area that is not in the dungeon, such as terrain/empty.

  9. Change the wall-arch property's value to a wall that matches the door-arch property's value, such as walls/brick_wall.

Please note that the random dungeon will work fine the way that it is. You don't have to change all of these properties, only the ones that you want to, which may be none at all. That's fine. A random dungeon is perfectly flavorful without having exotic floors, walls, and doors.

For more information on editing in the all properties dialog, refer to the All Properties Editing section.

Manually Creating Random Dungeons

At the moment, the editor for random dungeons doesn't work. So below is a sample of what the properties should look like so you can edit them by hand:

<arch loc="2 2" path="special/random_dungeon">
  <image layer="-500" path="indoor/stairs_downW"/>
  <string name="unavailable-message" value="The well is filled with water."/>
  <string name="wall-arch" value="walls/brick_wall"/>
  <string name="dungeon-name" value="Mountain Well"/>
  <string name="terrain-arch" value="terrain/cave_wall"/>
  <string name="floor-arch" value="terrain/dirt"/>
  <int name="danger-level" value="6"/>
  <int name="door-hp" value="50"/>
  <string name="door-arch" value="walls/brickwall_door"/>
  <music path="music/midi/spooky/samhoc.mid" repeats="-1"/>
</arch>

All the values should be fairly self-explanatory. However, note that terrain-arch has to be a valid terrain, and door-arch has to either be a valid door arch, or "none".

danger-level is the starting danger level for the dungeon. At the moment, beyond danger-level = 6 maxes out pretty quickly. You can also set:

<int name="fixed-danger-level" value="1"/>

This is particularly useful for random dungeons in newbie areas. They don't get harder with that setting. Also useful newbie areas is:

<boolean name="never-dark"/>

Without this setting, levels of the dungeon will randomly be dark. On the flip side, you can set:

<boolean name="always-dark"/>

to make all levels dark. Nice for mines, caves, etc. and more dangerous areas in general.

Another feature of random dungeons is the ability to have them lead to a non-random map, the way the dungeon beneath Tornaum Castle is. To do this, set:

<string name="level-#" value="path/to/map/goes/here"/>

where # is the level you want the bottom non-random map to appear at, and the value for the string is the path to the bottom non-random map. Then in the header of the bottom non-random map, you need to add (using a text editor) the (x,y) coords of where the stairs that connect to the random dungeon will appear:

<int name="upstairX" value="#"/>
<int name="upstairY" value="#"/>

If there are a lot of maps after the first non-random, you may want to mark the first non-random as never-unload, so it doesn't unload and mess up the stairs connecting to the random dungeon.

Finally, one tricky but very important aspect of random dungeons: the name. It has to be unique, as the maps for random dungeons are tracked by the name. If it isn't unique, there's a chance a player will go into a random dungeon in your area and come out of it in someone elses!. So it's best to preface the name with something about your area, and conclude with the number or direction to make it unique from your other random dungeons. For example, the well in Davos has two random dungeons in it. They're named "Davos Well West" and "Davos Well East".