It looks like you're new here. If you want to get involved, click one of these buttons!
Sometimes game logic needs to know when two fixtures overlap yet there should be no collision response. This is done by using sensors. A sensor is a fixture that detects collision but does not produce a response. You can flag any fixture as being a sensor. Sensors may be static or dynamic. Remember that you may have multiple fixtures per body and you can have any mix of sensors and solid fixtures. Sensors do not generate contact points. There are two ways to get the state of a sensor: b2Contact::IsTouching b2ContactListener::BeginContact and EndContact |
Comments
I think you just create the fixture and use:
fixture.name = "ground sensor"
Then use something like...
(I was trying to use pre-solve which I'm guessing won't work as it's a sensor...)
Likes: ar2rsawseen
Likes: ar2rsawseen