For mockup, use the experimental "Blutility"
https://forums.unrealengine.com/showthread.php?1954-Tutorial-Blutility-Running-Blueprint-functions-inside-Editor
Blutility is also said to possess a pointer to UEditorEngine so we can place actors and in the editor in a procedural way.
https://answers.unrealengine.com/questions/22052/how-can-i-place-actors-in-a-level-using-code-or-bp.html
The hard (and more powerful) way of extending the editor:
https://answers.unrealengine.com/questions/25609/customizing-the-editors-toolbar-buttons-menu-via-c.html?sort=oldest
update 1 ----------
Easier method to access GEditor is to #include "UnrealEd.h"
Also add "UnrealEd" in [yourproject].Build.cs as a PrivateDependencyModule
i.e., PrivateDependencyModuleNames.AddRange(new string[] {"UnrealEd"});
update 2 ----------
Landscape actor (ALandscape) can be spawned in the editor as in LandscapeEditorDetailCustomization_NewLandscape.cpp without the need to reference GEditor at all.
No comments:
Post a Comment