My game supports touchscreen, keyboard + mouse and the Xbox One controller and the input so far works properly. Now I also want to add a second layout for the gamepad the player can then pick in the settings, e.g.:

Layout 1: Fly up with "A", fly down with "B" (so two buttons)

Layout 2: Fly up with "LB", fly down with "LT" (LT uses an axis, not a button!)

With keyboard/touchscreen and gamepad input I was able to create two different inputs in Unity's InputManager for the same thing and they would then trigger depending on which input device you're using.

I thought about adding a bool for the layouts and checking it every time a button is pressed but that sounds more like a quick and dirty solution. Descriptions of InputManagers I've found so far make it sound like they're used for rebinding keys or to support different gamepads (e.g. Xbox One and PS4), which I don't want/need (plus, these InputManagers are usually pretty expensive).

How do you handle actual different layouts that use the same buttons/axis for different things, especially with something using a button in the first layout and an axis in the second?

Your Answer


By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Browse other questions tagged or ask your own question.