When my project use 4.11.2, I can load the asset from a pak file.
But I can’t do that after upgrade to 4.15. I know there are a lot of change from 4.11.
Mount function:
IPlatformFile& PlatformFile = FPlatformFileManager::Get().GetPlatformFile();
FPlatformFileManager::Get().SetPlatformFile(PakPlatformFile);
if (!PakPlatformFile.Initialize(&PlatformFile, TEXT("")))
{
return false;
}
PakPlatformFile.InitializeNewAsyncIO(); //< For 4.15, I must to call this function. For 4.11.2, it doesn't exist.
if (!PakPlatformFile.Mount(TEXT("D:\UE4\MyProject\Content\Packages\T001.pak"), 0, TEXT("D:\UE4\MyProject\Content\DLC")))
{
return false;
}
return true;
Well - I’m the blind leading the blind here. My code is very similar to yours and failing on MAC / iOS. In my case I can load loose files from my pak file but level streaming fails after I’ve mounted a pak file (levels are in the normal Content directory, non DLC). I tagged you on my thread:
Your above pointer to use InitializeNewAsyncIO got me past a crash in unmount, but how did you find out that was needed - just by looking for where the precache system was being inited?