Fixed enum to wrong string cause by misuse GetNameStringByValue and GetNameStringByIndex
This commit is contained in:
parent
6ed174b72d
commit
409ceece3d
|
@ -33,7 +33,7 @@ static FString PropSizeTypeToString(EPropSize PropSizeType)
|
|||
{
|
||||
return FString("unknown");
|
||||
}
|
||||
return ptr->GetNameStringByIndex(static_cast<int32>(PropSizeType));
|
||||
return ptr->GetNameStringByValue(static_cast<int32>(PropSizeType));
|
||||
}
|
||||
|
||||
static EPropSize StringToPropSizeType(FString PropSize)
|
||||
|
|
|
@ -26,5 +26,5 @@ FString CityMapMeshTag::ToString(ECityMapMeshTag Tag)
|
|||
const UEnum* ptr = FindObject<UEnum>(ANY_PACKAGE, TEXT("ECityMapMeshTag"), true);
|
||||
if(!ptr)
|
||||
return FString("Invalid");
|
||||
return ptr->GetNameStringByIndex(static_cast<int32>(Tag));
|
||||
return ptr->GetNameStringByValue(static_cast<int32>(Tag));
|
||||
}
|
||||
|
|
|
@ -57,7 +57,7 @@ FString QualityLevelToString(EQualityLevel QualitySettingsLevel)
|
|||
{
|
||||
return FString("Invalid");
|
||||
}
|
||||
return ptr->GetNameStringByIndex(static_cast<int32>(QualitySettingsLevel));
|
||||
return ptr->GetNameStringByValue(static_cast<int32>(QualitySettingsLevel));
|
||||
}
|
||||
|
||||
static void LoadSettingsFromConfig(
|
||||
|
|
Loading…
Reference in New Issue