physicCollider - onPostSolve() contact.getImpulse() not work

physicCollider - onPostSolve() contact.getImpulse() not work

I’ve tested many times to find out contact.getImpulse() will always return

     normalImpulses: cc.v2(0,0),
     tangentImpulses: cc.v2(0,0)

Is this a feature or a bug?
I need to get the impulse casted to a rigidBody in a physic-collision to see if it node should be broken.

Anyone experienced this?
I’ve found that no one asked this in this forum as well as Google. How weird!

My lastest test revealed that if collision caused by node running action will always make contact.getImpulse() return 0.
But if I call rigidBody.applyForceToCenter(...) then onPostSolve() contact.getImpulse() return a positive number.

For anyone who struggle this in the past & furture.

1 Like

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.