diff options
author | RĂ©mi Verschelde <rverschelde@gmail.com> | 2017-08-17 10:52:35 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-08-17 10:52:35 +0200 |
commit | e2c1792d06ab751a033a1e83802875dd4a2f95de (patch) | |
tree | 078169902dcc018595d27a55835d7ad1f3b76eba | |
parent | 2e54c5372d2ff0894107fe877e579084fb1943a2 (diff) | |
parent | 995fca44b200b093f1d3ff62d16846ba2e3df900 (diff) |
Merge pull request #10383 from bojidar-bg/x-fix-particles-emitting
Fix particles emitting when emitting is set to false in scene
-rw-r--r-- | drivers/gles3/rasterizer_storage_gles3.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/gles3/rasterizer_storage_gles3.cpp b/drivers/gles3/rasterizer_storage_gles3.cpp index ea6ac569f0..24fa117051 100644 --- a/drivers/gles3/rasterizer_storage_gles3.cpp +++ b/drivers/gles3/rasterizer_storage_gles3.cpp @@ -5177,6 +5177,10 @@ void RasterizerStorageGLES3::particles_set_emitting(RID p_particles, bool p_emit Particles *particles = particles_owner.getornull(p_particles); ERR_FAIL_COND(!particles); + if (p_emitting != particles->emitting) { + // Restart is overriden by set_emitting + particles->restart_request = false; + } particles->emitting = p_emitting; } void RasterizerStorageGLES3::particles_set_amount(RID p_particles, int p_amount) { |