Hard Light Productions Forums

Modding, Mission Design, and Coding => FS2 Open Coding - The Source Code Project (SCP) => Topic started by: MP-Ryan on September 04, 2010, 03:10:43 pm

Title: Any way to get FSO to recognize mouse buttons 4 and 5 without emulation?
Post by: MP-Ryan on September 04, 2010, 03:10:43 pm
Right now, I have to set mouse buttons 4 and 5 to a key through emulation to have them work in game.  Is there any way to get the game to recognize them?  (Feature request?)
Title: Re: Any way to get FSO to recognize mouse buttons 4 and 5 without emulation?
Post by: jr2 on September 04, 2010, 03:12:08 pm
IIRC PPJoy can do that by assigning buttons to keyboard keys, but I'm not sure.
Title: Re: Any way to get FSO to recognize mouse buttons 4 and 5 without emulation?
Post by: MP-Ryan on September 04, 2010, 03:16:31 pm
IIRC PPJoy can do that by assigning buttons to keyboard keys, but I'm not sure.

I can do that already.

What I'm looking to find out, or see if it an be added, is for the game to recognize buttons 4 and 5 as separate buttons WITHOUT mapping them to a keyboard key.  Unfortunately, while FSO easily recognizes mapped keyboard keys on mouse buttons, some other software does not, and the application-specific emulation in SetPoint doesn't seem to work with FSO.
Title: Re: Any way to get FSO to recognize mouse buttons 4 and 5 without emulation?
Post by: FUBAR-BDHR on September 04, 2010, 03:17:59 pm
Wait for new pilot code would be my guess.
Title: Re: Any way to get FSO to recognize mouse buttons 4 and 5 without emulation?
Post by: taylor on September 04, 2010, 03:47:21 pm
Even with new pilot code there are platform issues that have to be dealt with.  SDL for instance uses mouse buttons 4 & 5 as the mouse wheel (up and down, respectively), whereas Windows treats the mouse wheel as an axis.  It can still be done with some hacks to the Windows code to make it see the mouse wheel as buttons and then have the extra buttons be 6 and up.  The easiest thing would probably just be to wait until the Windows side of things moves to SDL and then there won't be any weird hacks involved to support all mouse buttons and the wheel.

There is also an issue of the mouse and joystick buttons overlapping as far as the control code goes.  These will need to be separated before any real changes can be made to support additional mouse functionality.

Either way, the new pilot code is set up to support this, so it will all be ready once the rest of the code is changed to properly support the mouse.