Set or delete a console variable
gma3_set_variableSet, delete, and verify global or user variables with type control and batch support, so macros and cue commands can use $name values reliably.
Instructions
Set a global or user variable to a value with its type (integer, double or text, as SetGlobalVariable / SetUserVariable do; a text keeps quotes exactly), or delete it, then read it back (value and type). User variables are the bridge's user's (another user profile has its own). Macros and cue commands use them as $name (outside quotes); a user variable shadows a global one. Needs bridge 0.31.0. Batch form: give the list instead of the single object's fields; the other arguments are defaults for every item (an item's own fields win). Each item gets the single form's checks and read-back, and its own outcome; items run in order, nothing is retried, an unknown outcome stops the rest, and the result has one line per item (detail: true for every step).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | No | Variable name (case-sensitive). Required unless variables is given. | |
| type | No | The type (default: from the value: whole number integer, other number double, string text). | |
| scope | No | global (every user) or user (the bridge's user profile). Required unless variables is given (it may then be a default). | |
| value | No | The value: a number (integer or double) or a text ("9" is the text 9). | |
| delete | No | Delete the variable instead of setting it. | |
| detail | No | Return every item's full result with its steps (default false: one line per item). | |
| verify | No | Read the variable back and compare (default true). | |
| variables | No | Batch form: several variables, each {scope, name, value, type} or {scope, name, delete: true}; scope may be given once for all. | |
| stop_on_failure | No | Batch form: stop at the first item that does not succeed (default false: independent items go on; an item on an object an earlier item failed on is skipped either way). |