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

Changing RigidBody bodyType before any collisions makes rigidBody static #267

Open
frankieali opened this issue Feb 29, 2024 · 1 comment

Comments

@frankieali
Copy link

frankieali commented Feb 29, 2024

With a simple scene such as a ball dropping onto a plane, if the dynamic rigid body is set to "fixed" after a few steps and then back to "dynamic" after a few more steps before colliding with the plane, then it will become stuck, unaffected by gravity as if it were still fixed. Once another object collides with it then it will begin to move again.

@frankieali
Copy link
Author

frankieali commented Feb 29, 2024

For example, as seen in this demo: https://react-three-rapier.pmnd.rs/dynamic-type-changes
The Suzanne monkey head is falling as a dynamic object. On mousedown of the model, it toggles to kinematic. Refresh the page and try to catch the Suzanne monkey head before it hits the floor with your pointer. Once you release your pointer, the head will no longer fall even though it's dynamic again. Then drag the head all the way down until it intersects the floor (you may need to zoom out). After that first collision intersection, the bodyType changing seems to work as expected.

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

No branches or pull requests

1 participant