Expose axis vector of PrismaticJoint and WheelJoint (fixes #1176)

This commit is contained in:
airstruck
2016-07-07 21:13:49 +02:00
parent debea1192b
commit 24da8433d0
7 changed files with 43 additions and 0 deletions
@@ -132,6 +132,13 @@ int w_WheelJoint_getSpringDampingRatio(lua_State *L)
return 1;
}
int w_WheelJoint_getAxis(lua_State *L)
{
WheelJoint *t = luax_checkwheeljoint(L, 1);
lua_remove(L, 1);
return t->getAxis(L);
}
static const luaL_Reg w_WheelJoint_functions[] =
{
{ "getJointTranslation", w_WheelJoint_getJointTranslation },
@@ -147,6 +154,7 @@ static const luaL_Reg w_WheelJoint_functions[] =
{ "getSpringFrequency", w_WheelJoint_getSpringFrequency },
{ "setSpringDampingRatio", w_WheelJoint_setSpringDampingRatio },
{ "getSpringDampingRatio", w_WheelJoint_getSpringDampingRatio },
{ "getAxis", w_WheelJoint_getAxis },
{ 0, 0 }
};