OptionalisInternalConstructor: booleanThe current profile to dynamically remap buttons to other button codes.
Sets repeat interval for held virtual buttons. Buttons will be continously triggered in interval increments as long as they button is being held.
Gets a previously registered virtual button with the specified name and category.
Unique name used to access the virtual button.
Optionalcategory: stringThe category of the button, if undefined, the default category will be used.
The axis or null if not registered.
Gets a previously registered virtual button with the specified name and category.
Unique name used to access the virtual button.
Optionalcategory: stringThe category of the button, if undefined, the default category will be used.
true upon success.
Registers the virtual axis.
The Virtual Axis to register.
The scope of the registration. Used to batch unregister if the scope is removed.
The axis or null if not, or already registered.
Registers a new virtual axis.
Unique name used to access the virtualAxis.
The scope of the registration. Used to batch unregister if the scope is removed.
Type of physical axis to map to.
OptionaldeadZone: numberOptionalsensitivity: numberHigher sensitivity means the axis will more easily reach its maximum values.
Optionalinvert: booleanShould axis values be inverted.
Optionalcategory: stringThe category of the axis, if undefined, the default category will be used.
The axis or null if not, or already registered.
Registers the virtual button.
The Virtual Button to register.
The scope of the registration. Used to batch unregister if the scope is removed.
The newly created button or null if failed, or if it was already registered.
Registers a new virtual button, or updates a previously registered button.
Unique name used to access the virtual button. Must be unique in the category.
The scope of the registration. Used to batch unregister if the scope is removed.
Physical buttons the virtual button is triggered by.
Optionalmodifiers: EnumValue<ButtonModifier, number>Modifiers required to be pressed with the physical button to trigger the virtual button.
Optionalrepeatable: booleanIf true, the virtual button events will be sent continually while the physical button is being held.
Optionalcategory: stringThe category of the button, if undefined, the default category will be used.
The newly created button or null if failed, or if it was already registered.
Unregisters a virtual virtualAxis with the specified name. You will no longer be able to retrieve valid values for that virtualAxis.
Unique name used to access the virtual axis.
Optionalcategory: stringThe category of the axis, if undefined, the default category will be used.
true if the axis was unregistered.
Unregisters a virtual virtualAxis with the specified name. You will no longer be able to retrieve valid values for that virtualAxis.
The virtual axis.
true if the axis was unregistered.
Unregisters all virtual buttons with the matching name and category for all button codes. Events will no longer be generated
for that button.
Unique name used to access the virtual button.
Optionalcategory: stringThe category of the button, if undefined, the default category will be used.
true if the buttons was unregistered.
Unregisters the virtual button. Events will no longer be generated for that button.
The virtual button.
true if the buttons was unregistered.
The InputConfiguration class enables developers to create virtual HID controls that map to physical devices. The abstraction makes it easy to dynamically change the behavior, or the button codes that trigger the input.
An InputConfigurationProfile can be assigned to the configuration, to provides a way to remap virtual buttons to other button codes after their creation. This allows developers to provide their users with a way to remap the stock button layout to other physical buttons. The profile can be trivially serialized as other types, and applied upon loading it.