Dungeon Builder (Development Thread)

classic Classic list List threaded Threaded
34 messages Options
12
Reply | Threaded
Open this post in threaded view
|

Dungeon Builder (Development Thread)

SamuelF
This post was updated on .
Dungeon Builder - Random Dungeon Generator


I've been stuck indoors this weekend with a case of man-flu, so I've had a bit of time to work on this project (requested by Mortis in the dice simulator thread).



It's currently at the stage where it will generate rooms, but not corridors. I've made the grid editable however, so if you want to change the the colour of any tile just click on it. If you make the board really big or ask it to make a ton of rooms, it can take a few seconds, so be patient. The code will do its best to draw the number of rooms asked of it for the space allowed. If it doesn't draw them all just click generate again and cross your fingers!

DungeonBuilderLATD01.swf

You can find a Flash player here if you need one: http://www.adobe.com/support/flashplayer/downloads.html

Anyways, late now. All feedback welcome as usual.



-------------------
Edit -
-------------------
22/6/10 - Most recent version: DungeonBuilderLATD03.swf
25/5/10 - Version 0.2: DungeonBuilderLATD02.swf
17/5/10 - Fixed a browser re-sizing problem that prevented large board areas from displaying.


Reply | Threaded
Open this post in threaded view
|

Re: Design Tool: Dungeon Generator

Marchomer


It's a good work! Is an alpha release, but is already simple and effective! My compliments!
And I think that maybe is a good thing to put the corridors manually, maybe it could in fact be an advantage.
Feedback: I may suggest you a thicker grid or visible borders, so it could be possible to create adjacents rooms and corridors.
+ Other planes lie beyond the reach Of normal sense and common roads But they are no less real Than what we see or touch or feel. +
Reply | Threaded
Open this post in threaded view
|

Re: Design Tool: Dungeon Generator

SamuelF

Thanks man!

Marchomer wrote
I think that maybe is a good thing to put the corridors manually, maybe it could in fact be an advantage.
The more I think about it, the more I agree with this. Random corridors are okay if you don't mind rather odd looking dungeons with very little narrative and the occasional loop that goes nowhere. The random rooms provide a good starting point, and human intervention seems to provide the best solution for the corridors for the moment. None of the algorithms I've looked at so far offer this more artistic element to dungeon design. Plus I actually quite enjoy adding in the connecting squares!

This leads me to propose that the generator stays as it is (unless anyone really wants to push for the corridor generation). Things to add could be an 'editor' option (doors, props etc..), or maybe a save option if needed.

Marchomer wrote
Feedback: I may suggest you a thicker grid or visible borders, so it could be possible to create adjacents rooms and corridors.
The decision to make walls one square thick was partly a practical one. Having thickened borders would come with many complications and for that reason I have avoided it so far. You could generate static rooms with thickened borders, but with the sacrifice of not being able to easily edit the room sizes. However, I could add it to the list of things an 'editor' would offer and you could put them in by clicking (for the moment one solution is to edit two rooms together and draw the partition by hand).


Reply | Threaded
Open this post in threaded view
|

Re: Design Tool: Dungeon Generator

SamuelF
Quick update - Having spotted Mortis's post with the 'Into The Unknown' random generator rules here, I am more open to the idea of generating corridors and a dungeon with a 'narrative'.
Reply | Threaded
Open this post in threaded view
|

Re: Design Tool: Dungeon Generator

Marchomer
An "Into the unknown"-like mechanic combined with your generator may become a uuuhm... uuuh...  a very interesting "clean multi-platform missions generator"? I hope so!
+ Other planes lie beyond the reach Of normal sense and common roads But they are no less real Than what we see or touch or feel. +
Reply | Threaded
Open this post in threaded view
|

Re: Design Tool: Dungeon Generator

MortiS-the-Lost
Administrator
In reply to this post by SamuelF
Ah I see this thread is coming along nicely and the project is off to a good start already.

 The editable tiles was something I hadn't even considered the possibly of and it's great, it reminds me of the way you mark out the tunnels you want to dig in Dungeon Keeper (an awesome PC game, if you haven't played it yet go and get a copy now!).
I agree with Marchomer that visible borders, allowing for directly adjacent rooms and corridors would be a useful feature meaning it would be compatible with as many dungeon set-ups as possible. What I suggest is giving each feature of the generator an On/Off flag, allowing users to better tailor what style of dungeon is generated toward their own set-up.  
As for corridor generation I suggest taking a look at how the dungeon generation in AHQ is done. To make it a bit more universal you'll need to add option for how wide corridors should be and have the option for set section lengths. Having to roll dice and look up the results on 30 different charts in the AHQ rulebook can be a time-consuming pain in the arse during a game, but a computer program could swallow all those tables and matrices easily  

ah yes! 'Into the unknown' is also a very good starting place and narrative element it provides will make for much more realistic feeling dungeons.
-----------------------------------
~The ravings of a single mad Goblin is bad enough, but such a power-hungry, malice-filled creature as Mortis can never hope to be understood~
Reply | Threaded
Open this post in threaded view
|

Re: Design Tool: Dungeon Generator

Billiam Babble
In reply to this post by SamuelF
Ooh.  I likes this.  In fact, I rather enjoyed adding/digging the corridors myself.

If you think about it, some dungeons sprawl in all directions and perhaps a treasure map the players have only includes key chambers and vague destinations "Dwarven Hearth Chamber - East" - perhaps magical sensors only pick up the large lairs or treasure hoards. - Leaving the players to fill in the rest...

Nice one.
Reply | Threaded
Open this post in threaded view
|

Re: Design Tool: Dungeon Generator

SamuelF
In reply to this post by MortiS-the-Lost
Thanks for the kind words and enthusiasm guys!

For the past few days I've been working on the 'pseudo-code' for generating a dungeon with corridors, loosely based on ideas in the 'Into The Unknown' dungeon generation rules. I've done a test run using dice, and I'm fairly happy with the results so far:



It took forever to roll all the dice for this so I won't be doing it again too soon  However I'm confident that with a few tweaks it could make some nice dungeons.

Once the code is up and running in actionscript I'll post up the results for your perusal (may be a while as I'll be really busy for the next few weeks). I'm a little way from double width corridors yet, but visible borders are on the horizon (editing via clicking will be possible, it will just take a little longer to edit due to having to click through more tile options).

MortiS-the-Lost wrote
As for corridor generation I suggest taking a look at how the dungeon generation in AHQ is done. To make it a bit more universal you'll need to add option for how wide corridors should be and have the option for set section lengths. Having to roll dice and look up the results on 30 different charts in the AHQ rule-book can be a time-consuming pain in the arse during a game, but a computer program could swallow all those tables and matrices easily  
Ah yes! A generator for AHQ would be a nice thing. It is a slightly different kettle of fish to the generator here as it stands currently. This generator is built for use with battlemats, and has a set boundary (which is partly what makes it so tricky to code). Board game style modular dungeons can sprawl across the floor limitlessly (or until they hit the fireplace). They also use a set of board pieces that are limited in size and number. So I would have to put a little thought into how to implement a 'modular style' option for those that would like to generate dungeons for non-battlemat purposes.

Hopefully I'll have something for you to see in the not too distant future...


Reply | Threaded
Open this post in threaded view
|

Re: Design Tool: Dungeon Generator

SamuelF
Dungeon Builder 0.2

Okay, a small update for you. We now have a rooms-with-borders option: (still no corridor generation yet)



With 'borders' ticked you can still click the tiles to edit, but you will notice that there are quite a few more option to click through.

The coding for corridor generation is taking a little while to wade through  I'll hopefully be able to resume work on it within the next couple of weeks.

DungeonBuilderLATD02.swf

Enjoy!

Reply | Threaded
Open this post in threaded view
|

Re: Design Tool: Dungeon Generator

MortiS-the-Lost
Administrator
 I am loving Dungeon Builder 0.2!

the multiple-clicks to change the boarder round the squares feels very natural and intuitive (if a little time consuming when drawing in long sections) I'd like to request that when you do implement the corridor generating code, you have the option to turn it off (like with the boarders) so people can draw their own corridors in if they prefer.

My next suggestion (and I hope I'm not getting too far ahead here) is to expand the post-generation editing phase to include some icon/symbols you can 'drag-drop' or 'stamp pad' onto the map. Things to represent statues, fountains, traps, grills, pillars and doors, all that kinda stuff (I think doors would need 2 versions, one that would fill a square and another that would sit on the line for maximum flexibility)

the icons wouldn't have to be anything complex, doors can be represented by long rectangles (with an 'S' through them for Secret Doors) and other items could be represented by simple ASSCI characters (in a 'Rogue' type fashion) for example

* = Statue
T = Trap
Ө = Fountain
# = Grill
● = Pillar
O = Well
£ = Chest
~ = Water

(BTW I could come up with ASSCI equivalents of the all the basic dungeon symbols given time  )

Numbers could also be tagged onto the map to help the GM/author add notes to the map.

Don't worry about adding HeroQuest style symbols for the monsters as this would narrow the universal application/flexibility for the program as you'd need an icon for every monster from every system the program might be used with.
It's much more flexible (and easier for the GM) to tag a room/corridor with a number and then write in their notes “12 - this room contains 3 Orcs and a Troll, the Troll is asleep against the West wall blocking the Door and the Orcs are trying to wake it up by poking it with their swords” or “4 - The Statue is of a naked female humanoid with horns and bat-like wings, 2 Dark Elves are kneeling at the base of the statue, they appear to be preying” or “9 - this room is littered with broken furniture, 4 Kobolds are picking though the rubbish, the Chest in the north-west corner is Trapped (poisoned needles) and contains 2 potions of Cure Light Wounds and a worn leather hat” I think you get the idea

my final suggestion (of which I'm not sure how possible it would be) is a Save to File button that  saves your finished map as a JPEG with a little line of text in corner saying something like “Dungeon Map made with SamuelF's Dungeon Builder” so that you'd be credited if someone used it to create maps for a module. 
-----------------------------------
~The ravings of a single mad Goblin is bad enough, but such a power-hungry, malice-filled creature as Mortis can never hope to be understood~
Reply | Threaded
Open this post in threaded view
|

Re: Design Tool: Dungeon Generator

MortiS-the-Lost
Administrator
Hope you don't mind, but I made a quick mock-up of what kind of maps could be produced with my suggestion


 ^ As you can see it looks something like the maps from the early D&D books.
-----------------------------------
~The ravings of a single mad Goblin is bad enough, but such a power-hungry, malice-filled creature as Mortis can never hope to be understood~
Reply | Threaded
Open this post in threaded view
|

Re: Design Tool: Dungeon Generator

Marchomer
In reply to this post by SamuelF


Great work man! Really cool! I wish I could give you some feedback again, but Mortis already said what I thought! I think that after these impovements, you will can say with a pride: "Dudes, we have a stable 1.0 release!"
+ Other planes lie beyond the reach Of normal sense and common roads But they are no less real Than what we see or touch or feel. +
Reply | Threaded
Open this post in threaded view
|

Re: Design Tool: Dungeon Generator

MortiS-the-Lost
Administrator
In reply to this post by SamuelF
Any more progress on this project?
-----------------------------------
~The ravings of a single mad Goblin is bad enough, but such a power-hungry, malice-filled creature as Mortis can never hope to be understood~
Reply | Threaded
Open this post in threaded view
|

Re: Design Tool: Dungeon Generator

SamuelF
Yes, some. Apologies for stalling on replying to this one, and thanks for all the kind words and enthusiasm. The coding for this one requires me to get quite fully involved (there are around 400 lines of code already!) and I haven't quite found the time to fully immerse yet. But I will!

I have looked into the concept of exporting a jpeg of the final map. The problem is that due to flash limitations it would require the use of a php enabled server (which nabble does not seem to be). I could use a different server but that would require upkeep and money to do so. It would also separate the map generating software end from the jpeg exporting end which wouldn't feel very stable. So.. For the moment it's screen capture time. (On the mac it is as simple as apple-shift-3 or 4. Is there an equivalent for PC users?)

The adding of symbols and doors to the map is one that I've been considering for a while and am confident that I'd be able to add that feature very soon. The idea I have is for different edit 'modes' whereby if you are in 'edit symbol' mode when you click on a square, you can then add text annotations to that square (any font requests? Maybe a symbol based font?). When in 'edit door' mode you will cycle through various door placements. This could also be coupled with an area to the side of the map where you can add your own key and text notes.

Another feature in the works is the ability to hold down a hot-key to cycle backwards through square options as I am always clicking one too many!

Corridors are still blowing my tiny mind at this point. I will master them. I will.

Nice Mock-up by the way Mort  (would you be happy with room numbers if they were not on the lines?)

Reply | Threaded
Open this post in threaded view
|

Re: Design Tool: Dungeon Generator

Billiam Babble
You may have covered this already but is there a way of importing pixel tiles - or vector - I could make some, if you're not already doing that yourself.
Reply | Threaded
Open this post in threaded view
|

Re: Design Tool: Dungeon Generator

SamuelF

Billiam Babble wrote
You may have covered this already but is there a way of importing pixel tiles - or vector - I could make some, if you're not already doing that yourself.
Were you thinking of art for tiles / dungeon dressings or something completely other? It could be very interesting. I know you have a lot on your plate at the moment with other projects though, so don't feel pressured or anything matey

Reply | Threaded
Open this post in threaded view
|

Re: Design Tool: Dungeon Generator

SamuelF
In reply to this post by MortiS-the-Lost
Dungeon Builder 0.3

Here is the first version of 0.3. (I'm expecting to need to make cosmetic changes based on feedback)

Firstly without borders:


..and with borders:


As you may guess, we now have an extended editor. Use the new combo-box to select one of three 'edit modes':

1. 'Walls' - This is the same as the click-cycle wall editing from 0.2.

2. 'Doors' - This will cycle through various door types.

3. 'Annotations' - This will allow the user to add their own keys and symbols to the map.


Another new feature is hot-keying. If you hold down the command key during editing, it will cycle backwards through the options (very handy!). If you hold down the shift key and click, it will clear the square of its content (depending upon which edit mode you are in).

Enjoy!

DungeonBuilderLATD03.swf


ps- Mort, I'm thinking of changing the title of this post to something like: "Dungeon Generator - Developement Thread". What do you think?



Reply | Threaded
Open this post in threaded view
|

Re: Design Tool: Dungeon Generator

MortiS-the-Lost
Administrator
Before I start with the feed back, a few notes for those of us using PCs (which I rather biasedly assume will be most us)

SamuelF wrote
 For the moment it's screen capture time. (On the mac it is as simple as apple-shift-3 or 4. Is there an equivalent for PC users?)
The PC equivalent is [Alt Gr] + [Print Screen] and then you can Paste ([Crtl] + [V]) the screen shot into MS Paint and Save it

SamuelF wrote
Another new feature is hot-keying. If you hold down the command key during editing, it will cycle backwards through the options (very handy!).
Although normally Command key + clicking on a MaC is the equivalent of Right Click (back-click) on the PC, back-clicking on a SWF application on a PC merely brings up the Flash Player Menu. If you are using a PC, simply hold down [Ctrl] and Click with the Left mouse-button to cycle backward through the click-cycle.


Ok with that out of the way ... on to the feed back:

Excellent! I've got to say that this has to be the most useful dungeon generator I've used and it keeps getting better! I spent most of yesterday evening playing with this making all kinds of dungeons.

I think the best thing about this dungeon generator that sets it above all the rest, is that it has the edit modes, I'm not aware of any other dungeon generator that lets you play around with the map after editing (most just generate the map and that's it)

The hot-key reverse click-cycling really speeds up editing and makes drawing-in the corridors a breeze

The new Doors Mode is brilliant, again very intuitive and easy to use

Annotation Mode works well, I was going ask that you make the font size a point or 2 bigger but after using the program I can see why it is the size it is.

SamuelF wrote
would you be happy with room numbers if they were not on the lines?
When I did the mock-up I put the numbers on the lines to keep them out of the way of the other symbols, but having used the real Annotation Mode now, I see that isn't really a problem like I though it would be. The numbers are just fine in the squares

Just out of interest what font are you using? The old PC trick of holding down [Alt] and punching the 3-digit character-code into the NumPad to get up non-keyboard symbols works in your program, but I can't seem to find a character-code table that corresponds to the character-map your program uses
With is in mind can I request that you add an extra drop-down menu to Annotation Mode of all the most useful non-keyboard characters/symbols this would make the Annotation Mode more user-friendly and much easier to use for people with compact keyboards like on a laptop.

Also, I'm not sure if it's possible to embed fonts or special characters into a SWF program, but there are a few D&D map-symbol fonts out there (most of them free) which would be very useful to add to the map editor. This triggers the further thought that Annotation Mode could be sub divided into a 'Lettering/Numbers Mode' and 'Symbols Mode' (if it helps I can make some bitmaps of common dungeon map symbols, just tell me the dimensions and/or format you'd need)

One final request is a mode that lets you put down a boarder like the walls but light grey or maybe dashed to allow the user to represent raised or lowered floors such as a Pool or Dais. (no extra colours though I think it's best the program generates traditional looking B/W dungeon maps)

Over all excellent work, I look forward to the next version and in the mean time I will be enjoying the current version

SamuelF wrote
ps- Mort, I'm thinking of changing the title of this post to something like: "Dungeon Generator - Developement Thread". What do you think?
Yea that's fine, go ahead.
On a related note the Forum will be getting a 'Useful Software' Category soon when I get around to doing the re-shuffle
-----------------------------------
~The ravings of a single mad Goblin is bad enough, but such a power-hungry, malice-filled creature as Mortis can never hope to be understood~
Reply | Threaded
Open this post in threaded view
|

Re: Design Tool: Dungeon Generator

Marchomer
In reply to this post by SamuelF


(Am I being understood?)
+ Other planes lie beyond the reach Of normal sense and common roads But they are no less real Than what we see or touch or feel. +
Reply | Threaded
Open this post in threaded view
|

Re: Design Tool: Dungeon Generator

SamuelF
In reply to this post by MortiS-the-Lost
Marchomer wrote
Thank you sir! *takes a bow*


MortiS-the-Lost wrote
The PC equivalent is [Alt Gr] + [Print Screen] and then you can Paste ([Crtl] + [V]) the screen shot into MS Paint and Save it
Thanks for the useful PC tip Mortis. The ctrl-left click for back cycling is good stuff as well


MortiS-the-Lost wrote
Excellent! I've got to say that this has to be the most useful dungeon generator I've used and it keeps getting better! I spent most of yesterday evening playing with this making all kinds of dungeons.
Brilliant! It's hearing stuff like that which makes the effort worthwhile!  I'm also glad that other people are finding it easy to use (I'm rather addicted to clicking out little dungeon plans myself!)

The font I am using is Times New Roman. You can embed fonts in Flash and I think tracking down those D&D map fonts would be a really nice idea. I had already thought about sub-dividing annotations into numbers and symbols etc.. I shall now ponder it further.

The dashed borders that you suggest could perhaps be linked in with a 'dressings' mode that could have stairs etc? I'll think on that a little more as well..

Thanks for the positive response chaps!



12