Code: Select all
#NoEnv ; Recommended for performance and compatibility with future AutoHotkey releases.
; #Warn ; Enable warnings to assist with detecting common errors.
SendMode Input ; Recommended for new scripts due to its superior speed and reliability.
SetWorkingDir %A_ScriptDir% ; Ensures a consistent starting directory.
F4::
bToggle := !bToggle
If bToggle
SetTimer , TheLoop , 200 ; This is 200 ms
Else
SetTimer , TheLoop , Off
Return
#Requires AutoHotkey v2.0
TheLoop:
Send , {Down}
sleep, 400
Send , {0} (+n)
sleep, 400
Send , {Down}
sleep, 400
Return