Config Saving/Loading Broken in UE 5.5
Context
Error
Cause
Fix
void UOS_PST_Settings::LoadFromConfig()
{
#if ENGINE_MAJOR_VERSION >= 5 && ENGINE_MINOR_VERSION >= 5
//The config system is broken in 5.5, so we have to manually load the config into memory BEFORE calling LoadConfig() on our object
FString ConfigPath = FPaths::ConvertRelativePathToFull(FPaths::Combine(FPaths::ProjectSavedDir(), TEXT("Config"), FPlatformProperties::PlatformName(), TEXT("OseroSuiteEditorSettings.ini")));
// Attempt to load the config file
GConfig->LoadFile(ConfigPath);
#endif
LoadConfig();
//...
}
void UOS_PST_Settings::SaveToConfig()
{
//...
SaveConfig();
}
Last updated