ABSTRACT

In this chapter, the authors explain how they built the random puzzle generation system that powers Desktop Dungeons' replayability and the issues that made that a unique problem. Often, the primary role of a procedural puzzle generator is trimming down a larger puzzle-space into a subset of possible puzzles that differ along axes that can be easily randomized. One way to guarantee solvability and continuity is to start from a specific randomly generated goal state and repeatedly undo atomic player actions at random until game developer reach a state of desired complexity. Adding layers of heuristics to the generation systems produced encouraging results. The first heuristic attempted to keep the available resource costs near player starting positions by introducing a minimum distance threshold to enemy spawns. The second heuristic made lower-level enemies look near their random spawn locations. Finally, they made specific glyphs that could have smaller but still useful impacts at lower player levels.