I’m trying to write a script that generates a random dungeon every time a button is clicked. I’ve spent multiple hours on it and got it to somewhat work. Most of the time it freezes or rooms intersect.
My Current Attempt at generations (Very pitiful)
There are four 4 types of rooms:
Intersection: This has 3 points where any room can connect
Hallway: This has 2 points for any room to connect
Hallway_WithDoor: This has 3 points for any room to connect
Room: This has 1 point for any room to connect
I created parts in each room titled “GENERATION PART” where other rooms can connect.
I’ve attached the world below if anyone would like to take a look. If I could just get this working maybe I could work on a seed system but right now I just want the map to generate randomly to a set number for each rooms. What would be the best way to approach this?
RNG_Generation_Attempt.rbxl (44.2 KB)