New ParticleSystem LocalVelocity Like In Old ParticleSystem

Hello!

I started with a ParticleSystem (the old one), where I could change the localVelocity like this:

private ParticleEmitter pe;
pe.localVelocity = direction;

I just changed it to the new ParticleSystem,
when I noticed there is no easy way of changing the localVelocity.

Any suggestions?

One more thing, I tried the following but it seems like the particles have no gravity

        ParticleSystem.Particle[] p = new ParticleSystem.Particle[particleSystem.particleCount + 1];
		int l = particleSystem.GetParticles(p);

		int i = 0;
		while(i < l) {
			p*.velocity = direction;*
  •  	i++;*
    
  •  }*
    
  •  particleSystem.SetParticles(p, l);*
    

They just come out of the ParticleEmitter and shoot right away above the target.
Felix

I just wanted to let you know how to access Properties in the new ParticleSystem:

private ParticleSystem.EmissionModule em;
private ParticleSystem.MinMaxCurve mmc;

void Awake() {
	em = groundPraticles.emission;
}

void Update(){
    mmc.constantMax = rb.velocity.magnitude; // For example velocity of RB
    em.rate = mmc;
}

Just a basic example of setting the emissionRate Property of the new ParticleSystem.