Input
Inherits Instance.
A service: the global Input is the game's one Input.
Properties
| Name | Type | Notes |
|---|---|---|
GamepadEnabled | boolean | Read-only. |
KeyboardEnabled | boolean | Read-only. |
MouseEnabled | boolean | Read-only. |
TouchEnabled | boolean | Read-only. |
Methods
GetConnectedGamepads(): {EnumUserInputType}GetGamepadConnected(gamepad: EnumUserInputType): booleanGetGamepadState(gamepad: EnumUserInputType): {InputObject}GetKeysPressed(): {InputObject}GetMouseLocation(): Vector2IsGamepadButtonDown(gamepad: EnumUserInputType, button: EnumKeyCode): booleanIsKeyDown(keyCode: EnumKeyCode): booleanIsMouseButtonPressed(mouseButton: EnumUserInputType): boolean
Events
GamepadConnected, whose handlers get(EnumUserInputType).GamepadDisconnected, whose handlers get(EnumUserInputType).InputBegan, whose handlers get(InputObject, boolean).InputChanged, whose handlers get(InputObject, boolean).InputEnded, whose handlers get(InputObject, boolean).TouchEnded, whose handlers get(InputObject, boolean).TouchMoved, whose handlers get(InputObject, boolean).TouchStarted, whose handlers get(InputObject, boolean).TouchTap, whose handlers get({Vector2}, boolean).
Inherited
From Instance: AddTag, AncestryChanged, Archivable, AttributeChanged, Changed, ChildAdded, ChildRemoved, ClassName, ClearAllChildren, Clone, DescendantAdded, DescendantRemoving, Destroy, Destroying, FindFirstAncestor, FindFirstAncestorOfClass, FindFirstAncestorWhichIsA, FindFirstChild, FindFirstChildOfClass, FindFirstChildWhichIsA, GetAttribute, GetAttributeChangedSignal, GetAttributes, GetChildren, GetDescendants, GetFullName, GetPropertyChangedSignal, GetTags, HasTag, IsA, IsAncestorOf, IsDescendantOf, IsPropertyModified, Name, Parent, QueryDescendants, RemoveTag, ResetPropertyToDefault, SetAttribute, WaitForChild.