hThe use case of the licensee is that he used FindInBlueprints inside the Editor to find a particular text contained in BPs and later used that listing to recompile the BPs using the CompileAllBlueprintsCommandlet -AllowList.
He noticed that not all BPs found by FindInBlueprints were showing in the commandlet. He pointed out that the UWorld/umap files were not being considered by the commandlet because the assets are cast to UBlueprint, what does not work on Levels because they contain BP, but are not BPs.
The proposed fix is:
There are two blocks of changes in CompileAllBlueprintsCommandlet.cpp. The first is in BuildBlueprintAssetList(). Line 185,
AssetRegistryModule.Get().GetAssetsByClass(BlueprintBaseClassName, BlueprintAssetList, true);
is replaced by
FARFilter Filter;
Filter.ClassPaths.Add(BlueprintBaseClassName);
Filter.ClassPaths.Add(UWorld::StaticClass()->GetClassPathName());
Filter.bRecursiveClasses = true;
AssetRegistryModule.Get().GetAssets(Filter, BlueprintAssetList);
This adds worlds to the BlueprintAssetList. BlueprintBaseClassName can be overridden using a command line parameter. I suppose some kind of override functionality would be desired in the production version.
The second change is in BuildBlueprints(). Line 152,
UBlueprint* LoadedBlueprint = Cast<UBlueprint>(StaticLoadObject(Asset.GetClass(), /Outer=/nullptr, *AssetPath,nullptr, LOAD_NoWarn | LOAD_DisableCompileOnLoad));
is replaced by
UObject* LoadedObject = StaticLoadObject(Asset.GetClass(), /Outer =/nullptr, *AssetPath,nullptr, LOAD_NoWarn | LOAD_DisableCompileOnLoad);
UBlueprint* LoadedBlueprint = Cast<UBlueprint>(LoadedObject);
if (LoadedBlueprint == nullptr)
{
UWorld* LoadedWorld = Cast<UWorld>(LoadedObject);
if ((LoadedWorld != nullptr) && (LoadedWorld->PersistentLevel != nullptr))
}
This looks for a level blueprint if the asset is a world.
The original use case of the licensee is that he used FindInBlueprints inside the Editor to find a particular text contained in BPs
On an empty project, create a new level, give it a name and save
Create some BPs just to verify that they show in the CompliteAllBlueprints log
Save everything
Use the commandlet CompileAllBlueprints in the command line: <ProjectFolder>...\UE_5.3\Engine\Binaries\Win64\UnrealEditor-Cmd.exe <ProjectFolder>\<ProjectName>.uproject -run=CompileAllBlueprints
Check the logs, all BPs are listed, but not the Level
Expected Behavior: since UWorlds contain BP logic, they should also be captured and compiled by CompileAllBlueprints
Actual Behavior: Levels are ignored and will not be recompiled
> UnrealEditor-UnrealEd.dll!UCompileAllBlueprintsCommandlet::Main(const FString & Params) Line 33 C++
UnrealEditor-Cmd.exe!FEngineLoop::PreInitPostStartupScreen(const wchar_t * CmdLine) Line 4195 C++
[Inline Frame] UnrealEditor-Cmd.exe!FEngineLoop::PreInit(const wchar_t *) Line 4483 C++
[Inline Frame] UnrealEditor-Cmd.exe!EnginePreInit(const wchar_t *) Line 41 C++
UnrealEditor-Cmd.exe!GuardedMain(const wchar_t * CmdLine) Line 136 C++
UnrealEditor-Cmd.exe!GuardedMainWrapper(const wchar_t * CmdLine) Line 118 C++
UnrealEditor-Cmd.exe!LaunchWindowsStartup(HINSTANCE__ * hInInstance, HINSTANCE__ * hPrevInstance, char * __formal, int nCmdShow, const wchar_t * CmdLine) Line 258 C++
UnrealEditor-Cmd.exe!WinMain(HINSTANCE__ * hInInstance, HINSTANCE__ * hPrevInstance, char * pCmdLine, int nCmdShow) Line 298 C++
[External Code]
i have this problem UE4CC-Windows-58DC12AF4B97F057BD108FBFF569B2E9_0000
I am not able to find world outliner how to enable it?
Undefined sysmbol: typeinfo for AActor when cross-compile linux dedicated server on windows
Delay nodes occasionally don't fire the "Completed" output in a nativized build
What method is used to fill polygonal regions when drawing spline mesh at run time?
When I open UE4 4.24.3 it appears that. Does anyone know how to solve?
How does TextureRenderTarget2D get TArray<uint8> type data?
There's no existing public thread on this issue, so head over to Questions & Answers just mention UE-234741 in the post.
0 |
Component | UE - Gameplay - Blueprint |
---|---|
Affects Versions | 5.3 |
Target Fix | 5.6 |
Created | Dec 16, 2024 |
---|---|
Updated | Dec 20, 2024 |