R1PeR / MouseToVJoy

Simple application that converts mouse/keyboard input to vjoy output, created using vjoyinterface and winapi32. Useful for games like Assetto Corsa, Live For Speed, Rfactor. Requires installed version of VJoy 2.1.8. As for version 1.7, Forcefeedback works with Constant Effect and Periodic Effect. Tested on Live for Speed and Rfactor and Assetto Corsa.
https://r1per.itch.io/mtvj
MIT License
26 stars 11 forks source link

Custom Button #14

Open rafadsm opened 5 years ago

rafadsm commented 5 years ago

How i can add custom buttons?

It seems kind of confusing to me, I didn't quite understand that LONG lButtons; // 32 buttons: 0x00000001 means button1 is pressed, 0x80000000 -> button32 is pressed

I tried to follow that https://github.com/R1PeR/MouseToVJoy/blob/master/MouseToVJoy/vJoy.cpp#L90 But I didn't understand the hexadecimal of "else"

xCuri0 commented 4 years ago

Do lButtons &= (1 << BUTTONNUMBER); to release and lButtons |= (1 << BUTTONNUMBER); to press @rafadsm