The NEW Build Your Own Arcade Controls

Front End Support => MaLa Frontend => Topic started by: play2dxtreme on January 14, 2010, 12:48:53 pm

Title: Assigning multiple key combinations in Mala Controller Options?
Post by: play2dxtreme on January 14, 2010, 12:48:53 pm
Can more than one key input or a combination of key inputs be assigned to 'START' or 'EXIT' a game in Mala's contoller option menu?  This would reduce the chance of accidently exiting a game during play by accidently hitting a single button (when 'Exit' would require 2 keys pressed simultaneously).
Title: Re: Assigning multiple key combinations in Mala Controller Options?
Post by: loadman on January 15, 2010, 09:10:09 pm
You can assign a 'shift' key to achieve this
Title: Re: Assigning multiple key combinations in Mala Controller Options?
Post by: play2dxtreme on January 20, 2010, 09:28:09 am
It seems as if that is the only way.  I appreciate your help.
Title: Re: Assigning multiple key combinations in Mala Controller Options?
Post by: loadman on January 21, 2010, 09:07:54 pm
It seems as if that is the only way.  I appreciate your help.

The 'shift' key itself can be allocated too
Title: Re: Assigning multiple key combinations in Mala Controller Options?
Post by: mh12 on January 22, 2010, 08:47:22 am
i was wondering a similar thing...

is there any way to make 2 individual keys do the same thing? i was considering having both of my joysticks able to scroll the game lists (so up=arrow up OR y), but it doesn't seem possible.
Title: Re: Assigning multiple key combinations in Mala Controller Options?
Post by: play2dxtreme on January 25, 2010, 10:51:14 am
MH12,
You are absolutely right, it would be a huge plus to give either the PLAYER 1 or PLAYER 2 side (in an arcade cabinet) the ability to navigate the MALA menu with their own buttons/keys.
Title: Re: Assigning multiple key combinations in Mala Controller Options?
Post by: Neverending Project on January 25, 2010, 11:58:38 am
is there any way to make 2 individual keys do the same thing? i was considering having both of my joysticks able to scroll the game lists (so up=arrow up OR y), but it doesn't seem possible.

Check out this thread for a setting up two joysticks to control the menu movement:
http://forum.arcadecontrols.com/index.php?topic=79752.0 (http://forum.arcadecontrols.com/index.php?topic=79752.0)
Title: Re: Assigning multiple key combinations in Mala Controller Options?
Post by: mh12 on January 25, 2010, 02:26:45 pm
is there any way to make 2 individual keys do the same thing? i was considering having both of my joysticks able to scroll the game lists (so up=arrow up OR y), but it doesn't seem possible.

Check out this thread for a setting up two joysticks to control the menu movement:
http://forum.arcadecontrols.com/index.php?topic=79752.0 (http://forum.arcadecontrols.com/index.php?topic=79752.0)

that's cool. i should've been clearer though: i said "keys" because i'm using a J-Pac. No way to assign to assign two different "keystrokes" to the same function, i guess. Not a big deal.
Title: Re: Assigning multiple key combinations in Mala Controller Options?
Post by: Neverending Project on January 25, 2010, 04:23:41 pm
Ah, I see. Two other options come to mind.

1) You could use the encode-on-the-fly feature of the JPAC. Make a default configuration where both joysticks are programed to send the same keystroke for up, down, left, right. Every time Mala launches a game it will load an emu-specific config with the correct joystick directions, and then will load this default when it returns to Mala.

2) Use something like AutoHotKey to remap one of the joysticks keys. Although I have never done it, I think you can have it only map the keys in Mala, and not in other programs.
Title: Re: Assigning multiple key combinations in Mala Controller Options?
Post by: play2dxtreme on January 25, 2010, 04:32:45 pm
MH12,
It seems as you and I are looking for the same solution.  I am also using a J-Pac to encode the button and joystick inputs from my cabinet.  So, where Player #1 joystick uses the UP, DOWN, LEFT, and RIGHT keyboard keys to navigate; Player #2 joystick is set to use e.g. the D, R, G, & C keys for movement.  Therefore, if the UP & DOWN keys scrolls through the game list for player #1, we would want to be able to scroll through the game list with R & C keys for player #2.  I am only looking for this capability in the Mala Frontend Menu section where you scroll/navigate through the lists of emulators and games.

I see where Mala allows dual control in the 'JoyStick/GamePad' setup but, I don't see that ability under the 'Keyboard' setup.  Please correct me if I am wrong.
Title: Re: Assigning multiple key combinations in Mala Controller Options?
Post by: play2dxtreme on January 25, 2010, 04:39:45 pm
Neverending Project,
I will see if the first option works.
Thank you.
Title: Re: Assigning multiple key combinations in Mala Controller Options?
Post by: mh12 on January 25, 2010, 09:26:02 pm
i've been messing with Autohotkey lately. i wasn't aware you could make hotkeys program-specific. i should do that with some scripts i've written. and it would make doing this for MaLa simple.
cheers
Title: Re: Assigning multiple key combinations in Mala Controller Options?
Post by: Stormrider on January 26, 2010, 03:27:32 pm
That's easy. Look at these examples. The first one remaps a joy button to send esc, to bring up the quit dialogue. The second one, autocancels the quit dialogue after a while. Take a look at the Autohotkey help to find out the names of the keys. Also, use Autoit3 Window Spy (included with Autohotkey) to identify the current window. As you can see, in the first example, the hotkey only works while in the MaLa mainmenu. In the second example, the code only works while in the quit dialogue. Every window has a name that identifies it. Just place the mouse pointer over it and watch the spy window.

#IfWinActive MaLa ahk_class TfrmMain
~1joy9:: // mala start button
send, {Esc}
sleep 300

#IfWinActive ahk_class TfrmExit
SetTimer, idleexit, 8000
idleexit:
IfWinActive ahk_class TfrmExit
If (A_TimeIdle > 9000)
send, {Esc}
return