Results 1 to 31 of 31

Thread: [RESOLVED] Random Maze Generator

Threaded View

  1. #1

    Thread Starter
    Addicted Member
    Join Date
    Dec 2013
    Location
    Earth
    Posts
    230

    Resolved [RESOLVED] Random Maze Generator

    Hi!
    Good morning to you all. I had a random idea of making a random maze generator, but may need a bit of help. What I do is create wall "Blocks" (with properties of X, Y, and Type) through the whole maze. So first thing, every block in a grid is changed to a pathway "Block." (White is pathway, black is wall.)
    Attachment 123991
    Then, every block connecting to 2 walls has about a 20% chance of becoming a pathway.
    Attachment 123993
    After that, every block connecting to 3 or less walls will become a pathway.
    Attachment 123995
    Edit: When I say connect, that means diagonal as well.
    (I don't think I need to put code here because I explained it pretty accurately.) Now, this code is pretty random (and inefficient.) There is no Start/End, there are some loops, and also some pathways aren't even connected to the rest. I found this: http://en.wikipedia.org/wiki/Maze_generation_algorithm but I was not sure how to put those into VB code.
    Does anyone know how to do these things in VB 2010? I appreciate this.
    Thanks
    ~Nic
    Last edited by NinjaNic; Feb 21st, 2015 at 01:46 PM.

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width