Dungeon Architect

I have a bug fix/proposal:

In the theme editor the dungeon is actually not fully rebuild, only markers seem to be re-emitted but in case of more complex custom markers this causes an annoying error since the rebuild in the theme editor does NOT equal the dungeon in the “real world” (scene).

So it seems that some old data remains which causes the theme editor preview to be wrong/different then when making a full dungeon rebuild by pressing “Build Dungeon” on the Dungeon actor in the world level.

This is very annoying since you cannot be sure that the new custom Selector you enabled actually worked as intented.

The hacky solution is to close the theme editor and re-open it.

Better solution: add this code to the top of the function SDungeonEditorViewport::PerformMeshRebuild:


  
 DungeonBuilder->GetModel()->Reset();

    if (DungeonBuilder->SupportsTheming())
    {
        DungeonBuilder->BuildDungeon(DungeonModel, ObjectToEdit->PreviewViewportProperties->DungeonConfig, DungeonQuery, GetWorld());
    }


Edit: forgot this also:

And at the very bottom of the function SDungeonEditorViewport::PerformMeshRebuild I also added this so that it better matched the code in the build task:


  
    DungeonBuilder->ProcessMarkerReplacementVolumes();