Methods for procedural Level Generation. Part 1

Methods for  procedural Level  Generation. Part 1

Bellow I will highlight various methods of PLG.

This method is from   and can be found here.

First Marcin set some rules for the dungeon


  • room is a large area that has one or more exits
  • corridor is a narrow and long area that may be sloped, and has exactly two exits
  • junction is a small area that has three or more exits
His Algorithm is as follows:


  •   Each dungeon piece is marked with its connection/exit points. The Generator has a set starting piece and stores that rooms exit points.
  • new pieces are randomly chosen (they still follow some rules) and attached to the exit points of the list (and are deleted from the list). Then the new rooms have their available points added to the list.
  •  This is repeat until the dungeon is built.


Marcins algorithm for creating a level. 

Benefits
  • It gives the room designer complete freedom in the shape and size of the room, and there is no restriction to the number of exits. 
  • It does not use a grid layout.
  • By setting exits at different heights it will in turn create a level of different heights.
Disadvantages
  •  The level branches out but never reconnects, it would need additional code to join the rooms at some points.
  • Collision detection is needed in case two parts are placed upon each other.

Comments

Popular posts from this blog

Player stats and brightness.

Testing the PLG

More work done on the interface, saving data.