Switch

From Staredit Network Wiki
Jump to: navigation, search

A Switch is an on/off variable that can be found in "Set" or "Cleared" states. Switches are assigned values with actions and tested with conditions. Switches may be given custom names which makes them use strings. There is a maximum of 256 switches that may be used in a map. Switches can be used to keep track of which triggers have been activated, to disable or enable certain triggers or to link multiple triggers together.

Conditions

Condition text: <Switch name> is <switch state>.

Tests switch <switch name> against given state <switch state>.

Editors syntax

Syntax in SCMDraft 2:

  • Switch("Switch name", set/not set);

Syntax in StarForge:

  • Switch(Switch name, Switch state);

Actions

Action text: <Switch name> is <switch state>.

Tests switch <switch name> against given state <switch state>.

Editors syntax

Syntax in SCMDraft 2:

  • Switch("Switch name", set/not set);

Syntax in StarForge:

  • Switch(Switch name, Switch state);

See Also