Sign in to follow this  
Followers 0
nadim

au3recorder

10 posts in this topic

I haven't used autoit in awhile just downloaded it and i cant seem to find the mouse recorder anywhere? Im just trying to do a simple script that clicks 3 areas on my screen and loop it infinite. Can anyone help me?

Share this post


Link to post
Share on other sites



You need to get the Customised version of scite from the download page

http://www.autoitscript.com/autoit3/downloads.shtml

thanks got it to work, and got my macro done, but one thing how do i make it endlessly loop?

Share this post


Link to post
Share on other sites

Make sure you have a way to escape out of your macro because if you don't, you will find it very difficult to take control of your mouse to do anything, including closing your own script.


010101000110100001101001011100110010000001101001011100110010000

001101101011110010010000001110011011010010110011100100001

My Android cat and mouse game
https://play.google.com/store/apps/details?id=com.KaosVisions.WhiskersNSqueek

We're gonna need another Timmy!

Share this post


Link to post
Share on other sites

i got a kill command that works, i just cant figure out how to loop the script

Share this post


Link to post
Share on other sites

HotKeySet("{Esc}", "end")

While 1
    MouseClick("left", 440, 282, 1)
    MouseClick("left", 444, 286, 1)
    MouseClick("left", 378, 285, 2)
    MouseClick("left", 384, 211, 2)
WEnd

Func end()
    Exit (1)
EndFunc   ;==>end

works fine for me, all you would need is to add your winwaitactive...


010101000110100001101001011100110010000001101001011100110010000

001101101011110010010000001110011011010010110011100100001

My Android cat and mouse game
https://play.google.com/store/apps/details?id=com.KaosVisions.WhiskersNSqueek

We're gonna need another Timmy!

Share this post


Link to post
Share on other sites

This should work for you. Just add the rest of your code before or after it.

HotKeySet ("{ESC}", "prog_close")

$x1 = 110 ; Set this number to first x coordinate
$y1 = 120 ; Set this number to first y coordinate
$x2 = 130 ; Set this number to second x coordinate
$y2 = 140 ; Set this number to second y coordinate
$x3 = 150 ; Set this number to third x coordinate
$y3 = 160 ; Set this number to third y coordinate

$delay = 100 ; Set this number to the delay between clicks, in milliseconds

While 1
    Sleep (10)
    MouseClick ("left", $x1, $y1) ; First mouse move and click
    Sleep ($delay)
    MouseClick ("left", $x2, $y2) ; Second mouse move and click
    Sleep ($delay)
    MouseClick ("left", $x3, $y3) ; Third mouse move and click
    Sleep ($delay)
WEnd
Exit 

Func prog_close ()
    Exit
EndFunc

You will probably have to have the "Sleep" commands in there so you're not overloading the processor. It's always good practice to add a little delay in all loops like this.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0