Post news RSS Procedural Altar Generation

A detailed analysis of the procedural aesthetic & thematic generation of ANSI religious altars!

Posted by on

In keeping with my mission to push procedural generation away from the “classics” – monsters, dungeons, levels – and towards more “qualitative” concepts that have never been generated before in games (nations, cultures, societies…), URR (as regular readers know) contains a range of procedurally generated religions. These are not just a name and a belief, but are designed to be complex, interwoven and often competing systems that procedurally generate a deity or pantheon of deities; their beliefs and forms of worship; what, if anything, is banned in their religion; what festivals (if any) they perform; what agendas the clergy of this religion have; what other religions they might consider to be infidels; where in the world the religion is found; the religious symbol; their cosmogenic and eschatological beliefs; what heretical sects within that religion exist; and – the focus of this blog entry – their altars.

This blog entry is a detailed post about generating the ANSI (ish) graphics for the altars (or “shrines” in some cases) for all religions.

There are three “classes” of religion – monotheistic, polytheistic, and what I’ve termed in the game’s code as “spirits”. Feudal civilizations can have either monotheistic or polytheistic religions (but are slightly statistically biased towards monotheistic, because there is more procedural variation within that type) whilst “spirits” religions are used for hunter-gatherer civilizations, who have a range of animistic of shamanistic beliefs, totemism, ancestor worship, etc. Nomadic civilizations, reflecting their role as melting pots of varied cultures and beliefs from across the globe, never have an official state religion (inasmuch as there is even a clear concept of “the state” in these civilizations). Each of these three kinds of religion has a wide set of different possible altars or shrines, based upon a significant number of archetypes which each contain within them a massive amount of variation.


Within monotheistic religions there are four possible archetypes for deities – to use the terms used in-game (though these are not seen by the player), religions can be “demonic”, “eldritch”, “egyptian”, or “general”. Each of these has its own algorithm for generating and selecting the depiction of the altars at which their devotees worship.

The first of these we’ll look at are what I’ve been calling the “egyptian” god type. These are gods that adhere to names of the sort “The ____-headed God” or “The ____-headed Deity”, and so forth. The heads of these deities, so to speak, are generated according to the climate within which that religion was first found. A religion founded in a cold, polar region might have a “bear-headed” god or a “wolf-headed” deity, whereas in the desert regions you may find those worshiping their “scorpion-headed” or “scarab-headed” equivalents. The altars, in turn, are generated with a central image, a colour, a selection of candles, and an altar shape. Here are two examples: on the left is the rather more ‘abstract’ symbol for a deer-headed god (with a particular randomly-chosen shape and colour), and on the right we have an altar for its bear-headed cousin. There’s over thirty different animals, a wide range of colours and shapes for the altars, and therefore a massive potential variation in the altars of the animal-headed gods.

The second are the “eldritch” gods. These are loosely based on Lovecraftian ideas, but also upon some of the more unusual gods in real-world pantheons (though generally ones no longer actively worshipped, or at least not by large numbers) which are not just “a person” of some description, and either have an unusual depiction, or are entirely animalistic. For instance, Chinnamasta is a Hindu goddess who holds her own severed head in her hands; the Rainbow Serpent in aboriginal myth (though these gods in URR are somewhat less benevolent); Lei Gong in Chinese myth; the Gnostic god Abraxas, and a few inspirations from voodoo, central American myth (primarily Aztec), and some of the truly bizarre demons from christian demonology (especially ones like Buer). This gives rise to gods like Uur Quog, the White Wolf of the Pit and Guardian of the Gate; or Fallin’thopar, the Transient Vulture of the Mountains and Taker of Souls. Those who like their Lovecraft can clearly see the procedural naming convention here, even if the descriptions and depictions of these deities draw from elsewhere as well. Their altars have a wide range of designs, “inscriptions”/patterns upon the altars, colours, bases, and patterns upon the basic, again yielding several thousand possibilities, of which two examples can be seen here:

The third are the “demonic” gods. These altars are the least procedurally-generated of the bunch, though still exhibit some variation in colour, and association with different forms of “demonic” gods. These are not gods which are worshipped secretly, or underground – these are clear, visible religions just like all the others in the game, but these deities are just not the most pleasant of sorts. In part my inspiration here was from the classic understanding one has of the “Old Testament” christian god – all fury, hatred, vengeance, wrath. I wanted to introduce some gods which were perhaps worshiped out of fear rather than out of the love and gentleness generally associated with the judeo-christian god in the present day, but at the same time deities who might have beliefs associated with them that state that although these deities are brutal and bloody, they are perhaps fair, or just, or expect a lot from their worshipers, or might give their worshipers great power in return for their loyalty:

The last class of monotheistic god is the “general” god, though that hides the significant level of variation within those gods, and their altars. In this case an altar for these other gods – such as the Cold King of the Moon, or the Lord of the Tall Grasses – consists of two components. The bottom half is a block of stone, wood or other material, over which is draped a cloth (all procedurally generated) which bears the symbol of that religion and some other general decorative patterns down the side. On top of that is placed one of roughly forty different items, ranging from candelabra to bowls, statues to bones, and plants to statues of various animals. Here are some examples of this last type, which generally makes up around 60-70% of monotheistic religions in a game world, whilst the rest are of the above “rarer” types.


Polytheistic religions also use three different altar archetypes, which are selected at random for each polytheistic religion. Around 80% of the time they will use the “general” altars described and shown above – a block of stone or carved wood, with a banner, and with a symbol either appropriate to some aspect of the deities or chosen at random from a much larger set of “general” religious symbols – but the other half of the time they will use altars that fall into another category. These are for gods of a pantheon centred around ‘elemental’ concepts or other groups like metals or stones (such as the Deities of the Five-Fold Firmament, or the Divines of the Six Elements). All those names are, of course, also procedurally generated from large and varied libraries of names/words. We’ve seen the “general” altars, so let’s look at these elemental ones.

I’m academically quite interested in alchemy, pre-modern interpretations of “elements”, and the interactions between the two, and this archetype draws on alchemical concepts and also a few of my own which are related, but not quite drawn directly from real-world history. There are several different “sets” of “elements” that might be chosen for a religion of this sort – they might be the traditional fire/water/earth/air/etc, or slightly more unusual. In the picture below, these are for two different elemental pantheons. The altar on the right has been generated for a pantheon of five gods, in this case gods of the sun, the moon, the earth, comets, and stars; the right pantheon has seven gods, in this case gods of gold, silver, bronze, platinum, tin, copper, and iron. As above, these are rare “religion types” and will not crop up often, in keeping with good procedural generation where all possibilities are not equally weighted. As with all the other altars here, there will be clues towards these altars scattered around the world, and the nature of the altars will be referenced in a thousand different places and integrated into the world’s cultural fabric.


As with everything in the game, these are designed to be integrated into the clues and hints the player pick sup. Perhaps the player will be suggested that a priest who worships at the altar of the three candles is harbouring a secret, and only one altar has three candles at the top? Similarly, if you come across an unknown altar, the experienced player should be able to make a reasonable guess about what kind of deity it “belongs” to, and if they have uncovered a range of deities that are worshiped but haven’t encountered their altars, they should be able to piece together this kind of information. Equally, as with all the other graphics in the game, these graphics are designed not just to aid in the kind of discovery/exploration/information gameplay that really interests me, but also just to aid in constructing a densely detailed procedurally-generated world. Several people have said they think URR stands already as the most detailed proc-gen world ever crafted; although I appreciate the appreciation (as it were), I think that’s a little premature, but the details in the interior of buildings (such as altars) this release (March, hopefully) should certainly move URR much closer to meriting such praise.

In Conclusion

What I’ve shown here is only the slightest fraction of the religious altars that might be generated in a single game world of Ultima Ratio Regum. The majority are the “standard” archetype, which gives far more impact to the discovery of one of the more unusual ones. The five different altar types all draw on very different traditions, either aesthetically, thematically or both, and offer similarity within an archetype whilst still remaining highly distinct, and having enough noteworthy features to allow their descriptions or nature to be disseminated by information throughout the game world. Lastly, if you liked this entry, please share it on your social media outlet of choice! To conclude, here’s an in-game screenshot of the player exploring a (procedurally generated) church, and finding the altar, and giving it a look (this being one of the ones shown in the examples above, in this case for a demonic deity called the King of the Spire):

And, a Reminder:

International Roguelike Development Conference (Europe)

I’m hosting this year’s IRDC! I’m trying something a little different this year and I invite everyone to come along. You can read about it here on this website, on Reddit, or on Roguetemple, and please get in touch if you’re planning on coming along! The more the merrier, and this year’s will be something really different and, hopefully, something really awesome.

Post a comment
Sign in or join with:

Only registered members can share their thoughts. So come on! Join the community today (totally free - or sign in with your social account on the right) and join in the conversation.