Show raw api
{
"functions": [
{
"name": "new",
"desc": "Construct a new instance",
"params": [
{
"name": "event_init",
"desc": "general init callback",
"lua_type": "(self: Progress) -> ()"
},
{
"name": "event_update",
"desc": "general update callback",
"lua_type": "(self: Progress) -> ()"
},
{
"name": "event_exit",
"desc": "general exit callback",
"lua_type": "(self: Progress) -> ()"
}
],
"returns": [],
"function_type": "method",
"source": {
"line": 15,
"path": "../../res/data/script/lib/env/progress.lua"
}
},
{
"name": "setPermanent",
"desc": "Use a permanent variable to save the state",
"params": [
{
"name": "id",
"desc": "variable name",
"lua_type": "string"
}
],
"returns": [],
"function_type": "method",
"source": {
"line": 37,
"path": "../../res/data/script/lib/env/progress.lua"
}
},
{
"name": "add",
"desc": "Add a state",
"params": [
{
"name": "name",
"desc": "state identifier",
"lua_type": "string"
},
{
"name": "init",
"desc": "general init callback",
"lua_type": "(self: ProgressState) -> (string | nil)"
},
{
"name": "update",
"desc": "general update callback",
"lua_type": "(self: ProgressState) -> (string | nil)"
},
{
"name": "exit",
"desc": "general exit callback",
"lua_type": "(self: ProgressState) -> (string | nil)"
}
],
"returns": [],
"function_type": "method",
"source": {
"line": 48,
"path": "../../res/data/script/lib/env/progress.lua"
}
},
{
"name": "get",
"desc": "Get the current state",
"params": [],
"returns": [],
"function_type": "method",
"source": {
"line": 55,
"path": "../../res/data/script/lib/env/progress.lua"
}
},
{
"name": "switch",
"desc": "Switch to a state",
"params": [
{
"name": "name",
"desc": "state identifier",
"lua_type": "string"
}
],
"returns": [],
"function_type": "method",
"source": {
"line": 78,
"path": "../../res/data/script/lib/env/progress.lua"
}
},
{
"name": "updateState",
"desc": "Process any pending state changes",
"params": [],
"returns": [],
"function_type": "method",
"source": {
"line": 85,
"path": "../../res/data/script/lib/env/progress.lua"
}
},
{
"name": "update",
"desc": "Run a single step of the state machine",
"params": [],
"returns": [],
"function_type": "method",
"source": {
"line": 139,
"path": "../../res/data/script/lib/env/progress.lua"
}
},
{
"name": "run",
"desc": "Continuously run the state machine",
"params": [],
"returns": [],
"function_type": "method",
"source": {
"line": 231,
"path": "../../res/data/script/lib/env/progress.lua"
}
}
],
"properties": [],
"types": [],
"name": "Progress",
"desc": "A general use state machines for scene scripting",
"source": {
"line": 7,
"path": "../../res/data/script/lib/env/progress.lua"
}
}