#include <Misc.au3>
#include <GUIConstantsEx.au3>
$GUI = GUICreate('Кликиы', 400, 300)
$Button1 = GUICtrlCreateButton('OK', 90, 200, 215, 20)
While 1
$nMsg = GUIGetMsg()
Switch $nMsg
Case $GUI_EVENT_CLOSE
Exit
Case $Button1
_1()
EndSwitch
WEnd
Func _1()
MouseClick("left", 10, 500, 1, 0)
sleep(10)
MouseClick("right", 25, 510, 1, 0)
EndFunc