#26 – Maze generation

I’ve got maze generation to work! Using a randomized depth-first search algorithm, I was able to produce this:

maze

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

However, I’m already sensing a problem here. As you can see, the paths don’t branch a whole lot – finding your way around is pretty easy. Starting from the upper right (where the generation starts), you go quite a ways before even having a decision to make. Not ideal! I think I’m going to just start over and use a different algorithm (namely, Prim’s), as it produces a lot more branching paths, which is great for the gameplay I plan on implementing with this maze.

Comments

Miltage
27. Apr 2013 · 13:48 UTC
A-maze-ing.