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

Improve decluster -> In addition to applying distance, apply size, and remove particle lifetime, therefore better simulating the particle as if it was emitted between frames #36

Merged
merged 2 commits into from Jul 29, 2019

Conversation

PatPL
Copy link
Contributor

@PatPL PatPL commented Jul 27, 2019

This change adds to particle's size on Emit, similar to how it adds distance. Other that that, it also subtracts appropiate amount of time from particle's remaining lifetime to improve color animation smoothness across particles spawned in one frame.

smokescreamaaaaaaaaaaaaaaaaa

This change also tweaked some logic responsible for detecting if particle was spawned this frame

// (particle = particles[j])

// Previous:
particle.remainingLifetime == particle.startLifetime

// Current:
j >= numParticlesAlive - ParticlesThisFrame

This change most likely won't be visible on most regular plumes. It's most visible on quickly expanding, high velocity plumes

@sarbian sarbian merged commit fa3c319 into sarbian:master Jul 29, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants