When porting box2d to actionscript, I found some problems, but because I
didn't study the code deeply, so maybe they are designedly.
1. Possible a contact is passed to contactListerner.BeginContact, but
never passed to contactListerner.EndContact, even if it has been destroyed:
a. one case: the contact is a touched in last step, but in current step,
even the aabbs are not overlapped, then the contact is destroyed, so the
EndContact is not called for this contact.
b. other reasons make the contact destroyed:
- some Destroy (contact)s in contactManager.Collide
- destroy fixtures
2. SyaGoodbye is not called in body.DestroyFixture and body.DestroyJoint.
Maybe this is deliberately.
3. Should "BufferMove (fixture)" also be called when a body become dynamic
from static? Image a situation: in a non-gravity enviroment, two static
shapes are ovelapped, then make one dynamic. Seems now no contacts will be
created between them.
4. Should ContactListener.PreSolve () only be called when (contact.m_flags
& e_touchingFlag) != 0 && newCount > 0
5. If I change the ShouldCollide rules runtimely, how can I make the core
api knows this change and call FlagForFiltering?
6. Can I change joint.m_collideConnected runtimely, if true, how can I
make the core api knows this change and call FlagForFiltering?
7. About the body mass, if there is only one shape with zero density in a
body, then the body is static, but if another shape with non-zero density
is added to the body, the body will become dynamic. If it is the design,
no problems here. I just thnk it is more reasonable to make the body
static only if there is a zero denstiy shape in the body.
That is all, maybe I'm wrong on these points.
btw, I like the new broadphase very much!