Raw Key Modifier

Tests if a modifier key was held when a rawkey was typed


wasHeld = Raw Key Modifier Caps Lock
wasHeld = Raw Key Modifier Control
wasHeld = Raw Key Modifier Command
wasHeld = Raw Key Modifier Shift
wasHeld = Raw Key Modifier Option


Takes a rawkey as returned from the Keyboard Raw Key command and tests if the modifier key specified was being held when the key was typed.
A result of TRUE will be returned if the modifier was held, and FALSE if it wasn't.

TNT Basic does not differentiate between the left and right modifier keys, so if you have a left shift key and a right shift key on your keyboard, they will both test positive for the 'Raw Key Modifier Shift' command.

For more information on raw keys and working with the keyboard please refer to the Keyboard Input Guide.

See also the Keyboard Raw Key, Raw Key Char and Raw Key Scancode commands.

Table of contents