mode
mode
gets/sets the action playback mode
Type: integer
0 =
KX_ACTIONACT_PLAY
1 =
2 = KX_ACTIONACT_FLIPPER
3 = KX_ACTIONACT_LOOPSTOP
4 = KX_ACTIONACT_LOOPEND
5 =
6 = KX_ACTIONACT_PROPERTY
Sample Code
################ Get mode
# get the controller
controller = GameLogic.getCurrentController()
# get the
actuator attached to controller named Walk
act = controller.actuators["Walk"]
# get playback mode
actionType = act.mode
################ Set mode
# get the controller
controller = GameLogic.getCurrentController()
# get the
actuator attached to controller named Walk
act = controller.actuators["Walk"]
# set playback mode
act.mode = 0
|