Difference between revisions of "MD-500D/SL Features"

From
Jump to: navigation, search
(Commands)
(Commands)
Line 24: Line 24:
 
|-
 
|-
 
|ONFAIL ''asgns'' | ''mesg'' || Sets a behavior to execute when a REQUIRE command fails.  ''asgns'' is a list of assignments to perform, and ''mesg'' is a message to display to the pilot.
 
|ONFAIL ''asgns'' | ''mesg'' || Sets a behavior to execute when a REQUIRE command fails.  ''asgns'' is a list of assignments to perform, and ''mesg'' is a message to display to the pilot.
 +
|-
 
|APPLY ''asgns'' || Executes a list of ; separated assignments.
 
|APPLY ''asgns'' || Executes a list of ; separated assignments.
 
|}
 
|}

Revision as of 20:03, 14 March 2026

SECTION 13. SL Features

1 Macros and Appliers

Macros and appliers can be used to execute fixed sequences of commands. The commands are written in notecards with specific prefixes, "*apply:" for appliers, and "*macro:" for macros. Both types of notecards are functionally equivalent and differ only in the command used to invoke them, and the intended use. Appliers are intended to set texture and otherwise modify the visual appearance of the aircraft, while macros are intended to activate switches and controls to put the aircraft into a desired state.

1.1 Invoking

To invoke an applier, use the command:

apply seats-white

This will look for the notecard "*apply:seats-white" in the aircraft inventory, and execute commands from it. Similarly, use the command:

exec auto

to invoke commands from the notecard "*macro:auto".

1.2 Commands

Command Description
ONFAIL asgns | mesg Sets a behavior to execute when a REQUIRE command fails. asgns is a list of assignments to perform, and mesg is a message to display to the pilot.
APPLY asgns Executes a list of ; separated assignments.