Frequently Asked Questions
Can DunGen be used for 2D games?
Yes. DunGen works just as well with 2D games as it does with 3D. There's even a (very) simple 2D demo scene included.
Does DunGen support loops?
Loops (paths that connect back up to the rest of the dungeon) are not supported. There are two ways to get a kind of looping behaviour, but they can't be relied upon if it's important that your dungeon loop back on itself.
- You can achieve incidental loops by using the
Doorway Connection Chancefeature in the DungeonFlow. This will try to connect any Doorways that coincidentally overlap, but were otherwise not connected. This method is unreliable and you don't have much control over where or how loops form. - Small local loops can be formed by making a tile that consists of multiple rooms. This method is more reliable, but since they're made up of a single tile, loops cannot connect two different parts of the dungeon and should be kept relatively small.
Can I generate dungeons in the editor, or does DunGen only support runtime dungeons?
DunGen can generate dungeon layouts entirely in the editor if you'd like. Just use the window located on the main menu under Window > DunGen > Generate Dungeon.
Can you save a dungeon layout and come back to it later?
The random number generator used by DunGen is seeded. If you need your players to be able to revisit a previous floor, for example, you would store the seed used to generate that floor. DunGen could then take that seed and generate an identical layout (including props). Of course, you'd need to also save any changes that were made to the dungeon (such as chests being opened) and re-apply them once DunGen has finished generating the layout.
Does DunGen work with outdoor dungeons as well?
While DunGen wasn't made with outdoor scenes in mind, it doesn't care what is contained within a tile. These are a few things you'll have to consider when using DunGen in an outdoor setting:
- DunGen was made for interior scenes, so in order to avoid your scene looking like a corridor, each Tile will need to be fairly large.
- You'll need a way to cover any Tile edges that aren't connected. The best way to do this is to have a cliff mesh (or some other large, natural structure) that blocks the edge of the tile. You'd then use a Doorways Blocker list to make this mesh only appear when the Tile is not connected to anything along that edge. See the Doorways section for more information.
- Standard portal culling won't provide much benefit (if any) when your doorways stretch the length of your tile. You'll need to make use of some other culling solution.
Will DunGen work with this art pack?
There are no strict requirements when it comes to the assets you use with DunGen. Any modular art pack should work without issue (although if you're mixing packs, it's best if all of the art uses the same grid size).
I'm getting some errors after installing DunGen
If you're updating from a previous version of DunGen, try deleting the old DunGen folder from your Assets directory before importing the new version. This will ensure that any files that have been removed or renamed in the new version are properly cleaned up.
Whether you're updating or installing for the first time, it's sometimes possible for the package to be corrupted during download or import. Try re-downloading and re-importing the package from the Unity Asset Store.