This function returns if the given Animation Curve Asset or Animation Curve Struct exists and is a valid Animation Curve.
animcurve_exists(curve_struct_or_id);
Argument | Type | Description |
---|---|---|
curve_struct_or_id | Animation Curve Struct or Animation Curve Asset | The Animation Curve asset or struct that will be checked. |
if (animcurve_exists(spring_curve))
{
apply_spring_animation(sprite_curve);
}
The above code checks if the Animation Curve stored in the custom spring_curve variable exists. If it does, it runs a custom method to use that Animation Curve.