Search Unity

World Building [RELEASED] Dungeon Architect

Discussion in 'Tools In Progress' started by AliAkbar, Aug 9, 2015.

  1. chiefarchon

    chiefarchon

    Joined:
    Jun 22, 2009
    Posts:
    80
    Thank you for the answer and that is a nice example thanks :D
     
    neoshaman and AliAkbar like this.
  2. eTech3D

    eTech3D

    Joined:
    Feb 2, 2014
    Posts:
    18
    Thanks @insomniaunleashed for the info...
    Thanks @AliAkbar for the reply and waiting for the theme with Eternal Temple
     
  3. wojciechsek

    wojciechsek

    Joined:
    Dec 7, 2014
    Posts:
    3
  4. Kevin_Scott

    Kevin_Scott

    Joined:
    Jan 6, 2015
    Posts:
    4
    OS Omega is looking fantastic. Would love it if you shared your scripts @arturmandas
     
    hopeful likes this.
  5. arturmandas

    arturmandas

    Joined:
    Sep 29, 2012
    Posts:
    240
    Thank you, soon it will be ready, hope to release it early next year :)
     
    Kevin_Scott likes this.
  6. arturmandas

    arturmandas

    Joined:
    Sep 29, 2012
    Posts:
    240
    Sure, give me just some time to clean it up and prepare some basic doc, will send a link near the end of this week or the beginning of next (much work).
     
    Kevin_Scott likes this.
  7. AliAkbar

    AliAkbar

    Joined:
    Jun 30, 2014
    Posts:
    729
  8. AliAkbar

    AliAkbar

    Joined:
    Jun 30, 2014
    Posts:
    729
    I'm experimenting with a side-scroller builder. Some very early screens:


     
  9. rrahim

    rrahim

    Joined:
    Nov 30, 2015
    Posts:
    206
    That is something I'd definitely love to see in this package.
    I'm already using it for some randomization, but a sidescroller with randomization is something I've always wanted!

    Keep up the good work with the updates.
     
  10. Puggy

    Puggy

    Joined:
    Jun 10, 2015
    Posts:
    6
    Hello,

    I'm building a 2D game and considering using Dungeon Architect. Your 2D example/demo with the rabbit is very similar to the style I'm going for, so that makes me hopeful. I've got a couple of questions though:

    Do you plan to integrate DA with the 2D tilemap that Unity has been developing (currently in the 2017.2 beta)? Combining their editor tools with your paint mode, or being able to place their programmable tiles or custom brushes into a DA theme, for example.

    Is there a way to connect multiple dungeon grids together? I'm hoping to make a large seamless game world made up of multiple areas such as a forest, a desert, multiple towns, etc. Each one would need their own theme, obviously, and would likely also use their own Dungeon Builder so that the areas feel different. My main concern is that the player should be able to walk from one area into another without a loading screen or interacting with a door, etc.

    Thanks in advance!
     
    Last edited: Jul 15, 2017
    AliAkbar likes this.
  11. spryx

    spryx

    Joined:
    Jul 23, 2013
    Posts:
    557
    @AliAkbar
    This image should be part of the documentation, IMHO. Calling something "empty" made me assume that it should indeed be empty... not expecting something of its own type. "Occupied" is ambiguous as well (I had first incorrectly assumed that it means it was occupied by the marker type). The spatial constraints are rather confusing in the regard. Additionally, do non-3x3 constraints work with sprites? Only the 3x3 spatial constraint seems to affect sprite markers at all.

     
    AliAkbar and Dwight_Everhart like this.
  12. Sehee26

    Sehee26

    Joined:
    Mar 13, 2014
    Posts:
    19
    Hi @AliAkbar,
    Is there a date for the next update?
    Will there be changes in the floorplanner?

    Thanks.
     
    AliAkbar likes this.
  13. wojciechsek

    wojciechsek

    Joined:
    Dec 7, 2014
    Posts:
    3
    Hi @AliAkbar,
    I just run Snap Builder in Unity, and its great!

    Is there any way to randomly decorate the room with some elements ? I mean room that is one of the modules of Snap Builder.
     
    AliAkbar likes this.
  14. R1PFake

    R1PFake

    Joined:
    Aug 7, 2015
    Posts:
    540
    Hello, the asset looks awesome and i will most likely buy it and use it for different projects.
    For one project in mind i have a maybe uncommon question, in the game i would like to create random levels, with different paths / rooms / props etc but the uncommon thing here is that i would like to go in a straight line, so the whole random dungeon has to go from the start forward no left/right turns, while the way forward itself should split up in different random rooms / hallways (as long as they all go forward, stairs up and down would be ok but is not required). Is this currently possible with the asset to create the random dungeon in forward line without any hallways leading left/right)
     
    AliAkbar likes this.
  15. arturmandas

    arturmandas

    Joined:
    Sep 29, 2012
    Posts:
    240
  16. Rob604

    Rob604

    Joined:
    Jul 16, 2017
    Posts:
    1
    Very interested in this! One question, is the generator able to incorporate prebuilt rooms into the runtime generation? And for the generator to create a specific amount of prebuilt rooms - for example 1 boss room, 2 loot rooms, 4 encounter rooms, etc.
     
    AliAkbar likes this.
  17. Duffer123

    Duffer123

    Joined:
    May 24, 2015
    Posts:
    1,215
    @AliAkbar ,

    Hi. Looking at buying this Asset. Would be nice if it landed on a sale... ;)

    Quick question though (silly question really) - can this be used on an existing terrain and if so what does it do to that terrain to smooth it and make everything fit?
     
    AliAkbar likes this.
  18. Xepherys

    Xepherys

    Joined:
    Sep 9, 2012
    Posts:
    204
    I went a different route and created a modified SpecialRoomFinder script that uses GridDungeonModelUtils.FindFurthestRooms() to find the rooms furthest from one another. I then mark one as the starting room and one as the goal room. The script takes three GameObjects, a spawnPortal, and endGoal (which is currently just a differently colored portal), and a playerObj that I set from the inspector. There's some additional code instantiates the player on top of the spawnPortal object. This all occurs on OnPostDungeonBuild().
     
    AliAkbar likes this.
  19. hopeful

    hopeful

    Joined:
    Nov 20, 2013
    Posts:
    5,682
    My guess is you'll be waiting a while. It was just on a 24-hour Unity sale a couple of weeks ago.
     
    AliAkbar likes this.
  20. arturmandas

    arturmandas

    Joined:
    Sep 29, 2012
    Posts:
    240
    @rob60
    No, you have to generate "dungeons" each making a small room inside, then prefab, then put in your entire dungeon generator.
     
    AliAkbar likes this.
  21. Power-Level-Studios

    Power-Level-Studios

    Joined:
    Jul 30, 2014
    Posts:
    3
    Looking good. Will check it out for our game.
     
    AliAkbar likes this.
  22. guinea6

    guinea6

    Joined:
    Feb 6, 2017
    Posts:
    7
    hey, i have question on this awesome plugin.
    when i want to make a level from scratch, the painter only create corridor type and the the room not automatically create door when connected with corridor i paint.
    then i tried to use platform volume to create room, the things is, the corridors it connect cant be understand. what pattern it makes? i cant seems to get decent connect from couples platform volume room.
    or any video that actually showing how to create from scratch. with out any single procedural?

    thanks
     
  23. castor76

    castor76

    Joined:
    Dec 5, 2011
    Posts:
    2,517
    I came back well after a month or two for this asset and there seems to be no actual update yet. :( I am sure author is working on it, but I wonder when the next version will come?
     
    AliAkbar likes this.
  24. castor76

    castor76

    Joined:
    Dec 5, 2011
    Posts:
    2,517
    I talked about this exactly months ago....
     
    AliAkbar likes this.
  25. AliAkbar

    AliAkbar

    Joined:
    Jun 30, 2014
    Posts:
    729
    @Puggy Thanks for the heads up. I'll have a look at the tile editor

    Here's an example of connecting dungeons together (possible with your level art assets (e.g. mountain entrance, forest, etc)
     
  26. AliAkbar

    AliAkbar

    Joined:
    Jun 30, 2014
    Posts:
    729
    @spryx I'm working on a rewrite of the spatial constraints based on the feedback I received to make it more data driven. Instead of having three fixed states like occupied, empty ignore, you'd instead search with marker names which you provide in a text box and an optional radius. I'll have more info in this soon
     
    spryx and hopeful like this.
  27. spryx

    spryx

    Joined:
    Jul 23, 2013
    Posts:
    557
    Looking forward to this.
     
    AliAkbar likes this.
  28. Yorlik

    Yorlik

    Joined:
    Sep 6, 2014
    Posts:
    3
    First:
    Thanks a lot for writing this wonderful asset.
    I bought it and love it, because it saved me from writing my own system
    and its much better than everything I had in mind to do for myself.

    I have one little issue though:
    I am modding for a game, where the dungeon assets do not really fit into the grid builder scheme
    or any other of the builders, so I will probably have to write my own builder. I decomposed some assets in blender to make them work with the DA grid builder, but thats not really optimal.

    The system of dungeon assets we have consists of several ready made rooms with a fixed grid size and connecting corridor tiles with the same length as the grid size, but they are much more narrow (actually 1/3 grid size).
    The rooms have stairs that could lead to other rooms at a higher levels and some rooms have the stairs which lead to a higher level including that balcony like elevation inside themselves and another room could be connected to that balcony. Also the walls are one sided only and have a dark black outside to keep the illusion of being underground, the terrain mesh also is pitch black, so you only see from an inside perspective.
    Everything outside the dungeon is pitch black.
    The basic room tiles already have walls attached in all combinations of 1,2,3, walls and also fixed doors and empty sides for combinations - so it's all very nicely for manual building, but I'd like to use DA to create big and diverse and decorated dungeons automagically.

    I was thinking about using the city builder, because the corridors fit nicely into the street scheme with _s, _x, _t and such, but the don't allow connection to houses, so I ditched that idea.

    Could you give me some pointers how to tackle this most effectively?
    I saw the videos and think I have an idea, already made my own version of an IsInRoom Selector script, but before proceeding I thought I'd drop a question here.
    I was thinking about using tables of which tile could be attached to which other tile or corridor or use a coding system for the tile type.
    However - I might have overlooked a way to do that type of setup with the already existing scripts - so - better asking beforehand... :)

    I hope I expressed it clear enough.
    Cheers
    ~Chris

    P.S:
    I created a quick draft to give you a visual idea of the type of elements I have to use.
    It's not complete but it illustrates the idea.
    Red = Rooms, Green = Walls, Blue = One level up
    http://imgur.com/xloxGuL
     
    Last edited: Jul 24, 2017
    AliAkbar likes this.
  29. djgriff

    djgriff

    Joined:
    May 29, 2014
    Posts:
    279
    Hello is this asset still supported and does it work with Unity 2017.1?

    @AliAkbar How often do you check the forum - is your asset supported in unity2017.1
    Also why do you have no other means of contacting yourself. even the website has no means to contact you?
    Thanks

    Daniel
     
    Last edited: Jul 27, 2017
  30. AliAkbar

    AliAkbar

    Joined:
    Jun 30, 2014
    Posts:
    729
    @Sehee26 I'll have an update soon. I'm experimenting with a new dungeon layout (more info below)
     
    Sehee26 likes this.
  31. AliAkbar

    AliAkbar

    Joined:
    Jun 30, 2014
    Posts:
    729
    @knotidm I'm open to suggestions, how would you like to go about this? Since the snap builder is more artist friendly (you can design the module any way you like without much constraints) I won't be able to add procedural stuff on top of an arbitrary layout
     
  32. AliAkbar

    AliAkbar

    Joined:
    Jun 30, 2014
    Posts:
    729
    @R1PFake do you mean something like this? I can add it to Unity



    Edit: Skip to 0:30
     
    JBacal, rrahim, R1PFake and 1 other person like this.
  33. AliAkbar

    AliAkbar

    Joined:
    Jun 30, 2014
    Posts:
    729
    @Rob604 You can add pre-built rooms using the new Snap builder (it stitches prefabs together). However there is no control flow system like in DunGen

    I'm working on fixing that
     
    Dwight_Everhart likes this.
  34. AliAkbar

    AliAkbar

    Joined:
    Jun 30, 2014
    Posts:
    729
    There's a landscape transformer that overwrites the landscape heights and apply alpha maps (i.e. paint the landscape). You can make it work on an existing landscape also, There's a Gaia sample in the quick start guide. This script leaves the height unchanged but paints the paths. Another script clamps all the dungeon items to the ground





    You can grab the sample from here
     
    rrahim and Dwight_Everhart like this.
  35. AliAkbar

    AliAkbar

    Joined:
    Jun 30, 2014
    Posts:
    729
    @guinea6 This is an issue that I'll address in the next update. I'll also be adding support for painting rooms
     
  36. AliAkbar

    AliAkbar

    Joined:
    Jun 30, 2014
    Posts:
    729
    @Yorlik Thanks for the draft. These assets will not work with the default layout algorithm as the width of the corridor can be greater than 1

    With these assets, you intend to create dungeons that look like this? I'm working on a new dungeon algorithm (more info below) and it should work nicely with it
     
    spryx likes this.
  37. AliAkbar

    AliAkbar

    Joined:
    Jun 30, 2014
    Posts:
    729
    @djgriff It works with 2017.1 We have a discord channel and I'm usually available everyday from 12:30am to 9:30am EST. (I know it's bad timing as it's mostly midnight for you folks but you can leave a message and I or the other 150+ users will help you out)

    https://discord.gg/dRewTSU

    You can mail me: ali.akbar@coderespawn.com

    I'll update the contact info in the product page in the next update
     
  38. AliAkbar

    AliAkbar

    Joined:
    Jun 30, 2014
    Posts:
    729
    I enjoyed playing Ziggurat and I'm creating a new layout algorithm that attempts to create levels like in that game





    I use space partitioning on a NxM world size and keep splitting the level till a min/max room size is reached.

    The BSP tree can be used to enforce rules (like keys, treasure rooms etc). We also use the tree to decide how the adjacent rooms connect

    Here's some very early progress:


    Instead of splitting in the center, it can also splits unevenly



    Next steps:
    • Traverse the tree and apply constraints (locks, keys, boss room, etc) on the tree nodes
    • Discard unused nodes from the tree (i.e. discard unused rooms)
    • Connect the adjacent rooms based on the tree layout
    Future improvements:
    • Give you a graph based UI to design your own constraints
     
  39. R1PFake

    R1PFake

    Joined:
    Aug 7, 2015
    Posts:
    540
    Yes, that looks like the layout that i need, can you please add this to Unity (or is this already possible with the unity asset?)
     
    AliAkbar likes this.
  40. Duffer123

    Duffer123

    Joined:
    May 24, 2015
    Posts:
    1,215
    @AliAkbar ,

    Damn. Going to have to buy it now... ;)
     
    AliAkbar likes this.
  41. djgriff

    djgriff

    Joined:
    May 29, 2014
    Posts:
    279
    @AliAkbar Thanks for the reply, I too am gonna have to get it now ! great to know you are actively supporting this asset. Looks fantastic!

    Many Thanks

    Daniel
     
    AliAkbar likes this.
  42. Yorlik

    Yorlik

    Joined:
    Sep 6, 2014
    Posts:
    3
    That looks pretty good already!

    The constraints for the assets we have basically are:

    1. There are ready made rooms with doors at a given fixed location of format 15*15

    2. There are partial room tiles which can be combined with other partial room tiles to create bigger rooms like 15*30 or 30*30

    3. New Rooms can also be created by a combination of partial rooms with Wall elements and Door Elements.

    4. All outside walls have a black cover to keep the impression of being underground which implies these walls can only be used from one side - if there is a directly adjacent room it needs to have its own walls on the backside of the walls of the other room. Everything outside the dungeon is pitch black.

    5. Corridors are 1/3 of a room (5 wide * 15 length) and need to work like a street system with blind ends, T and X junctions. There are also broken corridors which can not be passed but give information about something being there such, that player will search an alternate route.

    6. There are certain connector elements for certain types of connections. An easy way to layout items using a cell and an adjacent cell info would be great to have.

    7. Some rooms create an upper level which can be connected to other tiles adjacent to that upper level.

    8. Doors can be at any of three positions at the wall of a room tile: Left - middle - right, doors take 5 units and the room tiles are 15 wide. There can even be 2 or 3 doors on one side of a room.

    The layout image you posted looks very close to what we have - if youi can make an algorithm and interface for that type of tile layout it would be of immense help.
     
    AliAkbar likes this.
  43. Duffer123

    Duffer123

    Joined:
    May 24, 2015
    Posts:
    1,215
    @AliAkbar ,

    Hi. How can Dungeon Architect help with Doors and Keys?

    Can it assist with where Monster GOs are spawned?
     
    AliAkbar likes this.
  44. AliAkbar

    AliAkbar

    Joined:
    Jun 30, 2014
    Posts:
    729
    Added door connections



    You can also control the amount of looping in the configuration
     
  45. ValBis

    ValBis

    Joined:
    Jul 9, 2017
    Posts:
    50
    Hello, Ali! I love your script, I just got it couple of days ago and I am still exploring it. I have a question:
    I have some models imported from another package. When I place these models in the scene manually they are correctly scaled and oriented. However, when I place these models in the theme editor they are often rotated and sometimes badly scaled, which means that I have to manually adjust the scale and rotation by eyeballing the right size, direction etc.

    How come? Am I doing something wrong with this? Thanks! Keep up the good work!
     
    AliAkbar likes this.
  46. ValBis

    ValBis

    Joined:
    Jul 9, 2017
    Posts:
    50
    Also, another feature that would be immensely useful and doesn't seem too difficult to add, is the possibility to copy the transform of the offset for each theme component. A lot of models are scaled similarly and it would be nice just to copy and paste the transform from one to another.

    EDIT: also, I would like to add a model of a "corridor arch", something like this: ideahttp://absfreepic.com/absolutely_free_photos/thumb_photos/arch-corridor-5184x3456_58634.jpg
    If I add this as a marker emitter for the wall, then 2 of those will be added, one for each side of the corridor. I would like to add only ONE for each cell of the corridor. Maybe I could take the ground corridor, the problem is that I don't have any way to differentiate between a GroundCorridor and a GroundRoom! Any idea about how to implement this?
     
    Last edited: Jul 30, 2017
    AliAkbar likes this.
  47. AliAkbar

    AliAkbar

    Joined:
    Jun 30, 2014
    Posts:
    729
    @ValBis I couldn't get this to show up locally. Would it be possible to send a copy of the prefab that is causing this?
     
  48. ValBis

    ValBis

    Joined:
    Jul 9, 2017
    Posts:
    50
    Here it is! Let me know :)
     

    Attached Files:

  49. AliAkbar

    AliAkbar

    Joined:
    Jun 30, 2014
    Posts:
    729
    @ValBis It should be possible with a selector script to identify if the ground is a corridor or a room.
    • Add two nodes to the ground marker.
    • Attach this selector to the first node: DungeonArchitect_Samples/Support/Scripts/Rules/RoomSelectionRule
    • This will cause the first node to be selected if inside a room, or the second node otherwise (corridor)

    Those arches can be placed with spatial constraints as a ground node. This will select your arch node only if you have a single lane corridor

    Empty | Occupied | Empty
    Empty | | Empty
    Empty | Occupied | Empty


     
  50. AliAkbar

    AliAkbar

    Joined:
    Jun 30, 2014
    Posts:
    729
    Progress on the BSP builder


    Looping is supported and the tree's edges enforce the flow condition. (e.g. notice the doors, L, K, E)
     
    antoripa and Dwight_Everhart like this.