![endless maze generator algorithm endless maze generator algorithm](https://miro.medium.com/max/1400/0*I8Q8ot3zIqyFBQJD.png)
This algorithm produces mazes with a serious flaw: the North and West borders of the maze are completely open. Thus, it also determines the direction of the skew inherant in this algorithm. Determines which corner of the maze to start looping from.For every cell in the grid, knock down a wall either North or West.
![endless maze generator algorithm endless maze generator algorithm](https://catlikecoding.com/unity/tutorials/maze/10-colored-rooms.png)
Binary TreeĬlick to see the Binary Tree in Action The Algorithm This is perhaps the most common maze-generation algorithm because it is easy to understand and implement.
![endless maze generator algorithm endless maze generator algorithm](https://rosettacode.org/mw/images/5/54/MathematicaMazeGraph.png)
This algorithm treats the cells of a maze as a graph, and solves to find a Uniform Spanning Tree that covers that graph. Repeat step 2 until all cells have been visited.If the neighbor has not yet been visited, add the traveled edge to the spanning tree. Choose a random neighbor of the current cell and visit it.Maze-Generating Algorithms Go back to the main README Aldous-BroderĬlick to see Aldous Broder in Action The Algorithm