Controlling individual particles

Hello.

Is there a way to control individual particles?

I want to make particles act like a chain that stays within a certain distance to its parent while under turbulence or gravity.

Hello.
Your question is pretty tricky. I guess that the correct way would be to create some kind of “Constraints” between the different particles of a “Strip”. Sadly this approach would need that our particles to access other particle’s attributes.
It’s a Feature that is on the public Roadmap but not yet implemented.

But we still can try to “Fake it”…

I can see one “Position based” Approach:

01- We spawn a determined number of Particles each System Loop.
(In this example, we spawn 25 pts every 1 second.)

02- Each Particle is spawn the same frame and are assign a “Lifetime” attribute corresponding to the Loop Duration. This way every 1s , 25 new particles replace the dying ones.

03- We initialized a Particle Strip and set it’s capacity to 1 and the Particle per Strip should correspond to the Spawn Count. Each second , we now have a strip of 25 particles.

04-We calculate a 0-1 value across the Strip ("ParticleindexinStrip / (Spawncount-1)) and store it in an attribute.

05-This attribute is use in the InitContext to Set the PArticles Position along a line.

06- From here our custom attribute we’ll help us to drive the Strength of a CurlNoise. This will allow us to give some Noisy movement to the particles and leave the “Roots” particles unaffected by the Noise.

07- Time is Added to the sampled Noise Position to “Offset” the Noise and add some Motion.

It’s not perfect, as the Noise can sometime push the particles too far . By doing so it “stretches” our Fake Cloth/rope
but it relatively art directable and can give some results.

8437169--1117712--Unity_cj09KR0o92.gif

A second approach that I’m thinking of would be to try to Create “Forces” based on the Distance of the Particles from their Parent Roots.

init Context

  1. First We initialize our Particles in the Desired Rest Position ( on a line for example).
  2. We Calculate and store the Distance from our InitPositions to our ParentRoot for each particles.
  3. We Store the the Delta between our RootPos and the InitPos.

Update Context

  1. We pin the Particle Index ==0 thanks to Boolean Port
  2. We add Gravity and other needed Forces (turbulence etc…)
  3. We calculate the Distance from the RootPos to the Particle Pos.
  4. If the Distance is Greater than our Stored initPos, that’s mean that our rope is stretching. If it’s less it’s the opposite.
    05 We calculate the normalize vector from our Position to the “RestPos” and multiply this by some distance factor. This Vectors can be used as a Force to push the Particles towards their “restPos”.

It’s pretty theoretical and I sadly didn’t have the time to push it further but you can see the first and not so great results in the attached Gifs8437202--1117733--Unity_b0wM7KyPgf.gif

Hello,

I don’t have any training on particles, so I wasn’t quite able to recreate your second method.



8444684--1119620--String Attempt.gif
I noticed the particles flickering when they where replaced so instead I would use set alive and a spawn event for toggling the particles. Is there a downside for particles without a lifetime?

What I was trying to achieve was to create grass that can be affected wind, explosions, player movements and can be burned and detached.

13:46 for reference

Does this roadmap include things like controlling individual VFX particles by script? i.e. assigning multiple childs, making particle 52 to 65 move around because of a helicopter flying near a powerline.