0494

From GTAMods Wiki
Revision as of 20:18, 13 December 2007 by Spaceeinstein (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

0494=5,%1h% %2d% %3d% %4d% %5d%
Description: Gets the joystick data
Parameter 1: Controller number (usually 0)
Parameter 2: Value to store the integer
Parameter 3: Value to store the integer
Parameter 4: Value to store the integer
Parameter 5: Value to store the integer
Supports: GTA3, Vice City, San Andreas

Parameter 1 returns -128 when pressing the left button and 128 when pressing the right button.
Parameter 2 returns -128 when pressing the up button and 128 when pressing the down button.
Parameter 3 returns -128 when pressing the special control left button and 128 when pressing the special control right button.
Parameter 4 returns -128 when pressing the special control up button and 128 when pressing the special control down button.

This opcode is a useful alternate way of detecting certain keypresses.

Keywords

get, joystick