Latest Uploads
dungeon ma ... litz basic


Crystal Ca ... een So Far


Crystal Ca ... Screen V1


Day 5 Graphic


Mutanty Mo ... Workfiles.


mono images


Forum Home

PlayMyCode: Tiled Procedural Caves/Maps

Posted : Monday, 07 May 2012, 02:09 | Permalink

A few months ago I was playing around with procedural cave generation and came across an idea by Noel Berry that used the concept of "miners" to create the map. I knocked up a prototype using PlayMyCode which produced the following:

Obviously, the above is pretty ugly and needs to be tiled to look more like a map. The usual approach is to use a shedload of nested if/else statements, but last night I came across this incredible idea:

so I applied it (very quickly I might add) to the above map generator and ended up with:

(Use the arrow keys to move the map around and hold down shift and press up or down to scale it)

The tiling code is ridiculously short and simple - amazing

The source code is available on PMC.
Homepage :
Posted : Monday, 07 May 2012, 11:57 | Permalink | Mark Here

We discussed something like this before -
Posted : Monday, 07 May 2012, 13:15 | Permalink | Mark Here

Thanks for the excellent link - provides greater detail to the other I posted
Homepage :
Posted : Tuesday, 08 May 2012, 09:21 | Permalink | Mark Here

awesome ive been thinking of starting a dungeon crawler/rpg but didnt know how to do a randomly generateing map so ill try this :3
Latest Posts
RollerCoaster Tycoon 4
rychan Wed 04:44
Password Security Safety
dna Tue 20:48
GameJolt Revenue
Jayenkai Tue 13:04
AGameAWeek Progress Report
Jayenkai Mon 14:41
Evil Mongoose
Mog Mon 12:27
Arachnophobics Beware
steve_ancell Mon 03:36
confirmation form?
steve_ancell Mon 02:08
Driver survives flying car ride.
steve_ancell Sun 15:17
Weather Symbols
dna Sun 15:00
WebDev Made Easy
dna Sun 13:59

Latest Items
Showcase : dungeon maker algorithm
Jayenkai Wed 01:42
Dev-Diary : More Screens
Kuron Sat 09:01
News : Newsletter #221
Dabz Fri 10:07
Dev-Diary : Crystal Catch Development
rychan Thu 14:38
Link : Sfxr
rychan Thu 04:16
Showcase : SpringySquirrel
Jayenkai Tue 22:58
Dev-Diary : More Planning and Framework Learning
rychan Tue 17:23
Dev-Diary : Another Song
Kuron Tue 09:10
Link : Free 3D characters!
Jayenkai Mon 05:48
Family : Life...
Dabz Mon 04:57
Dev-Diary : New Song
Kuron Sun 17:32
Blog : Got Distracted from code today
rychan Sat 16:52
Dev-Diary : Monkey Day 5
rychan Sat 06:53
Dev-Diary : Monkey Day 4
rychan Fri 13:31
Showcase : Mutant Monty
steve_ancell Fri 08:14

Who's Online
Wed, at 09:33
Evil Roy Ferguson
Wed, at 09:29
Wed, at 09:21
Wed, at 08:18
Wed, at 07:08
Wed, at 04:58
Wed, at 04:56
Wed, at 04:13
Wed, at 02:19
Wed, at 02:12
Link to this page
Site : Jayenkai 2006-Infinity | MudChat's origins, BBCode's former life, Image Scaler.