UInputMan:KeyPressed

From Data Realms Wiki

Revision as of 16:44, 7 October 2009 by DrLuke (Talk)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search
Function
SyntaxUInputMan:KeyPressed( Number )
Description:
If a key has been pressed that sim update the function returns true, else the function returns false. See the Keylist for the keys' numbers.
ReturnsBoolean




Example
DescriptionPrints whether a key has been pressed or not.
Code
  1. if UInputMan:KeyPressed(23) then print(1) else print (0) end
Output1 if "W" has been pressed, 0 if not.
Personal tools