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

GPU Particle Attractor has no effect on stationary particles (GPUParticle3D) #87221

Closed
peterhoglund opened this issue Jan 15, 2024 · 4 comments · Fixed by #87320
Closed

GPU Particle Attractor has no effect on stationary particles (GPUParticle3D) #87221

peterhoglund opened this issue Jan 15, 2024 · 4 comments · Fixed by #87320

Comments

@peterhoglund
Copy link

peterhoglund commented Jan 15, 2024

Tested versions

v4.2.1.stable.official [b09f793]

System information

4.2 stable, Windows 10 - Vulkan Forward+ - Nvidia GeForce RTX 2070 Super

Issue description

I'm trying to use a particle attractor to shoot away particles that have landed (collided) on a surface. The attractor works fine as long as they are moving, but when they land on the surface and become still the attractor don't have any effect on the particles.

I have set the Collision to Rigid and Friction to 0. I've tried Bounce from 0 and above (with a bounce of 1 the attractor work as the particle has bounced off the surface and is in the air again).

Steps to reproduce

Create a GPU Particle 3D
Create a GPU Particle Collision Box
Create a GPU Particle Attractor Box 3D

Assign a sphere shape to the Particle and turn Collision on, set to Rigid and Friction to 0 and Bounce to 0
Have the particles land on the Collision box and become still
Move the Attractor over the particles to have them move. They are not affected by the Attractor

Minimal reproduction project (MRP)

ParticleTestProjectX.zip

@AThousandShips
Copy link
Member

Please provide a minimum project to make this easier to test 🙂

  • A small Godot project which reproduces the issue, with no unnecessary files included. Be sure to not include the .godot folder in the archive (but keep project.godot).
  • Having an MRP is very important for contributors to be able to reproduce the bug in the same way that you are experiencing it. When testing a potential fix for the issue, contributors will use the MRP to validate that the fix is working as intended.
  • If the reproduction steps are not project dependent (e.g. the bug is visible in a brand new project), you can write "N/A" in the field.
  • Drag and drop a ZIP archive to upload it (max 10 MB). Do not select another field until the project is done uploading.
  • Note for C# users: If your issue is not C#-specific, please upload a minimal reproduction project written in GDScript. This will make it easier for contributors to reproduce the issue locally as not everyone has a .NET setup available.

@peterhoglund
Copy link
Author

peterhoglund commented Jan 16, 2024

@AThousandShips I've added a test project. Let me know if it doesn't work as expected.

@Rudolph-B
Copy link
Contributor

I did some testing. It seems what happens is that one of the "collided" states of a particle sets it velocity to 0 unless there is a massive change in velocity. The force the attractor applies to the particle is not enough to push it out this state causing the particle to look stuck.

@Rudolph-B
Copy link
Contributor

I think I have a fix but it is definitely going to change existing behavior. Doing some more testing.

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

Successfully merging a pull request may close this issue.

5 participants