I’m have building system, which can place various blocks, wedges, spheres; and furniture like doors and windows.
But can I somehow detect rooms, which created by player?
What’s I mean about room:
This “room” contain 6 basic walls, and haven’t any gaps.
This’s NOT room:
This isn’t room, due to blank spaces in walls, which I marked with red color.
The main problem can exist with rooms like this:
This “room” have a lot of walls, which are placed chaoticly.
But this room shouldn’t be counted as room if it will contain any gaps:
Red shows blank zones here too.
I’m saw some topics about creating rooms in 2D grid space, but nothing about 3D without any normal grid (grid exist, but it very small - 0.001 studs, plot size is 250x250 studs, so I can’t say I have grid.)
What I’m want know - does this room detection ever possible, if blocks also can be rotated in small angles like 0.1 degree?
And if yes, what’s the most efficent way to achieve it - flood fill, raycasting, or something else?