Autohotkey Script: Two skills assigned to one key

Hello!

With my Commando I would like to use Canister Bomb AND Flashbang on the right mouse button (RMB) because I don’t like clicking too many keys.

I understand you can do stuff like that with Autohotkey but I have no idea how to write such a script.

Could someone do that for me or give an example on how to do it?

Canister bomb has a 8 second skill recharge, Flashbang only 1 second.
If both skills are “ready to use”, clicking on RMB should activate them both (almost) simultaneously.
If Canister bomb is still recharging, RMB should only activate Flashbang.

Thank you very much in advance!

In case anybody is wondering, this short script does make it work:

RButton:: send, {RButton}{0}
return

Skill 1 stays assigned to RButton, Skill 2 is assigned to 0.
Now if you press RButton the script will actually press RButton AND 0 :wink:

(You can choose any other keys as well in the script, but be aware: If you command e.g. your RButton not to actually press RButton, you will loose your actual right-click! (As long as the script is active))

Hey thanks, this sounds interesting (not to mention useful for a middle-aged dude with poor dexterity like myself).

Sorry for the incredibly stupid question, though. How do you implement this script? Do you have to add it to a text file, ini file or do you type it into a console during the game?

You can copy-paste it in a regular notepad, and save it as an AutoHotKey Script. Then to launch it, right-click and select “run with AHK”. (or something like that, I haven’t used it in a while)

Oh, OK. Thanks!

After installing AutoHotkey you can just

  1. Rightclick on the desktop–>new–>AutoHotkey script
  2. Rightclick on the script–>edit script
  3. Delete everything inside
  4. Copy&Paste the commands in there
  5. Save & close
  6. Rightclick on the script–>Run Script

Now you have that little “H” in your system tray.
In order to end it just rightclick–>exit

hello please answer you start script form scratch or just edit script???

Follow his instructions, and you will find the “NEW”.