Procedural Dungeon Generator
The Procedural Dungeon Generator is an easy to use, tile based dungeon generator for Unreal Engine. Built in blueprints, this is an easy to use tool to kickstart your procedural projects.
Plug in your own custom themes and decorations, then adjust the linearity and complexity of the dungeon to find the shape and style that fits your project.
Each path type has its own unique mesh pallet with an array for each building block to add even more variation. Add custom meshes for as many unique paths and rooms as you desire and even adjust the heights of the rooms pre-generation.
This project includes the main dungeon blueprint, Data Tables for editing Room/Path themes, functioning keys/doors and lights, and five example blueprints for adding procedural decorations.
Change Log
-
Changes
Changed Path Trim Material to assign to “Trim” Material slot instead of MatSlot 1
Changed DoorActor in KeyLocks Struct to WallDoor Actors Array
Changed KeysLocks in path themes to Key/KeyLockData combinations to allow multiple door variations to be assigned to single key
Removed Tall Mesh Variations
Removed Boss Mesh Variations
Scalable Room Height
Replaced the short and tall room system with a scalable room height float.
Dungeon can be assigned a max room height and rooms will randomly generate between 0 and max height.
In the path/room settings rooms can be locked at a specific height instead of only tall, and will generate only at that height, or the max height of the dungeon if the max height is lower
Additions
Added Dungeon Height Variation
Dungeons can now generate with height variation between rooms.
New rooms will generate one tile above or below the floor of the previous room.
Corridors are now built at the level of the lowest room, spawning a staircase doorway in the floor of the higher room.
If a corridor passes through a previous room above the floor the generator will build bridges cutting through the previous room.
Other changes
Ended support for Unreal version 4.27
This and future updates will only be for unreal 5.0 and above.
Version 2.1 in unreal 4.27 has been released as a free project and will not be recieving any more feature updates
-
Fixes:
Fixed issue when paths are enabled that would cause a default path to generate instead of an available themed path
Fixed and issue that would cause default door frames to spawn in corridors between rooms of another theme
-
Fixes
Fixed Decorations spawning repeatedly when using World Partitioning
Fixed issue where hallway entrances that are culled are not added back to room when building halls
Torches now adjust lighting to account for grid scale
Fixed debug lines not despawning when debug mode was turned off
Changes
Removed Door and Torch spawning functions
Added Door actors to DT_RoomData as a Themed Decoration
Added WallDecoration actor to DT_RoomData to replace Torches
Removed Room Merging to prevent locked doors from being avoided
Blocked rooms from spawning over corridors, spawning locked doors before the key (Corridors can still spawn through previous rooms creating looping paths)
Updated Dungeon Entrances and Exit, adding corridors and restricting generation to avoid paths being blocked
Additions
Added Key/Lock System
Dungeon can be assigned any number of key/lock combinations
Each room is procedurally assigned a locked door with the associated key spawning in the previous room, or any previous dungeon room.
Each room type can be assigned a themed key/lock combination in DT_Default_RoomData to be spawned instead of a random one. The Boss key always overrides procedural generation to guarantee the boss room spawns with the desired key.
Keys and Locks can be any desired blueprints
Added Dungeon Paths
Dungeon generation can now be split into path segments of varying length until the desired dungeon length is reached.
Path segments can be generated linearly, or branch off of random rooms along previous paths
Path rooms have assigned keys and locks, allowing for controlled progression through the dungeon, even when backtracking or overlapping paths.
-
Fixes
Fixed torches not being relative to world position when spawning
Fixed hallway corners not being removed from intersecting rooms
Additions
Add option for wall entrance and exit
Adjust grid spacing and dungeon size with GridScale variable
Add option to generate dungeon on Runtime