Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement a force_stop function on particles #6573

Closed
QbieShay opened this issue Mar 26, 2023 · 1 comment
Closed

Implement a force_stop function on particles #6573

QbieShay opened this issue Mar 26, 2023 · 1 comment

Comments

@QbieShay
Copy link

Describe the project you are working on

Various VFX

Describe the problem or limitation you are having in your project

Some effect have long lived particles that linger for long after the effect is finished. Reducing the lifetime will not work because slow motion requires longer lifetimes, and motion changes the feeling of an effect A LOT.

Describe the feature / enhancement and how it helps to overcome the problem or limitation

Add a way to interpolate lifetime towards 1 in a given time

Describe how your proposal will work, with code, pseudo-code, mock-ups, and/or diagrams

Add a force_stop(interp_time) function that behaves as follows:

  1. disables emission
  2. interpolates each particle's current lifetime towards 1 in given interp_time

In this given time, all properties that operate on lifetime (color, scale, angle, everything) will be able to correctly reach the end of their life and disappear all together.

If this enhancement will not be used often, can it be worked around with a few lines of script?

It's used in many VFX. currently VFX (in all engine) kind of either have to deal with this limitation and have long lingering particles, or implement custom shader/script solutions to do this.

This can be achieved by adding a line to the particles material - but this won't work for CPU particles because they cant be scripted (plus all the annoyances of using a particle process shader rather than the base material

Is there a reason why this should be core and not an add-on in the asset library?

Convenience and compatibility with GPUParticles.

@QbieShay
Copy link
Author

Superseded by godotengine/godot#79527

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Done
Development

No branches or pull requests

2 participants