[<<Previous Entry]
[^^Up^^]
[Next Entry>>]
[Menu]
[About The Guide]
Function: JoyX()
This function will return the current X position of the stick.
When positioned at the complete left, this should return 0 or
values close to that, at the right it should return some maximum
value (depending on the speed of the machine), and in the middle
it should return about half of right's value. Your program should
thus first initialise some machine dependant values. Once
understood how it works, it is easy to figure out the rest.
Syntax: JoyX([nJoyNr]) --> nX
Arguments: JoyStick #1 if none is supplied, otherwise 0 indicates #1,
1 indicates joystick #2.
Returns: A numerical, generally between 0 and . 255, machine
dependant.
Usage: * Assuming JoyMiddle is some initialised variable ..
if JoyX() < JoyMiddleX
MoveRight()
endif
See Also:
JoyPress()
JoyY()
This page created by ng2html v1.05, the Norton guide to HTML conversion utility.
Written by Dave Pearson