KEYSTATE
This command will return an integer value of one if the key specified by the scancode is pressed, otherwise zero will be returned.
Return Integer=KEYSTATE(Scancode)
Scancode
Integer
The scan code number to test
A one if the key specified by the scancode is pressed, otherwise zero will be returned
The scancode value is the raw value assigned to the key of the keyboard device and very often is ordered sequentially from the top left of the keyboard to the bottom right.
cls
do
if upkey()=1 then print "upkey()"
if downkey()=1 then print "downkey()"
if leftkey()=1 then print "leftkey()"
if rightkey()=1 then print "rightkey()"
if keystate(17)=1 then print "W up"
if keystate(31)=1 then print "S down"
if keystate(30)=1 then print "A left"
if keystate(32)=1 then print "D right"
loop
end
INPUT Commands Menu
Index