At which frame particle is generated?

   904   4   2
User Avatar
Member
24 posts
Joined: Aug. 2023
Offline
When a particle is generated,

how do I know at which frame it was generated? How can I save the frame number as a particlae attribute?



I read online that it says to use @age==0 to determine this,

But I found that once the particle is generated, @age is greater than 0, there is no such thing as @age equal to 0.

So I can't tell if the particle is generated in this frame or not.



As an example:

I want the particles generated after 20 frames to turn red, not @age at a certain value,

how can I achieve it?

Attachments:
Birth Frame_Snipaste_2024-10-16_17-01-27.png (1.0 MB)

User Avatar
Member
1827 posts
Joined: March 2009
Offline
You multiply age by the FPS rate and that's your age in frames. Something like this:

floor(@age * (1 / @TimeInc));
Edited by protozoan - Oct. 16, 2024 09:29:33
Martin Winkler
User Avatar
Member
541 posts
Joined: Nov. 2016
Offline
In your pop source you can create a "Just Born" group. Do that, and create a pop wrangle node affecting only this group, with:
i@emitFrame = @Frame;
User Avatar
Member
24 posts
Joined: Aug. 2023
Offline
protozoan
floor(@age * (1 / @TimeInc));


Thanks for your response,

you've provided a new method of calculation!
User Avatar
Member
24 posts
Joined: Aug. 2023
Offline
Tanto
In your pop source you can create a "Just Born" group. Do that, and create a pop wrangle node affecting only this group, with:
i@emitFrame = @Frame;


yes~

That's exactly the answer I was looking for!

Thank you very much!
  • Quick Links