Dungeon Architect

@ Looks like a typo in your folder name? DungeonARchitext

As there are no binaries for the Mac platform, I had to compile the sources on my own.
It fails. OSX 10.10.5, Unreal 4.9.2
In SceneProviderCommand.h we have a forward declaration of ADungeon, but the template AddActor fails with this line:
MoveToFolder(Actor, Dungeon->ItemFolderPath);
(member access into incomplete type ADungeon)

@rotwang I upload a new build tomorrow

Iā€™ve attached the infinity blade theme file if you want to try it out right now. Iā€™ll later add it to the quick start samples

Steps:

  • Add Infinity Blade Ice Lands asset into your project
  • Add UE4 starter content to your project
  • Extract and copy over the *.uasset theme file somewhere in your contents folder
  • Drop in a dungeon actor in your scene and assign this theme to it
  • IMPORTANT: Set the config as mentioned in the pic ā€œUSE_THIS_CONFIG.pngā€
  • Click build

Edit: In the config, only GridSize should be (500,500,250) and MaxAllowedStairSize = 1. You can play with the other params

Hey,

I just spent 2 hours trying to do the random transform checking for collisions and repositioning etc, and failed miserably. This is one of those that I will spend days trying to on my own.
Is there any way you can help me please? Iā€™m sure itā€™s childsplay to you but to me is proving too much. Most of my attempts end up with an editor crash with some horrible infinite loop scenarioā€¦

Can anyone takeā€™s example from the video and modify the blueprint to check for collisions with the dungeon walls, other meshes etc and take a screengrab of it please?
I just wanna move on to the exciting stuff and this is making my already limited time feel so wasted!

Thanks!
Daz

Ah, sorry should have told you this earlier. Now that I think of it, the theming engine runs in a separate thread and is not allowed to spawn actors from a non-game thread. So I queue all the spawning commands and finally run them all in the game thread.
So, you cannot check for physics collisions since the previous dungeon objects would not have been spawned by the time you check for collisions

Order of execution:

  • Generate Layout
  • Create mesh & actor spawn commands (with position / rotation), but donā€™t spawn them
  • After the generation thread ends, go back to the main game thread and run all the commands (to actually spawn the meshes) over multiple frames to avoid lag

As a workaround, would it be too costly to make these objects Movable with physics enabled? If not, you could just spawn them (even if they collide) and when the game starts, the physics engine would would recover the colliding objects over the next few frames
Colliding cubes

Runtime (penetration recovery by the physics engine)

could you expose ā€œemptyā€ marker to themes?

Your way fills entire area, and it does not solve my problem:
For eg when you create corridor you will have 2-3 tiles of floor (ground) then 2 walls, then empty space (or when doing your way you get at best ground level plane).
So when you fill it your way you get flat floor outside dungeon, and what i need is filling up to top of walls level.

So only one way is to expose (and create) markers for empty spaces inside dungeon and around it (in square that is 2-3 cells bigger than dimension of dungeon).

I tried to add second floor to dungeon (with filling up mesh as ground), but it generated stairs, and i could not change theme for second floor. This also forces to have flat dungeon without height variation.

Then there is problem of corners, if i put decoration on walls and corner is 90deg, both walls may have overlapping decorations.
Same problem goes for decorations on floors, it is hard to add any deco bigger than 1 cell, because they will overlap somewhere.

i guess iā€™ll wait for next build upload or revert to 1.1.0, but with 1.1.1 - getting error message - Plugin ā€˜DungeonArchitectā€™ failed to load because module ā€˜DungeonArchitectRuntimeā€™ could not be found. Please ensure the plugin is properly installed, otherwise consider disabling the plugin for this project.

That is what I had. I found that the problem was the project needs to be converted to C++ prior to adding the Plugins folder. So when you make a new project open up the File window and add C++ Class just name it whatever and save it. Then close the project, add the Plugins, and now it will work.

This will probably be cleaned up in a later build, but right now Iā€™m having trouble packaging any projects with dungeon architect in them; the build always fails with the following chain of errors:

MainFrameActions: Packaging (Windows (64-bit)): UnrealBuildTool: Unreal Projects\ProjectName\Plugins\4.9\DungeonArchitect\Source\DungeonArchitectRuntime\Classes\Dungeon\SceneProviders\SceneProviderCommand.cpp(19) : error C2039: ā€˜SetFolderPathā€™ : is not a member of ā€˜AActorā€™
MainFrameActions: Packaging (Windows (64-bit)): UnrealBuildTool: C:\Program Files (x86)\Epic Games\4.9\Engine\Source\Runtime\Engine\Classes\GameFramework/Actor.h(58) : see declaration of ā€˜AActorā€™
MainFrameActions: Packaging (Windows (64-bit)): UnrealBuildTool: Unreal Projects\ProjectName\Plugins\4.9\DungeonArchitect\Source\DungeonArchitectRuntime\Classes\Dungeon\Builders\DungeonBuilderOrganic.cpp(156) : error C2039: ā€˜GetLandscapeInfoā€™ : is not a member of ā€˜ALandscapeā€™
MainFrameActions: Packaging (Windows (64-bit)): UnrealBuildTool: C:\Program Files (x86)\Epic Games\4.9\Engine\Source\Runtime\Coreā€¦/Landscape/Classes/Landscape.h(30) : see declaration of ā€˜ALandscapeā€™
MainFrameActions: Packaging (Windows (64-bit)): UnrealBuildTool: Unreal Projects\ProjectName\Plugins\4.9\DungeonArchitect\Source\DungeonArchitectRuntime\Classes\Dungeon\Builders\DungeonBuilderOrganic.cpp(163) : error C2039: ā€˜GetLandscapeExtentā€™ : is not a member of ā€˜ULandscapeInfoā€™
MainFrameActions: Packaging (Windows (64-bit)): UnrealBuildTool: c:\program files (x86)\epic games\4.9\engine\source\runtime\landscape\classes\LandscapeInfo.h(87) : see declaration of ā€˜ULandscapeInfoā€™
MainFrameActions: Packaging (Windows (64-bit)): UnrealBuildTool: Unreal Projects\ProjectName\Plugins\4.9\DungeonArchitect\Source\DungeonArchitectRuntime\Classes\Dungeon\Builders\DungeonBuilderOrganic.cpp(170) : error C2065: ā€˜FLandscapeEditDataInterfaceā€™ : undeclared identifier
MainFrameActions: Packaging (Windows (64-bit)): UnrealBuildTool: Unreal Projects\ProjectName\Plugins\4.9\DungeonArchitect\Source\DungeonArchitectRuntime\Classes\Dungeon\Builders\DungeonBuilderOrganic.cpp(170) : error C2146: syntax error : missing ā€˜;ā€™ before identifier ā€˜LandscapeEditā€™
MainFrameActions: Packaging (Windows (64-bit)): UnrealBuildTool: Unreal Projects\ProjectName\Plugins\4.9\DungeonArchitect\Source\DungeonArchitectRuntime\Classes\Dungeon\Builders\DungeonBuilderOrganic.cpp(170) : error C3861: ā€˜LandscapeEditā€™: identifier not found
MainFrameActions: Packaging (Windows (64-bit)): UnrealBuildTool: Unreal Projects\ProjectName\Plugins\4.9\DungeonArchitect\Source\DungeonArchitectRuntime\Classes\Dungeon\Builders\DungeonBuilderOrganic.cpp(173) : error C2065: ā€˜LandscapeEditā€™ : undeclared identifier
MainFrameActions: Packaging (Windows (64-bit)): UnrealBuildTool: Unreal Projects\ProjectName\Plugins\4.9\DungeonArchitect\Source\DungeonArchitectRuntime\Classes\Dungeon\Builders\DungeonBuilderOrganic.cpp(173) : error C2228: left of ā€˜.GetHeightDataFastā€™ must have class/struct/union
MainFrameActions: Packaging (Windows (64-bit)): UnrealBuildTool: type is ā€˜unknown-typeā€™
MainFrameActions: Packaging (Windows (64-bit)): UnrealBuildTool: Unreal Projects\ProjectName\Plugins\4.9\DungeonArchitect\Source\DungeonArchitectRuntime\Classes\Dungeon\Builders\DungeonBuilderOrganic.cpp(180) : error C2039: ā€˜GetLandscapeInfoā€™ : is not a member of ā€˜ALandscapeā€™
MainFrameActions: Packaging (Windows (64-bit)): UnrealBuildTool: C:\Program Files (x86)\Epic Games\4.9\Engine\Source\Runtime\Coreā€¦/Landscape/Classes/Landscape.h(30) : see declaration of ā€˜ALandscapeā€™
MainFrameActions: Packaging (Windows (64-bit)): UnrealBuildTool: Unreal Projects\ProjectName\Plugins\4.9\DungeonArchitect\Source\DungeonArchitectRuntime\Classes\Dungeon\Builders\DungeonBuilderOrganic.cpp(181) : error C2065: ā€˜FLandscapeEditDataInterfaceā€™ : undeclared identifier
MainFrameActions: Packaging (Windows (64-bit)): UnrealBuildTool: Unreal Projects\ProjectName\Plugins\4.9\DungeonArchitect\Source\DungeonArchitectRuntime\Classes\Dungeon\Builders\DungeonBuilderOrganic.cpp(181) : error C2146: syntax error : missing ā€˜;ā€™ before identifier ā€˜LandscapeEditā€™
MainFrameActions: Packaging (Windows (64-bit)): UnrealBuildTool: Unreal Projects\ProjectName\Plugins\4.9\DungeonArchitect\Source\DungeonArchitectRuntime\Classes\Dungeon\Builders\DungeonBuilderOrganic.cpp(181) : error C3861: ā€˜LandscapeEditā€™: identifier not found
MainFrameActions: Packaging (Windows (64-bit)): UnrealBuildTool: Unreal Projects\ProjectName\Plugins\4.9\DungeonArchitect\Source\DungeonArchitectRuntime\Classes\Dungeon\Builders\DungeonBuilderOrganic.cpp(182) : error C2065: ā€˜LandscapeEditā€™ : undeclared identifier
MainFrameActions: Packaging (Windows (64-bit)): UnrealBuildTool: Unreal Projects\ProjectName\Plugins\4.9\DungeonArchitect\Source\DungeonArchitectRuntime\Classes\Dungeon\Builders\DungeonBuilderOrganic.cpp(182) : error C2228: left of ā€˜.SetHeightDataā€™ must have class/struct/union
MainFrameActions: Packaging (Windows (64-bit)): UnrealBuildTool: type is ā€˜unknown-typeā€™
MainFrameActions: Packaging (Windows (64-bit)): UnrealBuildTool: Unreal Projects\ProjectName\Plugins\4.9\DungeonArchitect\Source\DungeonArchitectRuntime\Classes\Dungeon\Builders\DungeonBuilderOrganic.cpp(183) : error C2065: ā€˜LandscapeEditā€™ : undeclared identifier
MainFrameActions: Packaging (Windows (64-bit)): UnrealBuildTool: Unreal Projects\ProjectName\Plugins\4.9\DungeonArchitect\Source\DungeonArchitectRuntime\Classes\Dungeon\Builders\DungeonBuilderOrganic.cpp(183) : error C2228: left of ā€˜.Flushā€™ must have class/struct/union
MainFrameActions: Packaging (Windows (64-bit)): UnrealBuildTool: type is ā€˜unknown-typeā€™
MainFrameActions: Packaging (Windows (64-bit)): UnrealBuildTool: Unreal Projects\ProjectName\Plugins\4.9\DungeonArchitect\Source\DungeonArchitectRuntime\Classes\Dungeon\Builders\DungeonBuilderOrganic.cpp(186) : error C2065: ā€˜LandscapeEditā€™ : undeclared identifier
MainFrameActions: Packaging (Windows (64-bit)): UnrealBuildTool: Unreal Projects\ProjectName\Plugins\4.9\DungeonArchitect\Source\DungeonArchitectRuntime\Classes\Dungeon\Builders\DungeonBuilderOrganic.cpp(186) : error C2228: left of ā€˜.GetComponentsInRegionā€™ must have class/struct/union
MainFrameActions: Packaging (Windows (64-bit)): UnrealBuildTool: type is ā€˜unknown-typeā€™
MainFrameActions: Packaging (Windows (64-bit)): UnrealBuildTool: -------- End Detailed Actions Stats -----------------------------------------------------------
MainFrameActions: Packaging (Windows (64-bit)): UnrealBuildTool: ERROR: UBT ERROR: Failed to produce item: Unreal Projects\ProjectName\Plugins\4.9\DungeonArchitect\Binaries\Win64\UE4-DungeonArchitectRuntime.lib
MainFrameActions: Packaging (Windows (64-bit)): UnrealBuildTool: Total build time: 110.98 seconds
MainFrameActions: Packaging (Windows (64-bit)): CommandUtils.Run: Run: Took 111.0084658s to run UnrealBuildTool.exe, ExitCode=5
MainFrameActions: Packaging (Windows (64-bit)): BuildCommand.Execute: ERROR: BUILD FAILED

I downloaded this to check it out since the way you built this is far more complex than your other examples. I instantly started having a problem with all of the empty space.

@anonymous_user_f2166112 guys last build was not released properly. Iā€™m working on fixing and will test it thoroughly before the next release. Got it working in Mac and fixed the release build issue reported by @HInoue. The editor specific features need to be within the #WITH_EDITOR macro in C++

@ Ah, I use a plane from the starter content pack for the ground mesh (the one that comes with UE4). Please add the starter content, then add the dungeon asset again to your project

Edit: Updated original post with this extra step

1> Yeah I used this method, but it does result in some of the dynamic crates dropping out of the world (when their proxy is further out of the wall than in for example).
I feel like their needs to be a way of fine-tuning random placed objects a little, within extents built into your (amazing) plugin.
So Iā€™m using RoomOpenSpace and your Random transform function to populate these areas but this can result in crates sticking through walls because the Ground tiles near the walls are still included in the calculation. Could there be a way of defining a radius from this RoomOpenSpace marker or having the option of a hard rule we can flag on that tells it not to spawn anything in Ground Cells that are adjacent or overlapping walls pieces?

2> My second thing is how to connect one dungeon to another? So if I have one dungeon on top of another, how do I connect these up?
Or at the least, Is it possible to define a cell type that is EXIT and possibly ENTRANCE or something and have rules governing these cells (such as spawning distance away from each other etc.).
I basically want to be able to have a start point next to an entrance cell, and then the player will navigate the area as normal, looking for the Exit which we can guarantee if we want (At generation time) that it will be the furthest distance away from the Entrance point as is possible in the currently generated dungeon.

3> I kind of defaulted to using the Design Time editor with the build option, but if I want to do RunTime instead how do I make the player spawn point be in a valid location?

Thx
Daz

@ - thanks! that works!
@ - great work! just when i thought it canā€™t get any better, and you go and do a infinity blade theme!!! must finish 1 game at a timeā€¦ resisting making one based off of infinity assets at the moment.

New update available:

Version 1.1.2

  • Fixed issues with game code not building due to editor specific code. Added WITH_EDITOR macro
  • Fixed breaking changes with XCode clang compiler to make it work in mac
  • Includes Win64 and Mac binaries

@

's something I canā€™t explain.

Iā€™ve been working with the DungeonDesignTime (DDT) mode and been creating my theme and as you can see the result so far works okay - though lots of work still needed:


But despite it looking okay in the main editor window, the Preview window in the theme is all messed up. I kinda ignored this because it looked fine in-game:

However, when I switched to DungeonRuntime and made the settings of Dungeon1 exactly the same as DDT mode and pressed play I got this:


and this in the preview window (this time an accurate representation of what I see in the game window (Except this has stairs too - which I explicitly turn off - check the settings!)

What am I doing wrong? Or is it a bug? Quite a few strange issues there

Cheers,
Daz

Daz, the preview windowā€™s dungeon config still has the default values (grid size 400,400,200). You can sync that to you main window by clicking the Properties button in the preview window in the theme editor and select Dungeon. Then expand the config section in the details window and set the values correctly there. The theme file will remember these settings when you open it the next time.

Let me know if it works out

The plugins requires more documentation and proper video tutorials. Iā€™ll be giving it priority.

In the Realtime demo, Iā€™m resetting the dungeon config in the level blueprint (to give it a random seed to get a new level every time). So you need to set your dungeon config in the Level blueprint because the demo overrides it

@HInoue Fixed the bug you mentioned in #290](Dungeon Architect - Work in Progress - Unreal Engine Forums)

Due to the newer optimizations in the instanced mesh scene provider, a hash is generated and saved for each node in the theme file. So the older theme files had to be re-saved. The theming engine now regenerates the hash if it is not available so it works with older theme files

Edit: Fix will be available in 1.1.3. In the mean time, just re-save your old theme file if you face this issue

thanks, that solved all the problems. Although i had to change some of my blueprinted static meshes to moveable on the RunTime demo for it to stop spamming the game log with errors and causing stuttering. Once I changed this it was exactly the same as the DDT one.

Got two more questions!

1> How do we know where to place and what dimensions to choose for adding a NavMesh?
2> Did you read my earlier questions regarding an ENTRANCE and EXIT type object, and the sprading of props around some kind of radius from the centre rather than everywhere, even near walls (to stop my crates and other objects from clipping through geometry?

Cheers.
LOVE this, youā€™re an amazing developer :slight_smile:

Daz

, thank you! I can verify that every bug Iā€™ve mentioned in this thread is now fixed, and really quickly too- I seriously appreciate all of the work youā€™re putting into this product :slight_smile: