Adapt Controls to the Active Device
Show a keyboard or gamepad prompt and let the player adjust camera sensitivity. Start with a working Input Setup with mappings for the devices you want to test.
Update the prompt
Create the prompt widget for the local player. From the player's Input Manager read Get Player Input Mode for the initial prompt and bind a custom event to On Input Mode Changed. Use a fallback prompt until a device has been detected.
Send the initial value and the event's new tag to the same widget function. Choose keyboard artwork for
Input.Mode.KeyboardAndMouse, gamepad artwork forInput.Mode.Gamepad, and touch controls forInput.Mode.Touch. Remove the binding when disposing of the widget.
Apply a saved preference
Enable the settings classes from Build a Key Remapping Menu. On the mouse Look mapping add Mouse Sensitivity. On its stick mapping add Gamepad Sensitivity. Use Invert XY Axis on mappings where the player can reverse an axis.
On your slider's change event, get Input User Settings from the manager. Call Set Mouse Sensitivity X and Set Mouse Sensitivity Y, or Set Gamepad Sensitivity for the stick. Bind an inversion checkbox to Set Invert Vertical Axis. Call Save Input Settings on Apply.
Try It in Play
Press a mapped keyboard key, then a mapped gamepad button. The prompt should change on each switch. Change the mouse slider and move the mouse the same distance again. The camera should turn a different amount while stick sensitivity stays the same. If the prompt stays put, try a mapped action that produces a nonzero value. If the slider changes but the camera feels identical, inspect the modifiers on the active mapping.