Custom maxhotkeysperinterval for a command?

Get help with using AutoHotkey (v1.1 and older) and its commands and hotkeys
User avatar
Sp3ctre18
Posts: 3
Joined: 15 Aug 2017, 15:38
Contact:

Custom maxhotkeysperinterval for a command?

16 Aug 2017, 01:04

Hello all, AHK 1.1.26.00.

I get the point of HotkeyInterval and MaxHotkeysPerInterval to prevent troublesome loops.
However, instead of fiddling with values for the complete script, can I have a custom setting for specific commands?

My case:
I'm using autohotkey in conjunction with a program called intercept to program a 2nd and 3rd keyboard as keypads.

I've programmed the arrow keys as WMP controls; up/dwn is volume. Volume is something I'd like to be able to HOLD down instead of tap repeatedly, so this is a SAFE case where I want generous values, but still have a max interval of say, 5 seconds.
On the other hand, I would want a VERY RESTRICTIVE value for my program launchers - I wouldn't want a glitch to spam-open MS Word windows - or League of Legends instances - even for one second!

I tried the following as a quick test, but it didn't work, acting on the default values for both arrow keys.

Code: Select all

#HotkeyInterval 1000
#MaxHotkeysPerInterval 200
up::ControlSend, , {F9}, Windows Media Player
#HotkeyInterval 2000  ; This is  the default value (milliseconds)
#MaxHotkeysPerInterval 70 ; This is  the default value (milliseconds)
down::ControlSend, , {F8}, Windows Media Player
If this is not possible, is it in the pipeline? Any suggestions to work around this?
Thanks
Rhoi Fajardo
Composer of Film / Cinematic music
SoundCloud | YouTube

Founder of This Can Be Pronounced (TCBP):
A Project for Supporting & Advising on Foreign Language Studies

Website | Facebook | YouTube

Return to “Ask for Help (v1)”

Who is online

Users browsing this forum: doodles333 and 317 guests