Can you scale an AnimationCurve?

I have a VFX asset with a Set Size Over Life block. I want to be able to adjust the size of the particles with a float parameter, but still have them follow an AnimationCurve.

Is there any way to scale an AnimationCurve, so that the values it outputs are multiplied by a float? I see that I can sample the curve at a specific time, so I suppose I could just use a Set Size node and use the particle’s lifetime to sample the curve, but it’d be a lot tidier to just rescale the curve itself.

Hello Chemicalcrux,

You can add a new Multiply size node after the Set size over life, it will provide you a float to multiply your previous animation curve values!

Note that you can change the composition of a node in its inspector, overwrite, multiply, add and blend modes are available there when relevant.

The order of your nodes will impact the final value, calculated from the top to the bottom (ex: if there 2 nodes “set lifetime”, the second one will overwrite the value. If there is a “set lifetime” and then a “multiply lifetime”, the first value will be multiplied by the second. If there is a “multiply lifetime” followed by a “set lifetime”, the multiply will have no effects.)

I hope this helps, have a great day.

2 Likes

Ah, thanks! That’ll do the trick for me.