Build Your Own Arcade Controls Forum

Main => Software Forum => Topic started by: knightrdrx on January 24, 2015, 02:06:53 pm

Title: does anyone use autohotkeys?
Post by: knightrdrx on January 24, 2015, 02:06:53 pm
Any cons to using autohotkeys software?..i guess it would be running on start up.  It can help eliminate having to pull out the keyboard to get to the escape or enter key.  I could control the play controls of windows media player with the x-arcade without using the trackball and side button...or should i just reprogram some of the x-arcade?
Title: Re: does anyone use autohotkeys?
Post by: keilmillerjr on January 24, 2015, 02:28:46 pm
The only con I've found so far is its inability to multithread, which I know there are a few alternatives to overcome this limitation. If a hotkey sequence is initiated while another hotkey sequence is running, it puts the first on hold. Definitely undesirable but not the end of the world.
Title: Re: does anyone use autohotkeys?
Post by: EMDB on January 24, 2015, 03:54:12 pm
The only con I've found so far is its inability to multithread, which I know there are a few alternatives to overcome this limitation. If a hotkey sequence is initiated while another hotkey sequence is running, it puts the first on hold. Definitely undesirable but not the end of the world.
It doesn't. I have a global F12 -> audio mute toggle script running while every emulator has it's own (e.g. ESC -> Alt-F4). The work just fine along...
Title: Re: does anyone use autohotkeys?
Post by: keilmillerjr on January 24, 2015, 05:02:45 pm
The only con I've found so far is its inability to multithread, which I know there are a few alternatives to overcome this limitation. If a hotkey sequence is initiated while another hotkey sequence is running, it puts the first on hold. Definitely undesirable but not the end of the world.
It doesn't. I have a global F12 -> audio mute toggle script running while every emulator has it's own (e.g. ESC -> Alt-F4). The work just fine along...

I don't think you understand. Autohotkey does not multithread. So the same autohotkey app can not execute two different hotkeys at the same time. Press a to execute a:: code and the. Press b to execute b:: code, autohotkey will put a on pause and resume when b is done executing. Did rephrasing it make more sense?
Title: Re: does anyone use autohotkeys?
Post by: Louis Tully on January 24, 2015, 05:09:34 pm
.
Title: Re: does anyone use autohotkeys?
Post by: EMDB on January 24, 2015, 05:20:09 pm
The only con I've found so far is its inability to multithread, which I know there are a few alternatives to overcome this limitation. If a hotkey sequence is initiated while another hotkey sequence is running, it puts the first on hold. Definitely undesirable but not the end of the world.
It doesn't. I have a global F12 -> audio mute toggle script running while every emulator has it's own (e.g. ESC -> Alt-F4). The work just fine along...

I don't think you understand. Autohotkey does not multithread. So the same autohotkey app can not execute two different hotkeys at the same time. Press a to execute a:: code and the. Press b to execute b:: code, autohotkey will put a on pause and resume when b is done executing. Did rephrasing it make more sense?
I still don't understand. You want two scripts executed in parallel within a single compiled executable?
Title: Re: does anyone use autohotkeys?
Post by: BadMouth on January 24, 2015, 05:57:53 pm
I'm picky about having stuff run in the background, but I install autohotkey on every emulator system I build.
It can be the solution to many problems getting emulators to launch and play correctly.
I have no hesitation recommending it and running a script at startup.

I had an AHK script that ran all the time on my old x-arcade setup.
The tankstick has an unused input on the trackball harness that posts as the middle mouse button.
So I added a red exit button in the upper left of the CP and connected it to this unused input.
Then I had an AHK script post ESC when the middle mouse button was pressed (mbutton::ESC)

Worked like a charm on everything but MAME, but MAME allows you to remap the exit button to mbutton anyway.
Since MAME gets it's input directly, windows programs like AHK don't work with it.
Title: Re: does anyone use autohotkeys?
Post by: keilmillerjr on January 24, 2015, 07:01:30 pm
The only con I've found so far is its inability to multithread, which I know there are a few alternatives to overcome this limitation. If a hotkey sequence is initiated while another hotkey sequence is running, it puts the first on hold. Definitely undesirable but not the end of the world.
It doesn't. I have a global F12 -> audio mute toggle script running while every emulator has it's own (e.g. ESC -> Alt-F4). The work just fine along...

I don't think you understand. Autohotkey does not multithread. So the same autohotkey app can not execute two different hotkeys at the same time. Press a to execute a:: code and the. Press b to execute b:: code, autohotkey will put a on pause and resume when b is done executing. Did rephrasing it make more sense?
I still don't understand. You want two scripts executed in parallel within a single compiled executable?

Yes. Code within same ahk script/exe simultaneously running. Read the docs and maybe they will make more sense.

https://www.autohotkey.com/docs/misc/Threads.htm (https://www.autohotkey.com/docs/misc/Threads.htm)
Title: Re: does anyone use autohotkeys?
Post by: keilmillerjr on January 24, 2015, 07:06:32 pm
I'm picky about having stuff run in the background, but I install autohotkey on every emulator system I build.
It can be the solution to many problems getting emulators to launch and play correctly.
I have no hesitation recommending it and running a script at startup.

I had an AHK script that ran all the time on my old x-arcade setup.
The tankstick has an unused input on the trackball harness that posts as the middle mouse button.
So I added a red exit button in the upper left of the CP and connected it to this unused input.
Then I had an AHK script post ESC when the middle mouse button was pressed (mbutton::ESC)

Worked like a charm on everything but MAME, but MAME allows you to remap the exit button to mbutton anyway.
Since MAME gets it's input directly, windows programs like AHK don't work with it.

Yes and no. You can compile mame to accept direct input, in turn allowing key presses to be intercepted and received from ahk. However, mame does accept window messages for pausing, closing, etc. So there are some things you can do with the precompiled version.

My app I'm almost ready to release takes advantage of these things. :) I just need to make a readme, license, and push to github/bintray.
Title: Re: does anyone use autohotkeys?
Post by: knightrdrx on January 26, 2015, 06:51:20 pm
that was a confusing discussion
Title: Re: does anyone use autohotkeys?
Post by: empardopo on January 27, 2015, 02:26:39 am
Any cons to using autohotkeys software?..i guess it would be running on start up.  It can help eliminate having to pull out the keyboard to get to the escape or enter key.  I could control the play controls of windows media player with the x-arcade without using the trackball and side button...or should i just reprogram some of the x-arcade?

Do you know my AllInOneFYC program? You could take a look!
Greetings!