Bring back some elements of better Body destruction that got lost in the merge

This commit is contained in:
Bill Meltsner
2011-10-12 13:51:47 -05:00
parent d40b25c1e6
commit 56ae3a95fc
3 changed files with 28 additions and 0 deletions
+10
View File
@@ -40,6 +40,7 @@ namespace box2d
{
class Contact;
class Body;
class Fixture;
/**
@@ -106,6 +107,9 @@ namespace box2d
// Ground body
b2Body * groundBody;
// The list of to be destructed bodies.
std::vector<Body*> destructBodies;
// Contact callbacks.
ContactCallback begin, end, presolve, postsolve;
@@ -255,6 +259,12 @@ namespace box2d
* Raycasts the World for all Fixtures in the path of the ray.
**/
int rayCast(lua_State * L);
/**
* Mark a body for destruction.
* To be called from Body
**/
void destroyBody(Body * b);
};