Random Cave Generation

I've been looking a bit into random level generation during the last week. In the search, I found a couple of articles that caught my attention:
The problem with algorithms like these is that they easily can become too random. To prevent this I went for a slightly different approach with a higher degree of designer control. The quest designer creates a set of nodes that define the different steps in the quest and place out areas they can spawn in. These nodes are connected based on the sequence you have to do the actions in - marked as 1 and 2 in image 1. There's also an optional boss marked as ?.
Image 1
Before the level is generated, the template is randomly rotated and flipped to make it seem a bit more random (not done in the example). The level generator then connects the nodes depending on the environment type. This test uses an algorithm based on Fractal Accretion, but I'm planning on adding support for other algorithms that are better for buildings and structures.
Image 2
Image 2 shows the generated map which will be used as the basis for the tilemap.

No comments: