+Atarius Maximus Posted September 1, 2017 Share Posted September 1, 2017 Here is a random maze generator for the 7800. I wrote this out of personal interest and didn't actually have a game in mind for it, but it could certainly be adapted into a game. I wrote this using the binary tree maze creation algorithm, which is fairly simple. Each block in the maze is checked for an opening in two adjacent directions (in this case south and west), and if no openings exist one is created. If an opening already exists in either direction the block is skipped. The maze is 25x25, but could be made larger. I'm going to be looking at implementing a few other maze creation algorithms as well, I'd like to try recursive backtracking next - it's really cool to watch. There is a simple title screen that is necessary in order to properly seed the randomizer before maze creation begins. I created custom image files, you'll need to download them if you'd like to compile this yourself. Edit: I haven't fully vetted this out to make sure it creates the maze as I described - but hey, it looks like it works. MazeGenerator.bas MazeGenerator.bas.a78 MazeGenerator.bas.bin MazeGeneratorGraphics.zip 4 Quote Link to comment https://forums.atariage.com/topic/269508-7800-random-maze-generator/ Share on other sites More sharing options...
+Atarius Maximus Posted September 1, 2017 Author Share Posted September 1, 2017 I forgot to mention that if anyone would like to use this code for a project, please do. It's free for anyone to re-use, there's no need to ask me first. 5 Quote Link to comment https://forums.atariage.com/topic/269508-7800-random-maze-generator/#findComment-3838877 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.