|
applyTorqueapplyTorque(torque, local):Note:Object types: Dynamic and
Rigid body
Sets the game object's torque. torque: Type: 3D
Vector
localType: Bool
1 = True
Apply force using
local (game object) axis
0 = False
Apply force using
world axis
Sample Code# get controllercontroller = GameLogic.getCurrentController()# get object that controller is attached toobj = controller.owner# set torque amounttorque = [ 0.0, 0.0, 50.0]# use world axislocal = False# apply torqueobj.applyTorque( torque, local) |