Hey everyone,
I’m still trying to get my assetpicker for my plugin working. I want to see the chosen asset and therefore need to provide it with an ObjectPath. It expects a FString my delegate is of type FString and it’s not working. What is the problem here?
SNew(SObjectPropertyEntryBox)
.OnObjectChanged(this, &FMyClassDetails::ModelChange)
.AllowedClass(UMyModelClass)
.DisplayThumbnail(true)
.ObjectPath( &FMyClassDetails::GetModelPath)
Here is the delegate:
FString FRealCameraDetails::GetModelPath()
{
if (ModelBlueprintAsset.IsValid())
{
return ModelBlueprintAsset.ObjectPath.ToString();
}
return "";
}
error C2440: ‘type cast’: cannot convert from ‘const OtherType’ to ‘ObjectType’ with[OtherType=FString (__cdecl FMyClassDetails::* )(void)] and [ ObjectType=FString ]
Any help is much appreciated!