Controller Presets
Stores native and custom controller presets that can be used in UI.
Preset Manager Workflow
This scriptable object is responsible for storing controller presets. Xbox, DualSense, and keyboard/mouse controllers are natively supported out of the box, but you can also add custom presets.
Preset Workflow
This scriptable object is responsible of storing the preset data. Some controllers have a different type of button scheme/layout compared to others. For example, Xbox has ‘B’ on the east side, while DualSense has ‘Circle’. Controller Preset solves this problem by working with IDs instead of mapping, so you can show unique icon or text based on controller and ID value. This feature is mostly used with the ‘Hotkey Event’ component.
Adding Custom Presets
To create a new custom preset, you can follow these steps:
- Duplicate one of the existing preset (e.g. Xbox)
- Change the filename to avoid confusion
- Set the controller name (as an input device supported by Unity Input System*)
- Add your preset to the ‘Custom Presets’ list (via Preset Manager)
* You can call Debug.Log(UnityEngine.InputSystem.Gamepad.current.displayName); at runtime to find the active controller name.
How can we help?
A premium WordPress theme with an integrated Knowledge Base,
providing 24/7 community-based support.