Unstable Selection is a whimsical action Roguelite about mutation. Adapt to a hostile and changing environment by absorbing the abilities of the creatures you defeat, and become who you were meant to be!

Comments on Level Generation

I was the author of our level generation code, and the above video shows the steps that go into making an Unstable Selection level. The algorithm has two phases: terrain generation and object generation.

Terrain generation starts by applying a cellular automaton to a grid of random noise. This creates the general cave-like structure of the level. Then, post-processing steps are applied to make the level well-connected, full of lock-key-puzzles in the form of environmental obstacles, and with a clear path from start to exit.

For object-generation, I wrote a tool in the Unity editor that enabled our lead artist to create object-spawning rules without having to touch any code. I built the tool to solve the following problem with our level generation. Our level generation is not room-based, like most Roguelike games. Instead, we basically have one large room in which we have to create interesting gameplay situations. The larger the space, the more difficult it is to control. The tool makes sense of these large level spaces by identifying different types of sub-regions (dead end regions, choke regions, wall regions, critical path regions, etc.) and allowing the end-user to define rules that say how different types of objects (different types of power-ups, enemies, decorations, and obstacles) should spawn in relation to those regions (within, bordering, in the center of, along the edge of, etc.). As an example, we defined rules that spawn treasure and creatures guarding the treasure in dead end regions, rewarding the player for exploring non-critical regions of the map.