mirror of
https://github.com/love2d/love.git
synced 2026-08-16 16:20:42 +02:00
Fixed World:getBodyList, World:getJointList, and World:getContactList causing hard crashes instead of Lua errors
This commit is contained in:
@@ -143,21 +143,27 @@ int w_World_getBodyList(lua_State *L)
|
||||
{
|
||||
World *t = luax_checkworld(L, 1);
|
||||
lua_remove(L, 1);
|
||||
return t->getBodyList(L);
|
||||
int ret = 0;
|
||||
EXCEPT_GUARD(ret = t->getBodyList(L);)
|
||||
return ret;
|
||||
}
|
||||
|
||||
int w_World_getJointList(lua_State *L)
|
||||
{
|
||||
World *t = luax_checkworld(L, 1);
|
||||
lua_remove(L, 1);
|
||||
return t->getJointList(L);
|
||||
int ret = 0;
|
||||
EXCEPT_GUARD(ret = t->getJointList(L);)
|
||||
return ret;
|
||||
}
|
||||
|
||||
int w_World_getContactList(lua_State *L)
|
||||
{
|
||||
World *t = luax_checkworld(L, 1);
|
||||
lua_remove(L, 1);
|
||||
return t->getContactList(L);
|
||||
int ret = 0;
|
||||
EXCEPT_GUARD(ret = t->getContactList(L);)
|
||||
return ret;
|
||||
}
|
||||
|
||||
int w_World_queryBoundingBox(lua_State *L)
|
||||
|
||||
Reference in New Issue
Block a user