Important Notice
The pages on this site contain documentation for very old MS-DOS software,
purely for historical purposes.
If you're looking for up-to-date documentation, particularly for programming,
you should not rely on the information found here, as it will be woefully
out of date.
STRIG Function Details
◄Summary► ◄Details► ◄Example► ◄Contents► ◄Index► ◄Back►
──────────────────────────────────────────────────────────────────────────────
STRIG(n%)
Usage Notes
■ The argument n% is an integer between 0 and 7 that indicates the
joystick and trigger to check. The following list describes the values
returned by the STRIG function for different values of n%:
Value
Argument Returned Description
════════ ════════ ═════════════════════════════════════════════════
0 -1 Joystick A's lower trigger was pressed since the
last STRIG(0) call
0 A's lower trigger was not pressed
1 -1 Joystick A's lower trigger is currently down
0 A's lower trigger is not down
2 -1 Joystick B's lower trigger was pressed since the
last STRIG(2) call
0 B's lower trigger was not pressed
3 -1 Joystick B's lower trigger is currently down
0 B's lower trigger is not down
4 -1 Joystick A's upper trigger was pressed since the
last STRIG(4) call
0 A's upper trigger was not pressed
5 -1 Joystick A's upper trigger is currently down
0 A's upper trigger is not down
6 -1 Joystick B's upper trigger was pressed since the
last STRIG(6) call
0 B's upper trigger was not pressed
7 -1 Joystick B's upper trigger is currently down
0 B's upper trigger is not down
■ You cannot use the STRIG function inside a joystick event trap, because
the trigger information used by STRIG function will not be available for
ON STRIG. See: ◄ON STRIG Statement►
■ In previous versions of Microsoft Basic, the statement STRIG ON enabled
testing of the joystick triggers; STRIG OFF disabled joystick trigger
testing. The current version of Basic ignores STRIG ON and STRIG OFF
statements.
■ The earlier STRIG ON and STRIG OFF should not be confused with the
current STRIG(n%) ON, STRIG(n%) OFF, and STRIG(n%) STOP statements.
Note: The STRIG(n%) statements enable, disable, and inhibit trapping of
joystick events.