Right click with input combo

Subforum for discussion and help with ScummVM's GP2X, GP2X Wiz and Caanoo ports

Moderator: ScummVM Team

Post Reply
User avatar
Yahiko_Yagami
Posts: 4
Joined: Wed Mar 03, 2010 10:59 am

Right click with input combo

Post by Yahiko_Yagami »

Hello, I'm a recent user of the GP2X WIZ port of ScummVM, and I'd like to request a new button combo for the mouse emulation.

As an addition to the current input configuration, which is almost perfect for the sort of games I play, it would be perfect to have the right click of the mouse mapped to yet another input combo. In this case, it would be the Left Trigger plus a touch in the touch screen, which I think will be an easy modification to the input handling source code.

This same combo for the right click was present in the Nintendo DS port when I tried it some time ago, and I found it the perfect control for games like Fate of Atlantis, so I hope it can also be added to the WIZ port.

I've added a new ticket to the feature requests of the project in SourceForge, as you suggest in your web. I would gladly modify the source code myself, but I don't know if it's available.

Thank you.
User avatar
DJWillis
ScummVM Porter
Posts: 174
Joined: Wed Oct 26, 2005 8:55 pm

Post by DJWillis »

Yahiko_Yagami,

Patches are always very welcome (the source is of course available, the GP2X Wiz code is included in the main ScummVM SVN source code). If you need help getting the source setup let me know (or find me on IRC #ScummVM on FreeNode)

There is room for improvement in the control system for ScummVM on the Wiz, if you are willing to help with this it would be much appreciated. For reference the current controller mapping is shown below (right click is mapped to X).

Controller mappings

Touch screen:
Touch: Move Pointer and Left click

Mouse emulation:

dPad: Move Pointer
B: Left click
X: Right click

Keyboard emulation:

Right Trigger: Return
Select: Escape
Y: Space Bar (Pause)
Menu: Game Menu (Save, Load, Quit etc.)
Volume Buttons: Increase and Decrease volume

Fancy button combos:

NOTE: To use button combos press and hold the Left Trigger then...

Right Trigger: Display Virtual Keyboard
Menu: Bring up the Global main menu for ScummVM
Select: Exit ScummVM.

Regards,

John
User avatar
Yahiko_Yagami
Posts: 4
Joined: Wed Mar 03, 2010 10:59 am

Post by Yahiko_Yagami »

Hi there, I didn't know that the source code was included in the general source code release.

I've downloaded and looked into it for a while, and I can't seem to find the specific event handling for the click on the touch screen.

Right now I'm at work, so I'll try again later this night.

Thank you.
User avatar
DJWillis
ScummVM Porter
Posts: 174
Joined: Wed Oct 26, 2005 8:55 pm

Post by DJWillis »

Dear Yahiko_Yagami,

backends/platform/gp2xwiz should give you all the source bits that you would need to look at ;). The event handling is in the appropriately named source files.

Feel free to ask me any more questions.

Regards,

John
User avatar
Yahiko_Yagami
Posts: 4
Joined: Wed Mar 03, 2010 10:59 am

Post by Yahiko_Yagami »

Yes, that's the directory I looked into. I've gone through the code several times, and I don't see any reference to the touch screen...

Is it possible that the SDL interpretes and maps the WIZ touch screen directly as mouse input? I am only guessing, since I still haven't installed the development environment, and I obviously have no experience developing on WIZ.

If that's what the SDL does in the WIZ, if it maps the click on the touch screen as a left button click on the mouse, I think I know how to include the combo I mentioned :).

What SDK are you using to compile the code? I'd like to use the same, to avoid any unnecesary problems related to the compiler.

Thank you.
User avatar
Yahiko_Yagami
Posts: 4
Joined: Wed Mar 03, 2010 10:59 am

Post by Yahiko_Yagami »

Hi again, I've downloaded and installed the open2x toolchain, as that is the one used in the sh scripts. Now, when I try to run the config.sh script, it stops with an error of SDL not found.

Which version are you using of the libraries? Should I get the last SVN version, or one of the prebuilt versions?

Thank you.
Post Reply