Moai SDK
2.0
|
Function List | |
addChild | |
attach | |
clear | |
defer | |
detach | |
getChildren | |
hasChildren | |
isActive | |
isBusy | |
isDone | |
isPaused | |
pause | |
setAutoStop | |
start | |
stop | |
throttle | |
update | |
Function List inherited from MOAIInstanceEventSource | |
getListener | |
setListener | |
|
|
Attaches a child action for updating.
function addChild ( MOAIAction self, MOAIAction child [, boolean defer ] )
MOAIAction | self |
MOAIAction | child |
boolean | defer Optional. Default value is 'false.' |
|
Attaches a child to a parent action. The child will receive updates from the parent only if the parent is in the action tree.
function attach ( MOAIAction self [, MOAIAction parent, boolean defer ] )
MOAIAction | self |
MOAIAction | parent Optional. Default value is nil; same effect as calling detach (). |
boolean | defer Optional. Default value is 'false.' |
|
Removes all child actions.
function clear ( MOAIAction self )
MOAIAction | self |
|
Defers action's update until the next time the action tree is processed.
function defer ( MOAIAction self )
MOAIAction | self |
|
Detaches an action from its parent (if any) thereby removing it from the action tree. Same effect as calling stop ().
function detach ( MOAIAction self )
MOAIAction | self |
|
Get action's children (if any).
function getChildren ( MOAIAction self )
MOAIAction | self |
|
Returns 'true; if action has children and the number of children.
function hasChildren ( MOAIAction self )
MOAIAction | self |
|
Checks to see if an action is currently in the action tree.
function isActive ( MOAIAction self )
MOAIAction | self |
|
Checks to see if an action is currently busy. An action is 'busy' only if it is 'active' and not 'done.'.
function isBusy ( MOAIAction self )
MOAIAction | self |
|
Checks to see if an action is 'done.' Definition of 'done' is up to individual action implementations.
function isDone ( MOAIAction self )
MOAIAction | self |
|
Checks to see if an action is 'paused.'.
function isPaused ( MOAIAction self )
MOAIAction | self |
|
Leaves the action in the action tree but prevents it from receiving updates. Call pause ( false ) or start () to unpause.
function pause ( MOAIAction self [, boolean pause ] )
MOAIAction | self |
boolean | pause Optional. Default value is 'true.' |
|
Flag action to automatically stop (and be removed from action tree) when no longer busy.
function setAutoStop ( MOAIAction self )
MOAIAction | self |
|
Adds the action to a parent action or the root of the action tree.
function start ( MOAIAction self [, MOAIAction parent, boolean defer ] )
MOAIAction | self |
MOAIAction | parent Optional. Default value is MOAIActionMgr.getRoot () |
boolean | defer Optional. Action will first run during the next sim step, even if it visited during the current sim step. Default value is 'false.' |
|
Removed the action from its parent action; action will stop being updated.
function stop ( MOAIAction self )
MOAIAction | self |
|
Sets the actions throttle. Throttle is a scalar on time. Is is passed to the action's children.
function throttle ( MOAIAction self [, number throttle ] )
MOAIAction | self |
number | throttle Optional. Default value is 1. |
|
Update action manually. This call will not update child actions.
function update ( MOAIAction self [, number step ] )
MOAIAction | self |
number | step Optional. Default value is sim step |