Difference between revisions of "StopAction"
From The Official Visionaire Studio: Adventure Game Engine Wiki
Line 40: | Line 40: | ||
<b><u>Arguments</u></b> | <b><u>Arguments</u></b> | ||
− | action: path <br/> | + | <b>action</b>: path <br/> |
The path to the action to be stopped! ("path"."object_id"."action") | The path to the action to be stopped! ("path"."object_id"."action") | ||
− | |||
− | Return | + | <b><u>Flags</u></b> |
− | {{i18n|StopAction}} | + | |
+ | none | ||
+ | |||
+ | <b><u>Return</u></b> | ||
+ | |||
+ | none | ||
+ | {{i18n|StopAction}} <br/> | ||
+ | {| style="background: #f0f0f0; border: 1px dashed darkgrey" width="100%" | ||
+ | |- | ||
+ | |<b>Relevant Pages</b>: [[StartpAction|startAction]] | ||
+ | |} |
Revision as of 19:08, 8 March 2013
Command History
Available since v3.7
Allows you to stop any "called by other action" you include!
Syntax:
stopAction(action)
Example 1: basic stop action method
--[[
!important: you must take care when using this method that you don't have multiple instances of actions with the same name otherwise it will not work correctly!
--]]
-- shortened get action method; !important: see comment above!
stoptAction("Actions[action_name]")
-- full get action method; !recommended
stoptAction("Scenes[scene_name].SceneObjects[object_name].SceneActions[action_name]")
Example 2: stop action via a variable
-- you can of course use variables with actions stored in them instead!
local act = getObject("Actions[action_name]")
stoptAction(act)
Arguments
action: path
The path to the action to be stopped! ("path"."object_id"."action")
Flags
none
Return
none
日本語 – 正體中文 – 한국어 – Dansk – Deutsch – English – Español – Français – Italiano – Nederlands – Polski – Português – Svenska – Русский |
Relevant Pages: startAction |