Hey,
What would be the best way to precisely determine the impulse a collision generates? I've tried a few things:
- using a b2ContactResult
But I'm not always getting reading of a result. Sometimes it just doesn't seem to happen?
- using a b2ContactPoint (with b2ContactListener.Add())
-> velocity doesn't seem to be consistent. Sometimes a 'slow' collision seems to give a higher value than a really fast one.
-> seperation seems to have the same problem. I tried making one of the to-collide objects' a bullet, but it's still not that great.
My best guess is still using b2ContactResult, but why doesn't it always work? I only get a few traces through, after that, it seems to just stop detecting collisions, for that specific object. When I spawn a new object, it works a few times with that object again.
Thanks!
What would be the best way to precisely determine the impulse a collision generates? I've tried a few things:
- using a b2ContactResult
But I'm not always getting reading of a result. Sometimes it just doesn't seem to happen?
- using a b2ContactPoint (with b2ContactListener.Add())
-> velocity doesn't seem to be consistent. Sometimes a 'slow' collision seems to give a higher value than a really fast one.
-> seperation seems to have the same problem. I tried making one of the to-collide objects' a bullet, but it's still not that great.
My best guess is still using b2ContactResult, but why doesn't it always work? I only get a few traces through, after that, it seems to just stop detecting collisions, for that specific object. When I spawn a new object, it works a few times with that object again.
Thanks!