BUTTON STATE
Generally used with the IF command, this script returns 1 if the button is down and 0 if the button is up.
FORMAT: BUTTON button_name STATE or BUTTON button_name STATE IN WINDOW
DEFINITIONS:
- button_name: A string with the name of a button in the code input window.
EXAMPLE 1:
SHOW BUTTON "name1" STATE
Shows 0 or 1, depending on if the button called "name1" is up or down.
EXAMPLE 2
Obtains the name of the button with ID name "player1" and uses it in the $player variable. If the button in the same code window named with the value in $player is activated, then the current button will display "DOWN". Otherwise, the button displays "UP". Note that the button with the ID "player1" must be an Event of Action -> Toggle (Action button is only available with an Elite license.)