Ivory Siege Tower

mobile construct built of thoughts and parentheses

D23 Inspirations and Tools

[2023-01-08]

dungeon23 st_lounge ttrpg

So, #dungeon23 it is. Or in my case, Æonic point-crawl within a (re)discovered space cluster. A polygon for the level design ideas and itches, all of them, since there is plenty of time to - finally - try make them a dedicated cozy intergalactic space.

My attitude towards the #dungeon23 is that of a media project where I intend to combine my original ideas together with some generative art techniques, 3D kneecap-sketching and whatnot. Even more, the bunker-crawl is to become a part of my recently formed lifestyle of using emacs as a superb textual medium. A massive addendum to the hypertext labyrinth that wondering adventures find in a form of the Siege Tower.

I've mentioned the original design idea of the Backwater Sector bunker-crawl sequence in the Intro. Here I'll try to sum up the inspirational influences, as well as the tooling that I'm gonna use for this marathon.

§ Inspirations

§ RPG Setting Flavor

During the cursed year of 2022 I've turned back to a hobby that has a proven therapeutic impact: the Tabletop pen-and-paper (and VTT) Role-Playing Games. One can judge by looking at the Library Hall featuring mostly rulebooks recently.

The genre dominating my brain is Science Fiction, and among old but gold Traveller and new creations like Mothership and Death in Space one stands out for me as an ultimate setter of tone and inspiration for what should become my game: Suldokar's Wake made by the same person who is ultimately responsible for Whitehack (a universal and compact ruleset that is never off my desk).

I've written a review on the Wake recently, that might sound as obscure as the book itself, and the two big problems with it which are:

  1. it's unclear how to run this game - the rules are quite complex - and

  2. it's unclear what exactly to run.

The book insists on following the official metaplot, however only one introductory adventure is available at the moment. The rest looks to stuck "in development" for a while.

I want to fill this gap so hard that in fact unconsciously the ideas I had in mind for the #dungeon23 from the very beginning were forming themselves into a bunker-crawl. Here, enumeration of the key points that are borrowed primarily from the Wake:

  • levels are represented by ancient, æonic structures on each planet in the set, built by a civilization that predates any other;

  • the Great Adversary of that civilization was banished eons ago, but is slowly returning, with its shadow influence tainting the physical world - the Hidden Enemy trope;

  • later plenty of civilizations rose and fell over centuries, leaving different culture and technological layers.

The most influential of those cultures left their inheritance within the dungeon walls. Also partially inspired by the Wake, I intend them to be:

  1. Æonic. Only known for their colossal structures left within the Backwater Sector: environmental processors, planetary defence systems, dreadnought mecha chassis.. The Holofields and Nanite clouds are thought to appear around that time, as are evidences of massive confrontation with an unknown Darkspace enemy. Style: huge scale in everything.

  2. Dynasty of Xhi, also often read as Ksilians. Highly technically developed civilization that at the same time kept a tribal social structure. Those could be decadent descendants of their æonic ancestors, or a separate dying culture. They left first written chronicles and cipher tomes with instructions for the Guardians - cybernetic protectors of their places of worship. But the most miraculous are the Makers: automated factories that require vast amounts of resources and energy to operate. Style: ornate murals, ziggurats and mausoleums.

  3. Thaldean Empire. Theocratic human Empire that spawned throughout the sector and was keen on genetic engineering rather than cybernetics. Although treating the artifacts of previous cultures in with respect, Thaldeans were not able to fully understand nor convert neither of them. Moreover, their experiments have opened a gate for the ancient Adversary to materialize back in the Universe. So far in a rare case of Rogue Guardian Replica, or a genetically treated natives gone insane and forming a cult of Shadow Worshippers, but one could maybe spot a pattern? The empire eventually dissolved, leaving every world in isolation before rediscovery by the Consortium. Style: Baroque-decorated biolabs and cryotank complex.

  4. Natives. Local societies independently developing after the fall of thaldeans. Their technological progress and social structure described by each planet's UWP.

  5. Galactic Consortium. "Present" time industrial galactic civilization under federative corporate rule. Recently discovered and absorbed the sector, turning it into important trade route and aiding local rulers with developing conventional technology where possible. Origin of the Player Characters. Take them from the Traveller or Mothership, or Death in Space - most of the "Industrial SciFi RPG" archetypes should fit here.

§ Tooling

§ Editor Choice

First of all, the favorite editor on steroids. Not only for writing and self-publishing, obviously (although it helps a great deal with both the structuring of projects and the way I share them, more on it here). There are extensions that fit well for the task of dungeon building too.

Take for example random tables. The key to stoking variativity arguably lies in combination of several random tables that do not to be huge for some interesting results (take for example the brilliant obscure spell generator from Maze Rats). For Emacs we have decide-mode that behaves like your local perchance: a simple grammar for combining random outcomes. One problem - the package does not provide an option of using Org-mode tables as input... but that's easy to add - we're in Emacs after all!

§ Dealing with Balanced Generators

Extending Org tables with decide-mode functionality can be done via one function implementation like the following. I replicate it here, though the source of truth is located in the Org section of My Elisp Definitions.

  (defsubst my-org/decide-push-org-table (name data)
    "Push DATA from Org table to the `decide-tables' under NAME."
    (let ((formatted
           (mapcar (lambda (rec)
                     (if (second rec)
                         (cons (second rec) (first rec))
                       (first rec)))
                   data)))
      (push `(,name ,@formatted) decide-tables)))

The odds of the table choices are either spread equally in case of a one-column table, or taken from the first column otherwise. Creating tables in Org is blazing fast, and so is editing and using inline dungeon stocking generators for me now. A few examples follow.

There is an interesting approach of transforming Moldvay combination of two tables for dungeon stocking into a compact one, where decision is made upon one roll of d20. Twice as interesting if you realize that the author of that post also uses Emacs for digital writing and publishing, but for some reason avoids plugins like decide-mode and programming capabilities, that would easily allow said table combinations. Well, here is the alternative.

oddsContents and Treasured20
5Empty1-5
1Unguarded treasure6
1Trap and Unguarded treasure7
2Trap8-9
3Monster10-12
3Monster and treasure13-15
5Special16-20
(my-org/decide-push-org-table "generic-stocking" data)

The last column with d20 outcomes is for reference in case I'm in a mood for using an analog randomizer :), it's not accounted for by decide.

The tiny code block above I execute once to register the table. There data represents the table's raw data in emacs lisp with :var data=generic-stocking code block directive.

After that I can use it anywhere I write my dungeon rooms description with a call to decide-from-table. I just select a registered table from the menu, and...

[<generic-stocking>] -> Empty

...viola, new Empty Room appears in the buffer! Ready to be, em, stocked.

But what if I want to concretize the generator table with some setting flavor, or to fuse several generators in one? Like if for my setting when characters enter an Empty or Special room they should dive into that place origin epoch:

backwater-epoch
(A) Æonic
(X) X/Ksilian
(T) Thaldean
(N) World Native
(C) Consortium
(my-org/decide-push-org-table "backwater-epoch" data)

The monster, say, can be an animal, sentient humanoid or cybernetic guardian:

backwater-monster
Humanoid [backwater-taint]
Animal [backwater-taint]
Guardian
(my-org/decide-push-org-table "backwater-monster" data)

And while the Guardians cannot be tainted, biological organisms can be altered by Shadow mutation or go mad in case of sentient humanoids. Note the reference in the square brackets that I will fill in right now:

oddsbackwater-taintd6
2Pristine (Sane)1-4
1Shadow Mutant (Mad, Cultist)5-6
(my-org/decide-push-org-table "backwater-taint" data)

Last touch: edit the original table:

oddsContents and Treasured20
5Empty: [backwater-epoch]1-5
1Unguarded treasure: [backwater-epoch]6
1Trap and Unguarded treasure: [backwater-epoch]7
2Trap8-9
3Monster: [backwater-monster]10-12
3Monster: [backwater-monster] and treasure: [backwater-epoch]13-15
5Special: [backwater-epoch]16-20
(my-org/decide-push-org-table "backwater-stocking" data)

Some of the outcomes when calling the composed generator:

[<backwater-stocking>] -> Empty: (A) Æonic

[<backwater-stocking>] -> Special: (N) World Native

[<backwater-stocking>] -> Monster: Guardian

[<backwater-stocking>] -> Trap and Unguarded treasure: (T) Thaldean

[<backwater-stocking>] -> Monster: Guardian

[<backwater-stocking>] -> Monster: Animal Pristine (Sane) and treasure: (X) X/Ksilian

Keep in mind dear reader, that what for you looks like a formatted text, for me was an automated random tables composition. An Interactive Fiction game session in a sense, quite enjoyable already!

And by the way, with this approach the original Moldvay stocking procedure can be used without modifications.

§ Inline Image Generation

Composing images in-place can also be done within Emacs using it's SVG library. This is suitable for drawing simple diagrams as well as for procedural generation of some abstract art.

In the corresponding section in My Elisp Definitions I have a few tweaks to prettify the drawings and make the output somewhat interactive. With them, the star cluster diagram from the intro can be built like this:

  (require 'my-svg)

  (my-svg/reset-canvas 900 600)

  (let ((systems '(("R" (150  100))
                   ("G" (275  100))
                   ("A" (275  200))
                   ("V" (400  200))
                   ("O" (525  200))
                   ("M" (525  300))
                   ("P" (650  400))
                   ("H" (650  500))
                   ("T" (775  500))))
        (links '(("R"  "G")
                 ("R"  "A")
                 ("G"  "A")
                 ("G"  "V")
                 ("A"  "V")
                 ("V"  "O")
                 ("V"  "M")
                 ("O"  "M")
                 ("M"  "P")
                 ("P"  "H")
                 ("P"  "T")
                 ("H"  "T"))))
    (loop for link in links
          do (let ((x1 (-> (assoc (first link) systems)
                           (second)
                           (first)))
                   (y1 (-> (assoc (first link) systems)
                           (second)
                           (second)))
                   (x2 (-> (assoc (second link) systems)
                           (second)
                           (first)))
                   (y2 (-> (assoc (second link) systems)
                           (second)
                           (second))))
               ;; draw the connections between the systems:
               (svg-line my-svg/canvas x1 y1 x2 y2
                         :stroke-color "#00ef00")))
    (loop for system in systems
          do (let ((label (first system))
                   (x (first (second system)))
                   (y (second (second system))))
               ;; draw the star system marker labels:
               (my-svg/tag-embed my-svg/canvas
                         x y
                         label nil
                         :foreground "#00ef00"
                         :background "#2f4f4f"
                         :font-size 10 ;; I use Iosevka Regular 
                         :stroke 2.0
                         :radius 20)))
    ;; return the contents of the reulting svg canvas:
    (with-temp-buffer (svg-print my-svg/canvas) (buffer-string)))

The Emacs Lisp code may look confusing but is actually trivial: given lists of star systems' coordinates and connections between them it draws the connecting lines and system name abbrev labels. Resulting image is output as SVG and is ready to be viewed straight away thanks to the following code block header incantation:

#+begin_src elisp :exports both :results value file :file backwater-cluster-scheme-gen.svg

Simple schematic map outlines could be also obtained this way. As for the procedural abstractions, some of them could represent useful geomorphs for a dungeon level, like this Diffusion Limited Aggregation fractal built another day:

In conclusion, even if I'm way behind the schedule, I like what is forming within these notes. A labyrinth of narration and code that itself is like an adventure to me. And it is mostly for what the Siege Tower was built in the first place.

This post will be updated with other inspirations and visual editors descriptions...