The Magic of Magicbuilding:  Dungeons, No Dragons

The Magic of Magicbuilding: Dungeons, No Dragons

Welcome to the Magic of Magicbuilding, our little spinoff feature that focuses specifically on building a magical system for a fantasy setting.  This week, we're going to build a dungeon.

What We Have So Far

Last week, we finished our examination of adventuring parties, the most heavily armed groups on the world of Istenaiti.  These groups make their money mostly by delving into the dungeons that the world itself creates in a semi-conscious effort to control, contain, and destroy the invading energies and creatures of other dimensions.

When we first discussed dungeons, we talked about how they would come about- they are an immune system response from a world that possesses magic.  We've also discussed how the primary purpose of that magic, at least for the people who live on said world, is to manipulate the dimensional energies of other worlds.  What we didn't mention, but which makes sense, is that the world itself would use magic the same way.

We're mentioning it now because it will let us very quickly figure out what a dungeon is like: it will look like something a determined caster could make, if they only used magic in the construction.  We can also make a couple of other assumptions regarding the construction, but the rest of the assumptions are more for ease of magicbuilding than because they make some kind of absolute sense.  For example, we're going to say that dungeons are mostly underground, and this is because the planet has no concept of civic engineering, but we already know that large buildings could be constructed by even fresh-from-the-Stone-Age mages, so that rule isn't nearly as hard and fast.  Expect the rest of the reasoning to be about that feeble; it'll hang, but probably won't be load-bearing.

Procedurally Generated

The single largest supposition we need to make is about how the dungeons are actually, y'know, designed.  It isn't like the planet keeps an engineer on staff, and we've thus far worked under the supposition that whatever divinity might exist in this world, it doesn't actively intervene in the material realm.  That means that the planet itself has to come up with the designs, and it must do so within the constraints of "only semi-conscious" and "not actually what we would define as 'intelligent.'"

And hey, wouldn't you know it?  We have some experience with that kind of thought.  We're going to approach this from two linked concepts:  procedurally generated systems and the digger wasp.  One of those you may have heard of.  The other's a little more obscure.  We'll explain both real quick.

A procedurally generated system is just that:  a system that is generated, not by creating a design, but by following a set of procedures.  Sufficiently complex lists of procedures can create systems (such as dungeons) that appear to be both random and designed.  As it happens, even simpler procedures that introduce an element of randomness can do the same, though the results may turn out either truly weird or suspiciously similar, depending on how the procedure corrects for catastrophic choices made via said randomness.

The digger wasp is of the breed of insect most normal people refer to as "scary."  It attacks prey insects, paralyzes them, drags them to its nest, inspects the nest to ensure its eggs are safe, and then pulls the prey inside.  It performs this complex set of tasks with a brain the size of a grain of sand.  How does it manage to do so flawlessly?  It turns out this is due to having a preset "program" of behavior.  Back in the early 80's, philosopher Daniel Dennett described what happened if an outside force quietly changed the process while the digger wasp wasn't looking; if, while it was inspecting its nest, someone moved the prey a couple of inches away, the wasp would apparently think, "Oh, I'm back at 'drag the prey to the nest,'" and then repeat the activities from there.  He opined that the digger wasp would do this indefinitely.  Now, it turns out that this is a cool philosophical idea, but in real life, the digger wasp eventually figures out that something is messing with it and alters its pattern.  That said, this is magicbuilding, not real life.  We can totally use this same concept.

So:  through a combination of trial and error (the error being dungeons that collapse prematurely or do not draw in monsters in magic as planned) and influence from the thoughts of creatures with magic, the planet has developed a procedure for building dungeons.  This procedure has the simultaneous advantage and disadvantage of continuing to be influenced by the thoughts of creatures with magic, so dungeons evolve.  The overarching procedure "seems" to be (we'll avoid setting it in stone so we can make changes as necessary) a series of rooms with resources, connected by corridors with traps.  The further into the dungeon one gets, the greater the resources and the more dangerous the traps.  Moreover, the traps are built in such a fashion that they become deadlier when leaving the dungeon than they are when entering.  If there were a thought process behind this setup, it would be that creatures are enticed into the dungeon and then trapped there.  As an added layer of security, the corridors are intentionally maze-like, and the rooms are built such that under normal circumstances, there is only one exit from each room.  While more intelligent monsters may consider the rooms to be defensible, the exit cuts both ways- once within a room, it becomes more difficult to leave and easier to block the only avenue of escape.

This setup can be handled by procedure, and in fact basic dungeon-building programs use a similar procedure to make dungeons for roleplaying games.  The biggest differences between those programs and this procedure is that the procedure is easily influenced, introducing new changes due to external forces, and that, like the fictional digger wasp, if the procedure is interfered with, there's no intelligence to fix the issue... meaning that if the basic setup can't be followed for whatever reason, dungeons get weird.

Some Assembly Required

Our dungeons now consist of the following basic parts:

  • A Single Entrance, large enough to allow monsters entry
  • A maze of corridors, trending downward and (while varying in size to create bottlenecks) on average large enough for monsters to freely move through
  • A series of traps that work on very basic mechanical and/or magical principles- pit traps, falling rock traps, traps that cut off movement in one direction, traps that briefly render an area deadly
  • A series of rooms that are not trapped and which contain enough resources to entice monsters into them; food and water for many dungeons, but can vary as long as the resource can be magically generated (such as a room that exudes a specific emotion in a dungeon designed to trap the fae)
  • A general increase in difficulty and reward as one progresses further into the dungeon, accompanied by traps that work directionally (safe for travel in one direction, but not another)

To go with this, we need a few more pieces.  A big one is determining how large a dungeon gets, and this requires some more superficially sound reasoning.  We've already said that dungeons are created using magic.  It stands to reason that, outside of some very basic sigils that could evolve in the same way sigils appeared on monsters, the world doesn't use sigil magic.  They therefore make use only of ambient magic, which is limited.  This in turn limits what the dungeon can do, as well as how big it can grow.  It is also an excellent reason for the dungeon to exist in the first place: by expending the ambient magic, the planet gets rid of it just as it is attempting to get rid of the living invaders.

This reasoning also means that a dungeon that successfully contains monsters will be exposed to more magic... and can use that magic to continue to procedurally generate more dungeon.  The better the magical mousetrap is, the larger it grows.  Mousetraps that don't work run out of magic, and then time works its will on the inner workings.  Over time, the dungeon naturally collapses... which also serves a purpose, burying whatever is left of the monsters it trapped beneath the earth, just as if it was fixing nutrients into the ground.

One more thing that a successful dungeon will need over time is loot.  We already expect that our adventurers are intentionally, if not consciously, used as one further form of monster control.  Considering the amount of magic used by a typical party, they're likely also used as a power source, similarly to the monsters captured.  It stands to reason (feebly, don't look too close) that the most successful dungeons will be those that draw the greatest number of adventurers, and the best way to draw adventurers is to give them something beyond monsters that they would want to recover from the dungeons.  Now, given the influence conscious thought has on the design of a dungeon, it is entirely possible that (using elemental magics) a dungeon would eventually figure out how to create actual pieces of equipment... but much more likely is that dungeons with valuable natural resources that can't be created but could be manipulated (gemstone and metal veins, for example) would start appearing, at first by accident as the dungeon dug deeper but increasingly as part of the procedure.

Conclusion

We now have everything we need to build a dungeon.  We have a series of rooms and corridors, traps, mazes, areas of safety and danger.  We have monsters, and we even have gold and gems, though you'll need a pickaxe to collect them.  Most importantly, we have the logic necessary to justify how the dungeon works.

We still don't have an actual example dungeon, though.  We'll tackle that next time.

Back to blog

Leave a comment

Please note, comments need to be approved before they are published.