Arma 3 Scripting

setFSMVariable

  • Arma 3 v0.50
  • First in Arma 2 v1.00

Command · Markdown · JSON · original wiki page

Description

Set variable to given value in the variable space of given FSM.

The FSM handle is the number returned by the execFSM command.

Syntax

handle setFSMVariable [name, value]

Parameters:

Returns: Nothing

Examples

Example 1

_handle = execFSM "test.fsm";
_handle setFSMVariable ["_foo", 23]; // sets variable _foo in the FSM to 23

See also

FSM · commandFSM · completedFSM · doFSM · execFSM · getFSMVariable

Community notes

Master85

If the variable is not yet defined within the FSM it will be created.