Does this still work with PS4 in 4.3 version?
I have a few files that are just loaded on the fly, and no matter what I try it doesn’t include them in the package for the PS4. It mentions the files when I run the command under the “LogCookCommandlet:Display: Loading” section, and finds them if I add print outs in CookCommandlet.cpp when it is iterating through CmdLineDirEntries in CollectFilesToCook where it adds them to FilesInPath, but during the build they never show up under the D:\depot\UE4QA\MyGame\Saved\Cooked\PS4\MyGame\Content\GameUI folder with the other files that are properly being cooked, and don’t show up in the log when it does the “LogCookCommandlet:Display: Cooking” section.
These missing files I am loading up in the game by going:
m_pTexture = LoadObject(NULL, *p_pTexture, NULL, LOAD_None, NULL);
And I am cooking the game by going:
Engine\Build\BatchFiles\RunUAT BuildCookRun -project=MyGame -build -ps4 -cook -map=lvl_1+Main_Menu -stage -package -pak -manifests -cmdline=Main_Menu -clientconfig=Development -CookDir=D:\depot\UE4QA\MyGame\Content\GameUI
Looking at the answers below, it looks like I am doing everything correctly, but when I make a build on the ps4 is crashes because it can’t find these dynamically loaded files since they never get packaged. Is there something I am missing here, or does these commands not work properly for PS4 builds? I managed to fix one issues just by putting one of the UI textures on an off camera box, and figure I could just manually load them with the ConstructorHelpers like the other UI textures that are working, but that doesn’t seem to be the proper way to fix this.