2
$\begingroup$

I have a particle system moving around creating abstract shapes in Blender. I need the material to slowly change over time. For example:

  • frame 30, all particles are red
  • frame 31, 95% of particles are red, 5% are green
  • frame 32, 90% of particles are red, 10% are green
  • and so on until frame 40 where 100% are green

Alternatively if the new colour could start from the emitter and move out (instead of changing on a random particle) that would also be helpful. Currently I have the particles able to change colour but all the particles change at once.

I tried using a collection with different colours and animating the 'use count' feature when instancing a collection but that doesnt seem to work either.

Any help with this would be greatly appreciated I have tried everything and can't seem to get it to work.

$\endgroup$
2
  • $\begingroup$ So what you mean with "alternatively" is, at frame 31 it should be 5% of the particles being born on that frame that are green...? Not altogether with the ones being born on frame 30 (or before if you start the emission earlier)? So at frame 40 it should be 100% of the new particles, not all existing particles? I just ask to make sure I understood correctly. $\endgroup$ Nov 20, 2023 at 10:59
  • $\begingroup$ Yes thats correct so at frame 40 all new particles will be green, whatever particles that were emitted before remain red. If you have a solution I'd LOVE to hear it :). $\endgroup$ Nov 20, 2023 at 11:41

2 Answers 2

3
$\begingroup$

Plug an Input > Object Info node into a ColorRamp, move and keyframe the Position value of each color needle so that they go from right to left (or opposite):

enter image description here

Result:

enter image description here

$\endgroup$
3
  • $\begingroup$ I had a different approach but with a similar result... however I cannot find a way for the "alternative" method he is asking for. Or at least not without Geometry Nodes. $\endgroup$ Nov 20, 2023 at 11:49
  • $\begingroup$ oh yes i skipped the "new colour could start from the emitter" $\endgroup$
    – moonboots
    Nov 20, 2023 at 11:52
  • $\begingroup$ This is absolutely amazing though and a huge step in the right direction. Thank you soo much for this i really appreciate the time spent on this! :) (I'm frustrated with myself it was that simple though haha) $\endgroup$ Nov 20, 2023 at 11:56
4
$\begingroup$

Another possible solution for just switching the color of all particles is the following:

Take the Object Info node's Random output just like @moonboots does, use the frame number as driver in the Value input of a Map Range node. The From Min value is the frame number where all particles should be red, i.e. 30, and the From Max is the frame where 100% should be green, i.e. 40.

This range can now be mapped To Min = 0 and To Max = 1, which makes each frame a step of 10% (your example says 5%, but I'm not sure if this is what you want because then only 50% will be green on frame 40).

If you leave Clamp enabled, you make sure the value will always be 0 for frames < 30 and stay 1 for frames > 40.

By the way, if you do not know how to enter the frame number as driver: just enter #frame into the Value field. Alternatively you could insert keyframes, but then you would not need all this remapping of course.

Now you can compare the Random value with an increasing value from 0 to 1 in a Greater Than node, and the higher the number, the more particles will get 0 as result, and this value is the factor for a Mix Color node.

colored particles

The result looks like that (made it a bit slower than 30 to 40, these are 50 frames, particle emission starts at 5, they are red until 10, become 100% green on frame 40 and then stay green).

particle animation

$\endgroup$
1
  • $\begingroup$ Unreal thanks heaps for this I really appreciate it! I'll experiment with yours and moonboots and see how I go. Thanks again! $\endgroup$ Nov 21, 2023 at 8:29

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .