I am working on a generator for a Dungeon game. Basically, I have different types of rooms, and different shapes of rooms. The different types contain a list of allowed shapes, and each shape contains possible door locations. I have a set box size (4x4), and I want to generate rooms following that size with randomized types, shapes, and doors. I've been doing research for a few days about all the dungeon/house generators I can find but none of them quite fit the bill. They either use corridors, rely on randomized room sizes, or some other quirk. Any ideas about how to go about this would be greatly appreciated. I've attached an example I made that shows about what I'm looking to create.
The requirements are as follows:
- The room shapes are predetermined
- The possible door placements for each room are predetermined
- The full dungeon shape is predetermined, and is always a box (4x4, 8x8, etc)
- There are no big hallways, only doors leading straight to the next room
- There should always be at least 2 big shapes
The closest algorithm that I've found would be a binary space partition, but I'm unsure of how to implement that with predetermined room shapes, all the implementations I've seen randomly select points to divide at with hallways, which wouldn't fit the bill.
Any suggestions are greatly appreciated!