Game
Mindscape
6 years ago

Dungeon Generation


I spent this week working on special dungeons. So why don’t we talk about how our dungeon generation system works. Warning this might get a bit technical, but i’ll try to keep it as simple as possible.

So how do we get from this

5d09dbc58a249.png

To this

5d09dbc62ecf1.png

First we generate a grid of zeros. Then we go through the grid zero by zero and see if a room will fit and if we want to make one, if we do then we create a box of 1,2,3,4, and 5 (which represent walls) and fill the box in with tens (which represent floor tiles). We save each of these rooms in another array that stores their position and size. After that we chisle out paths connecting each room. Then we populate each room, excluding the start and ending rooms with a monster randomly chosen from the monster pool, or a chest. Then we take this grid of numbers and spawn the corresponding tiles. By leaving things so open ended we can re-use the same dungeon gen for special dungeons by changing the size and number of rooms, the tileset, and the enemy pool. If you have any questions or want a more in depth run down, just let me know. I’ll see you next week with another update :)



1 comment

Loading...

Next up

Ooo Fancy Lighting

Just as Pecaminosa's musicians #improvise this rendition of #LittleSunflower 🌻, so do we improvise with this post you're reading. 😂

What's coming out of your own improvs? 🤔

#Pecaminosa | #IndieDev | #OST | #Jazz

Smile! Here, take some happy pills! ✨💊 #Blender #3DModelling #3DArt Buy me a Ko-fi: https://ko-fi.com/barbarafb_

Been working lately on lots of 'behind-the-scenes' boring stuff that no one really cares about, so here’s a guy playing the sax for some reason.

#screenshotsaturday

🍒Did you like the game? A demo is available for free on Steam.

✌️ Thanks for playing IndieGameiacs!

⚙️ Free Demo: http://bit.ly/UniDuni

📺 Full Video: https://youtu.be/5qEbVXg7GaQ

#steam #uniduni #clops #screenshotsaturday

Finished work on the emotions of a new character for the tank universe

The Darkside Detective: A Fumble in the Dark is out TODAY! 🖱️Advanced pointing, clicking action 🖨️Very funny words! Loads of them! 👻6 sarcastic, spectral cases to solve

Microsoft Windows XP Unprofessional (windows logo prototype)

I worked so hard to get all four of them to the end safely, but then...