Created for/r/proceduralgeneration'smonthly challenge.
PressEnter to generate a new dungeon, more shortcuts⌨️here. All the options are available via the context menu (right-click on the generator).
You can use images created by the generator as you like: copy, modify, include in your commercial rpg adventures etc. Attribution is appreciated, but not required. Please consider supporting this project onPatreon☕!
| Status | Prototype |
| Category | Tool |
| Platforms | HTML5 |
| Rating | Rated 4.9 out of 5 stars (1,180 total ratings) |
| Author | watabou |
| Genre | Role Playing |
| Made with | Haxe,OpenFL |
| Tags | Dungeon Crawler,Generator,Procedural Generation |
| Average session | A few seconds |
| Languages | English |
| Inputs | Keyboard,Mouse,Touchscreen |
| Accessibility | Color-blind friendly,High-contrast |
| Links | Patreon,Twitter/X |
Log in with itch.io to leave a comment.
https://dysonlogos.blog/2013/12/23/the-key-to-all-this-madness/ (the generator use only a few of them)
My method is described here: https://www.patreon.com/posts/hatching-in-1pdg-31716880. I've improved it since then but the core idea remains the same.
Hi Watabou! Just wanted to let you know that I created a smallFoundry module. It's basically only your maps, walled, with some journal entries. For now, I only used 5 maps generated by 1PD, but I plan on doing more, also using other genarators. Cave/Glade and Dwellings would fit right in, I think.
Thank you so much for all you do!
You might likeDungeonScrawl for this. It's not generated, but it's easy to use. The free version lets you do plenty, but cannot export at 100 px.
Okay here's a technical question for you on your "non doors" code. I thought I had this particular door case cracked but maybe not.
My approach was to draw these doors using two rectangles. In this example, my left rectangle would just emulate the corridor. The shape fill is the same color as the floor and the right side line is the same as the walls.
Then I was going to draw a second rectangle for the right side but realised it needs to be transparent (or something) to display the hatching underneath BUT also not show the corridor.
Can you please go into a little bit of detail in terms of the door algorithm you used to achieve this. Am I on the right track?
In this case there is only oneleft rectangle. There is no right rectangle (which should be the same as having a transparent right rectangle if you need it for some reason), so the hatching is not obscured. There is no explicit corridor underneath all this, so I don't need to care about showing/not showing it. The whole cell is a corridor and a door at the same time.
Thanks bro. In my code I draw one door and rotate it depending on its properties in the json:
door.dir.x is horizontal (left or right facing)
door.dir.y is vertical (up or down facing)
So if you were to turn doors off in your code, is this sort of what you'd expect a map to look like?
To achieve something that even closely resembles what you you have made I need to draw doors over the walls that mask what . It's a pain but I also love learning this stuff.
Anywho. The more I tinker with this, the more admirable I find your attention to detail and the skill needed to pull it all off elegantly. Even the Dyson hatching and the seed generation method. Hot dang it's cool. I'm guessing you're an old school Flash Dev :)
Hey waabou. Greetings and hope you're well.
A question. Could you add support for?notes=off to the request string?
For some reason adding ?notes=offactually seems to work on FirefoxSOMETIMES but not all the time and I have no idea why. Ideally there is a way for me a way to download the dungeon png without notes + the json for the same dungeon.
https://watabou.github.io/one-page-dungeon/?notes=off&tags=compact,small,square,cramped&export=png
Hi Dan!
The "notes" parameter (or anything of this kind) is not currently supported. The last selected notes mode is saved locally, so it may sort of "work" in one browser but not in another - you have selected different modes in different browsers. If you need to download maps without notes, all you have to do is to select"Notes > Off" once and that's it. No more notes until you changed it.
What does alignment mean when two levels have different shapes? For example, how can you know that these two levels are not aligned:
?
There are many algorithms for dungeon generation. This one is my own invention and as such it's not exactly elegant. Its advantage is that it can produce maps that look kind of human-made, because they are they are "partly symmetrical". Here is how it works:
That's it. There are some nuances to make it work and more nuances to make it work adequately, but that's the idea.
You can try to examine the published js code as@BorisTheBrave did with the cave generator: https://www.boristhebrave.com/2023/11/19/how-does-cave-glade-generator-work/
Thank you so much for your reply and for sharing the link I'll definitely go through it and study the concepts. I truly appreciate the effort you've put into your work, and I can only imagine how valuable it is to the community.
I completely understand if it's not the right time to release the code as open source, but if there's any chance I could have access to a part of it for personal study, it would mean a lot to me. I’m eager to learn from it, and I believe it could greatly enhance my understanding. Of course, I would respect any limitations you’d like to set.
Either way, thank you again for the insights and your time. I'm really grateful for your work!
I was wondering if it would be possible to have an option for a different kind of legend, one that provides a prosaic description of each room (ie. only the features visible on the map, without any imagined details added).
For example:
1. This 20' x 30' rectangular room has a doorless archway on the north wall and a set of double doors on the east wall. A crate and some rubble is lying on the floor.
2. [Description of Room #2]
...
This would help LLMs or other AI models better understand the dungeon layout so they can generate themes and embellished room descriptions that more closely match the map.
Example Prompt:
"The attached image shows the layout of a dungeon. Please provide a theme or history for this dungeon, then write a detailed description of it including specifics for each of the numbered rooms."
Note that this would work best with unrotated maps, unless a "North" indicator is provided (and AI gets smarter).
Can you possibly add a button or some GUI to allow us to manually rotate the map?
I use this alot for grabbing some rooms from one generation and other rooms from another generation and sometimes the shadows don't match up, if i was able to rotate it the shadows would be uniform.
Great tool either way!
You can request a dungeon with a set of specific tags via the url parameter"tags" :
https://watabou.github.io/one-page-dungeon/?seed=177003564&tags=backdoor,chaotic....
It is also possible to make the browser download a map (as png/svg/json) right after it's generated:
https://watabou.github.io/one-page-dungeon/?seed=1143801683&export=png
Since it's a purely client-side application, there is no real api to work with it.
UnlikeCave Generator (with itsconnected andtree tags), here I have much less control over the way rooms are connected. I'll think about it, but right now I don't how this could be implemented in this generator.
You are probably talking aboutAzgaar's Fantasy Map Generator (made by Azgaar), there is some limited integration between this world generator and mycity generator. The closest thing I've ever done isPerilous Shores.
I've been using your maps for a long time now, both as a dungeon master and as a developer for testing our team's tabletop map projection software Infinite Realms.
I recently implemented support for the Universal VTT file format in our app and was wondering if you would be interested in this as well for this generator. UVTT supports light, grid and wall placement information and more. The information is in JSON format and the map image is a base64 encoded string in the same file.
The format is supported by a growing number of map generators and VTTs, so it may be worth a look... ;)
Arkenforge has posted a blog post on the specs, along with a demo file here: https://arkenforge.com/universal-vtt-files/
I love this generator (and all your others). I was playing with it, and decided to play around with the water level settings a bit. I wondered what it would be like with various water depths indicated (so like, this area is water level 1, that area is deeper, like 5, etc) - I decided to layer levels 1 to 5, so that the smallest area (where depth 1 covers) is 5, the next is 4, etc. Here are my results:
it would be cool if you could include something like this, but even without, this is a really great tool. Thanks for all the cool stuff you make, and especially for sharing it freely!
some of them, yes, there is some tags that doesn't quite fit well and others tag that are "missing". also the style is a bit different, I know is only aesthetic but still..
2 of the main difference would that the general shape should be far more compacted and the final map must resemble some kind of "shape" (squared, elongated, triangular...).