LuaBody

Body type for use in lua scripting.

See ScriptController and ScriptMeasure for details on scripting.

Public Functions

Function Description
LuaString name() get the name of the body
LuaVec3 com_pos() get the current com position [m]
LuaVec3 com_vel() get the current com velocity [m/s]
LuaVec3 point_pos(const LuaVec3 &p) get the global position [m] of a local point p on the body
LuaVec3 point_vel(const LuaVec3 &p) get the global linear velocity [m/s] of a local point p on the body
LuaQuat ori() get the body orientation as a quaternion
LuaVec3 ang_pos() get the body orientation as a 3d rotation vector [rad]
LuaVec3 ang_vel() get the angular velocity [rad/s] of the body
LuaVec3 get_contact_force() add contact force [N] to body com
LuaVec3 get_contact_moment() get contact moment [Nm] to body
void add_external_force(LuaNumber x, LuaNumber y, LuaNumber z) add external force [N] to body com
void add_external_moment(LuaNumber x, LuaNumber y, LuaNumber z) add external moment [Nm] to body

Converted from doxygen using dokugen

  • (external edit)