Why isn't my maze generation algorithm working properly?

-5

So I am working on a maze generation algorithm for a project in C language. The algorithm is based on the Modified Prim's algorithm where you check a field's neighbours and move through the whole thing opening up walls between neighbours. The problem is that the leftmost column of the maze becomes an unreachable hallway 100% of the times and I don't know why it happens. The second problem is I have a size selector implemented with 33x33, 65x65 and 129x129. But 75% of the times I run with the largest size the console crashes with -1073741819 (0xC0000005) error message. So if you are familliar with mazes and could check out my code it would be appreciated. This is the c code:

https://drive.google.com/file/d/1WvxD7pC86dbbYIU_J4BG6esyDtOL12N1/view?usp=sharing

c
maze
prims-algorithm
asked on Stack Overflow Oct 19, 2020 by Cubemaster

0 Answers

Nobody has answered this question yet.


User contributions licensed under CC BY-SA 3.0