Code: Select all
f1::MyFunc()
MyFunc() { ; function 'MyFunc'
static boolean := true ; the value of static variables (included any modification upon them) are remembered between function calls
if (boolean:=!boolean) { ; !boolean return true if boolean=false and false if boolean=true
MouseClick, left, 107, 537,,1
Send ^{9}
; content of action 1 goes here
} else {
Send ^{1}
; content of action 2 goes here
}
}
return
f2::
Send ^{1}
sleep 200
MouseClick, left, 107, 577,,1
MouseClick, left, 107, 537,,1
Send ^{9}
boolean:=!boolean
boolean := true
return