This commit is contained in:
Garrett Brown
2020-08-16 19:01:59 -04:00
parent 59a1a4b2cd
commit 09db462fd6
16 changed files with 111 additions and 124 deletions
@@ -102,18 +102,18 @@ int w_WheelJoint_getMotorTorque(lua_State *L)
return 1;
}
int w_WheelJoint_setSpringFrequency(lua_State *L)
int w_WheelJoint_setSpringStiffness(lua_State *L)
{
WheelJoint *t = luax_checkwheeljoint(L, 1);
float arg1 = (float)luaL_checknumber(L, 2);
t->setSpringFrequency(arg1);
t->setStiffness(arg1);
return 0;
}
int w_WheelJoint_getSpringFrequency(lua_State *L)
int w_WheelJoint_getSpringStiffness(lua_State *L)
{
WheelJoint *t = luax_checkwheeljoint(L, 1);
lua_pushnumber(L, t->getSpringFrequency());
lua_pushnumber(L, t->getStiffness());
return 1;
}
@@ -121,14 +121,14 @@ int w_WheelJoint_setSpringDampingRatio(lua_State *L)
{
WheelJoint *t = luax_checkwheeljoint(L, 1);
float arg1 = (float)luaL_checknumber(L, 2);
t->setSpringDampingRatio(arg1);
t->setDamping(arg1);
return 0;
}
int w_WheelJoint_getSpringDampingRatio(lua_State *L)
{
WheelJoint *t = luax_checkwheeljoint(L, 1);
lua_pushnumber(L, t->getSpringDampingRatio());
lua_pushnumber(L, t->getDamping());
return 1;
}
@@ -150,8 +150,8 @@ static const luaL_Reg w_WheelJoint_functions[] =
{ "setMaxMotorTorque", w_WheelJoint_setMaxMotorTorque },
{ "getMaxMotorTorque", w_WheelJoint_getMaxMotorTorque },
{ "getMotorTorque", w_WheelJoint_getMotorTorque },
{ "setSpringFrequency", w_WheelJoint_setSpringFrequency },
{ "getSpringFrequency", w_WheelJoint_getSpringFrequency },
{ "setSpringStiffness", w_WheelJoint_setSpringStiffness },
{ "getSpringStiffness", w_WheelJoint_getSpringStiffness },
{ "setSpringDampingRatio", w_WheelJoint_setSpringDampingRatio },
{ "getSpringDampingRatio", w_WheelJoint_getSpringDampingRatio },
{ "getAxis", w_WheelJoint_getAxis },