Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ability to specify XInput DeviceSubType for Control Schemes #738

Closed
mdsitton opened this issue Jul 28, 2019 · 1 comment
Closed

Ability to specify XInput DeviceSubType for Control Schemes #738

mdsitton opened this issue Jul 28, 2019 · 1 comment
Labels

Comments

@mdsitton
Copy link

I am a developer of a popular rhythm game Clone Hero, and we are investigating switching to the new input system however we need support for XInput DeviceSubType for ControlSchemes to be able to differentiate the guitar controllers from normal xinput gamepads.

@Rene-Damm
Copy link
Contributor

Add this somewhere in your startup (e.g. in some InitializeOnLoad code)

InputSystem.RegisterLayout(@"
    {
        ""name"" : ""Guitar"",
        ""extend"" : ""XInputControllerWindows"",
        ""device"" : {
            ""interface"" : ""XInput"",
            ""capabilities"" : [ { ""path"" : ""subType"", ""value"" : ""6"" } ]
        }
    }
");

This should do the trick. There should be a new "Guitar" layout under XInputController in the control picker. Let me know how it goes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants