Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Code Snippets / DBPro 2D/3D random maze generator

Author
Message
DeepBlue
20
Years of Service
User Offline
Joined: 17th May 2003
Location: A little box in the UK
Posted: 23rd May 2004 13:48 Edited at: 1st Jul 2004 10:21
Please use the Code Snippet box below and not the source button.

[Edit]Now updated to work with 5.4[Edit]
[Edit]Does not work with DBC & will take me to long to convert[Edit]



Code also includes some basic sliding collision/timing, but requires more work. Main purpose of the program is to demonstrate a fast understandable maze algorithm.

Most of the examples I've seen either use recursive function calls, and/or are totally impossible to follow the program flow. The actually maze generation in 2D is also twice as fast as the best db example I could find.

Originally intended this code to get butchered in a 20liner, but couldnt bring myself to do it, so expanded it instead, hopefully I've added comments where required.

The coder formerly known as Twynklet.
DeepBlue
20
Years of Service
User Offline
Joined: 17th May 2003
Location: A little box in the UK
Posted: 23rd May 2004 13:57 Edited at: 1st Jul 2004 10:18
[Edit]Above post now amended[Edit]

The coder formerly known as Twynklet.
flibX0r
21
Years of Service
User Offline
Joined: 14th Feb 2003
Location: Western Australia
Posted: 27th May 2004 13:24
I'm not stalkin you. Honest.

Like it. Works quite fast on my computer. I don't think i'll have any reason to use it for anything but i'm sure someone will

DeepBlue
20
Years of Service
User Offline
Joined: 17th May 2003
Location: A little box in the UK
Posted: 27th May 2004 22:32
Thnx fibble

Think I might go build a random dungeon generator now (no idea why, sommit do do aint it)

Then again I accidentally made some organic growth algorithms when I first started the above by mistake (Now Im thinking texture generators or trees...bah I know I'll have a coffee instead )

Twynklet
Oibaf2000
20
Years of Service
User Offline
Joined: 31st Jan 2004
Location:
Posted: 28th May 2004 00:35
Any chance you make this work using DBClassic?
DeepBlue
20
Years of Service
User Offline
Joined: 17th May 2003
Location: A little box in the UK
Posted: 30th May 2004 00:02 Edited at: 1st Jul 2004 10:22
[Edit]See top post[Edit]

The coder formerly known as Twynklet.
Oibaf2000
20
Years of Service
User Offline
Joined: 31st Jan 2004
Location:
Posted: 31st May 2004 15:42
Cool thanks Twynklet. Good luck with the server migrations..

-Oibaf2000

Login to post a reply

Server time is: 2024-05-13 01:35:52
Your offset time is: 2024-05-13 01:35:52