Hi Wallenstein,
Blueprints don’t actually know what const
means, so if this is only being used in Blueprints, the const
keyword doesn’t help much. What I did find that worked in this case is instead of using const struct FTestStruct& AMyActor::GetTestStruct() const
, use const struct FTestStruct AMyActor::GetTestStruct() const
instead. Leaving the &
out seems to allow this to work as expected.