Memoize Contacts, and add List-fetching functions to World (they return arrays)

--HG--
branch : box2d-update
This commit is contained in:
Bill Meltsner
2011-09-24 16:46:07 -04:00
parent f852c9bac2
commit 6a0c5b485b
5 changed files with 114 additions and 0 deletions
+24
View File
@@ -214,6 +214,30 @@ namespace box2d
* @return The number of joints.
**/
int getJointCount();
/**
* Get the current contact count.
* @return The number of contacts.
**/
int getContactCount();
/**
* Get an array of all the Bodies in the World.
* @return An array of Bodies.
**/
int getBodyList(lua_State * L);
/**
* Get an array of all the Joints in the World.
* @return An array of Joints.
**/
int getJointList(lua_State * L);
/**
* Get an array of all the Contacts in the World.
* @return An array of Contacts.
**/
int getContactList(lua_State * L);
/**
* Gets the ground body.