Page 1 of 1

Change button mapping xinput controller

Posted: 04 Feb 2017, 13:11
by gaspard
Is there a way to reconfigure the button mapping that the game automatically gives you for xinput controllers? I tried with the "pad-map" command on the ons.cfg but it didn't do anything.
Thanks

Re: Change button mapping xinput controller

Posted: 04 Feb 2017, 23:05
by vit9696
Of course there is, and pad-map should actually do the trick. Could you tell me how you tried using pad-map?
So far I do not see a reason why would it fail unfortunately.

Re: Change button mapping xinput controller

Posted: 05 Feb 2017, 01:23
by gaspard
Well at first I just tried:
pad-map=-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1
or just giving value to a few buttons at time.

But strangely enough I just tried again and it suddenly started working, even though I thought I did the same thing before! :?

However with the example above while it disables the non-directional buttons successfully, it still recognizes the d-pad and the analog sticks (I want to disable all controls to use the JoyToKey program instead, while keeping the rumble).

Re: Change button mapping xinput controller

Posted: 05 Feb 2017, 01:33
by vit9696
Well, this is by design, because the analogue buttons cannot be remapped without losing data. And for sure they are not meant to be mapped anywhere else.

More importantly is why would you need anything like JoyToKey. Of course we do not try to prevent users from using weird stuff like that but it is certainly not supported. Feels like http://xyproblem.info to me.

Re: Change button mapping xinput controller

Posted: 05 Feb 2017, 02:34
by gaspard
Yeah I know it seems weird, I guess it needs a little clarification. It is to bypass the automode turn off on click (which I asked in the previous thread) by mapping the mouse wheel (which preserves automode) to the controller using JoyToKey.

This workaround seems to be good enough for now as long as I don't touch the D-pad (which could not be disabled) or analog sticks on automode. When the update comes with the ons.cfg option to make clicks preserve automode that Knox mentioned in the other thread then JoyToKey will no longer be necessary, but for now I guess I'll have to stick with it :lol:

Ps. I also wanted to change some mappings so my original question was valid at first, even though it somehow resolved by itself

Re: Change button mapping xinput controller

Posted: 05 Feb 2017, 12:40
by vit9696
Ah, I see now. Makes sense for me. We might consider providing mapping for hats and d-pad in the future (as extra number pad-map), but I am not too sure at the moment.

Re: Change button mapping xinput controller

Posted: 05 Feb 2017, 13:54
by gaspard
Cool, eagerly awaiting next releases, thanks for your help! :)