First post, by michaelmak
- Rank
- Newbie
Hi all,
When I play the Xenon2 games, I need to press and release the space bar repeatedly to shoot the enemies.
How can I make the space bar become an auto fire key by keyboard mapper ?
Thanks.
Michael
Hi all,
When I play the Xenon2 games, I need to press and release the space bar repeatedly to shoot the enemies.
How can I make the space bar become an auto fire key by keyboard mapper ?
Thanks.
Michael
I remember someone asking this same question recarding the same game on a different forums. Let's see...
Url removed, abandonware site
Hi Zirkoni,
I have already read that forums before I post this question here.
But I still don't understand how to create the autofire key.
It seems that I need to write some program code to achieve my aim.
AutoHotkey is a program you install on you Windows PC: https://www.autohotkey.com/
It uses it's own script language to perform key mappings and other actions and can be used to do some quite complex tasks.
Fo Xenon 2 autofire the script I posted at Abandonia is enough:
$Space::
While GetKeyState("Space","p"){
Send {Space}
Sleep 10
}
return
Save that text in an AutoHotkey script (e.g. autofire.ahk) and run it with AutoHotkey. While the script is active keeping spacebar pressed fires once every 10 ms.
Hi Zirkoni,
I will study how to install and run the AutoHotkey.
But how can I stop this script when I exit from the DOSBox ?
You run Autohotkey in the background and you can set it to only run this script when Dosbox runs. It can probably even configured to only run when you play the game in Dosbox as Dosbox' titlebar shows that and Autohotkey can check for this.
Hi Dominus,
Thank you for your reply.
I guess that you mean I need to write a BAT file to start both DOSBox and Autohotkey.
Then I need to kill the Autohotkey process from Task Manager when I exit from the DOSBox.
I will study how to do it.
You can do all that with autohotkey. Start the script with dosbox (or rather a script converted to exe can start dosbox), exit when you exit Dosbox.
But my Autohotkey is rusty, seven years ago I switched to OS X but before I used Autohotkey for something like that.