Anon's Procedural Generation Model

It’s been a while since my last low quality creation. So here’s another one.


It’s a simple model that generates a new “room” after the previous “room” when the gui button is pressed.


Tips for adding new rooms:

  • Make sure the room is a model.
  • Make sure all the Rooms are defined in the weight table in the script and their names match EXACTLY (Case-sensitive)
  • Make sure rooms with multiple paths have each different exit renamed, and is referenced in the script as such.
  • Make sure NOTHING is anchored inside the room, but is instead welded to the floor part.
  • Make sure the LastRoomPoint and NewRoomPoints are in the model.
  • Make sure the NewRoomPoint is facing away from the floor and inside the floor so it lines up correctly like this (I used a surface gui to make sure it was facing right):
    Screenshot 2025-03-27 013824
  • Make sure the LastRoomPoint is NEXT TO the floor, and the front facing into the floor as seen below:
    Screenshot 2025-03-27 014035Screenshot 2025-03-27 014124

Note: The model is very lack-luster right now, as it’s currently 1:30am as of writing this post. Also, comments are placed in the script to teach people how it works.


Model


If you have any suggestions or criticisms, feel free to tell me!


Latest update:

4 Likes

Version 1.1

  • Added auto generate feature
  • Added weighted rooms
  • Added a new room for testing weighted rooms
  • Removed Herobrine

That’s a really weird restriction :sob:

What’s with all the restrictions man

The way :PivotTo works, you have to unanchor all the parts otherwise they don’t get pivoted

Odd, I never had that problem when pivotting room models

1 Like

This is my first time using :PivotTo so I don’t know why it’s doing that. But just in case the issue replicates to others, I figured I’d mention it

1 Like

Version 1.2

  • Added Rooms with multiple paths
  • Added generating the next room with a Proximity Prompt
    (Note: Using the Generate Room UI button will not generate all paths for a branching room)

Version 1.3

  • Fixed a bug that didn’t delete the correct Proximity Prompt when activated.

That is probably become you are using :PivotTo() on a specific part, and not on the whole model. When doing so, :PivotTo() acts very similarly to using .CFrame directly

Either way, I recommend keeping it like this (or using .CFrame), as moving welded models this way is much more performant than moving entire unwelded models. The roblox engine has some kind of optimization for welded assemblies

1 Like