blackberry-gaming/GamePlay — pull request #536 by kcunney (2012-07-13 16:03:04+00:00)
Title: Fixes for physics

Fixes bug where upon re-enabling physics on a collision object, the object's physics world transform was not being updated with the node's current transform.

Fixes bug where collision listeners on a collision object were being removed when calling setEnabled(false) on the object.

Adds a flag to the PhysicsController to keep track of when it is updating the physics simulation. The flag is asserted to be false when calling PhysicsController::removeCollisionObject(). This is to denote that removing collision objects while the PhysicsController is updating the physics simulation is not permitted. (ie: from within the PhysicsCollisionObject::Listener::collisionEvent() callback)

Adds note to the doxygen comments for the PhysicsCollisionObject::Listener::collisionEvent() callback to indicate that removing PhysicsCollisionObjects from the physics world is not permitted from within the callback.

Removes false memory leak being reported in Game. Changes the std::vector to a pointer to a std::vector.