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

Removing ColliderDisabled component does not re-enable collisions #435

Closed
rafalh opened this issue Oct 9, 2023 · 1 comment · Fixed by dimforge/rapier#538
Closed

Removing ColliderDisabled component does not re-enable collisions #435

rafalh opened this issue Oct 9, 2023 · 1 comment · Fixed by dimforge/rapier#538

Comments

@rafalh
Copy link
Contributor

rafalh commented Oct 9, 2023

When ColliderDisabled component is removed collision detection is not getting effectively re-enabled (collider does not affect rigid bodies etc.).
Please see attached code for a minimal reproducible example: rapier-bug-enable-collider.zip
I tried to debug it for a moment and it seems that ColliderDisabled component removal is properly detected so it may be a bug in the Rapier itself.

rafalh added a commit to rafalh/rapier that referenced this issue Oct 18, 2023
If collider was enabled and no other attributes were changed its collisions
were not detected. This was the result of `needs_broad_phase_update` function
not handling case of changed enabled status.
Fixes dimforge/bevy_rapier#435
@rafalh
Copy link
Contributor Author

rafalh commented Oct 18, 2023

This issue is fixed by dimforge/rapier#538
Workaround until new version is released: modify transform component (can be set to the same value, it's only important to trigger change detection)

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 a pull request may close this issue.

1 participant