Reference to curve

I would like to add a reference to a float curve (which should be FRichCurve) in order to be able to create it externally in a separate object, and then assign it in my blueprint properties.
I’ve tried to use FRichCurve*, TSharedPtr, TSubobjPtr, but w/o any success, as it doesn’t compile. And using FRichCurve alone is valid for compilation, but I have nothing in my BP attribute…
Any idea how to do that?

Hi Man, You Fix This error… Post your code to create FRichCurve Object Please??

Hi,

Yes, I found the answer, you just need to use a UCurveFloat reference:

UPROPERTY(EditDefaultsOnly, BlueprintReadOnly, Category = Curve)
UCurveFloat* MyCurve;

and then use it as follows:

float CurveValueY = MyCurve->GetFloatValue(CurveParamX);
1 Like

do you know if there like me create a FRichCurve and assign in a UCurveFloat to use the timeline?