GameInputManager.WaitForElement
From Xojo Documentation
Method
This method is only available on macOS and Linux platforms. For cross-platform compatibility, use #If...#Endif with the Target... specifiers to make sure you will not attempt to use this method on an incompatible platform. |
GameInputManager.WaitForElement(timeout as Single) As GameInputElement
Supported for all project types and targets.
Supported for all project types and targets.
Returns the GameInputElement the user pressed. It waits for an element to change on any input device. Timeout is in seconds.
Example
The following example determines which element the user is using as the Fire key. It assumes that there is a global property, mManager as GameInputManager, and mFireButton as a GameInputElement.