ATTENTION: You are viewing a page formatted for mobile devices; to view the full web page, click HERE. Software > Coding Snack Guidelines

AutoHotKey script to assign mouse button to Esc playing Gems of War


I could try to learn how to do this myself, but it seems a waste of time when I'm sure there's people here who know how to do this in a few minutes.  Here's hoping!

The idea is to use a program like AutoHotKey (other options are welcome) to provide an alternative way of closing dialog boxes in the game Gems of War, launched from Steam. Basically, the near thumb button on my mouse will go Back in browsers, and I want it to do the same in Gems of War.

Here's the technical detail (please ask if I've missed anything):
- Assign near mouse thumb button to generate Esc-key keystroke.
- Diablo III designates this mouse button as Mouse4.
- Only active while GemsOfWar.exe is running, and preferably only while in the foreground.

Thanks in advance!

Doesn't your mouse supplier provide software for that? Most major brands do, AFAIK

I have no way of testing this since I do not have that game, but you can try the following:

--- Code: Autohotkey ---#IfWinActive, ahk_exe GemsOfWar.exe{    XButton1::Esc  ; XButton1 is typically the fourth mouse button.  XButton2 is typically the fifth mouse button.}#IfWinActive
Also, keep in mind that many games try to detect this sort of behaviour and will actively prevent it from working.

Many games actively sense if AutoHotkey is working period.  If you can get your mouse software to remap, that would be your best option.  What kind of mouse do you have?

Thanks heaps!

I'll definitely try both.

My mouse is a Cougar (German brand).  I didn't install the software because my previous mouse's Razer software did little more than make it *too* sensitive.  Maybe I now have reason to!


[0] Message Index

Go to full version