This is a system I'm working on that creates a randomly generated map with 8 rooms, this is going to be the movement + world gen for an upcoming project I'm working on, this is still a W.I.P. so expect bugs, use if you want but I would recommend waiting for it to be done
It is not the best, it could be optimized (it will at some point), most times the blocks overlap, and sometimes blocks spawn outside the boundaries, what I have for this later is I'm going to add a player and door gen so you can get from room to room.