Interfaces
IControlService
Used to register keybindings.
Methods
RegisterKeybind
Registers a method to be ran on keybind press.
Parameters
| Name | Type | Description |
|---|---|---|
| id | string | The id of this keybind. |
| key | string | The key of this keybind. |
| title | string | The description of this keybind. |
| onPress | Action<FPlayer> | The method that'll be invoked on press. |
| onRelease | Action<FPlayer> | The method that'll be invoked on release. |
RegisterMomentaryKeybind
Registers a method to be ran on keybind press. A momentary keybind also supports a release method to be ran on key release.
Parameters
| Name | Type | Description |
|---|---|---|
| id | string | The id of this keybind. |
| key | string | The key of this keybind. |
| title | string | The description of this keybind. |
| timeToHoldInMs | int | The time to hold in ms. |
| onPress | Action<FPlayer> | The method that'll be invoked on press. |
| onRelease | Action<FPlayer> | The method that'll be invoked on release. |
RegisterMouseKeybind
Registers a method to be ran on keybind press.
Parameters
| Name | Type | Description |
|---|---|---|
| id | string | The id of this keybind. |
| key | string | The key of this keybind. |
| title | string | The description of this keybind. |
| onPress | Action<FPlayer> | The method that'll be invoked on press. |
| onRelease | Action<FPlayer> | The method that'll be invoked on release. |