fyhuang / enjoy2

Transform joystick input into keyboard and mouse events (OSX)
MIT License
363 stars 55 forks source link

Issue: Xbox Triggers #43

Open MoonPhoenix83 opened 4 years ago

MoonPhoenix83 commented 4 years ago

I am using Enjoy2 to play minecraft with my Xbox One S controller. However, it seems that the triggers cannot be remapped and are not highlighted when I press them. what do I do?

carcamx052 commented 3 years ago

I'm having the same problem, and I haven't been able to find any fixes. Its been over a year so I was wondering if you have?

Tryptame commented 2 years ago

700 some days later, still no fix. I just want to play some ps3 games man...

Nicholas-Swift commented 1 year ago

Ok I think I have a resolution for this. It looks like the triggers are just getting skipped when trying to figure out all the buttons. Can resolve this through changing line 78 in Joystick.m to if ((usage >= 0x30 && usage < 0x36) || (usage == 196 || usage == 197)) {, to be able to register triggers as well.

Found this by adding NSLog around the usage area and seeing that 2 actions were skipped being mapped. Printed out the usage int, found 196 and 197.

@fyhuang, I'm sure there's a more elegant solution, but something you want to update Enjoy2 with?

sdw82538253 commented 1 year ago

@Nicholas-Swift How do I change the line 78 in Joystick.m to let enjoy2 recognize my trigger?

fyhuang commented 1 year ago

@Nicholas-Swift Apologies, I'm not really maintaining this repo. But if you send me a PR I'm happy to merge it!