Code:
Global $TPaused
HotKeySet("{PAUSE}", "TogglePause")
HotKeySet("!{q}", "Terminate") ; PRESS Alt Q to terminate.
Func TogglePause()
$TPaused = NOT $TPaused
While $TPaused
sleep(100)
ToolTip('BOT PAUSE',0,0)
WEnd
ToolTip("")
EndFunc
Func Terminate()
Exit 0
EndFunc