+2 votes

Hello. I was working on a system where the player's speed would change how many particles are generated. I wrote the code and it works perfectly, except that everytime the player's speed is updated, all the existing particles are instantly deleted. Is there a way to change that? Thanks in advance.

Godot version 3.2.3
in Engine by (21 points)

I had this same problem too a while back. I know this doesn't answer any questions, but my solution was to avoid it entirely.

I have an idea though: what if you stop the Particle2D node from emitting, change the amount, and turn on emitting again in the same frame? I haven't tried this, so sorry if it doesn't work.

I update the Particles2D node.

So it worked?

I think you should instance new particle system when you update values

Please log in or register to answer this question.

Welcome to Godot Engine Q&A, where you can ask questions and receive answers from other members of the community.

Please make sure to read How to use this Q&A? before posting your first questions.
Social login is currently unavailable. If you've previously logged in with a Facebook or GitHub account, use the I forgot my password link in the login box to set a password for your account. If you still can't access your account, send an email to webmaster@godotengine.org with your username.