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

No proximity or contact detected between moving Kinematic and Static #25

Closed
vilcans opened this issue Oct 1, 2020 · 2 comments
Closed
Labels
C-Bug Something isn't working

Comments

@vilcans
Copy link

vilcans commented Oct 1, 2020

I'm moving a Kinematic object and expect to get proximity or contact events when the Kinematic intersects a Static object.

I investigated this more, and found that the results are different depending on whether the moving object is a sensor. But in both cases, no intersection between a Kinematic and a Static is reported.

Here are the results. Note that when a moving Kinematic intersects a Static, the result is None (no contact).

Moving object is not a sensor:
Moving Dynamic vs Dynamic => Contact
Moving Static vs Dynamic => None
Moving Kinematic vs Dynamic => None
Moving Dynamic vs Static => Contact
Moving Static vs Static => None
Moving Kinematic vs Static => None
Moving Dynamic vs Kinematic => Contact
Moving Static vs Kinematic => None
Moving Kinematic vs Kinematic => None

Moving object is sensor:
Moving Dynamic vs Dynamic => Proximity
Moving Static vs Dynamic => None
Moving Kinematic vs Dynamic => Proximity
Moving Dynamic vs Static => Proximity
Moving Static vs Static => None
Moving Kinematic vs Static => None
Moving Dynamic vs Kinematic => Proximity
Moving Static vs Kinematic => None
Moving Kinematic vs Kinematic => None

Test program here: https://github.com/vilcans/rapier-intersection-test

Please let me know if I have misunderstood how detection is supposed to work.

@sebcrozet
Copy link
Member

Currently, contacts and proximity are never computed between colliders attached to two static/kinematic bodies. This is being discussed in #15 .

So most of what you are observing are currently the expected behavior, except for:

Moving Static vs Dynamic => None (both sensor and non-sensor cases)
Moving Kinematic vs Dynamic => None

which look like a bugs.

@sebcrozet sebcrozet added the C-Bug Something isn't working label Oct 1, 2020
@sebcrozet
Copy link
Member

Closing this as all these cases can now be obtained by setting up the appropriate physics hooks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-Bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants