Sign in to follow this  
Followers 0
Kulisha

When pixel color changes do...

3 posts in this topic

Hi all,

I'm a newbie as you see. I'm trying to use autoit to execute the following action:

Check continuously the color of a pixel, as soon as it changes execute a mouseclick for example.

The loop should be executed several times a second.

Pretty basic I think, but I'm loosing a lot of time trying to make it succeed.

Thanks for any help!

Kulisha

Share this post


Link to post
Share on other sites



Hi all,

I'm a newbie as you see. I'm trying to use autoit to execute the following action:

Check continuously the color of a pixel, as soon as it changes execute a mouseclick for example.

The loop should be executed several times a second.

Pretty basic I think, but I'm loosing a lot of time trying to make it succeed.

Thanks for any help!

Kulisha

$Color = 0xFFFFFF ; or whatever the color is
While $Color = 0xFFFFFF
    $Color = PixelGetColor($xCoord, $yCoord)
    Sleep(10)
WEnd
MouseClick(button, x, y, times, speed)
Anymore help than that you'll need to post what you've done that has waisted your time.

[center]Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.[/center]

Share this post


Link to post
Share on other sites

$Color = 0xFFFFFF ; or whatever the color is
While $Color = 0xFFFFFF
    $Color = PixelGetColor($xCoord, $yCoord)
    Sleep(10)
WEnd
MouseClick(button, x, y, times, speed)
Anymore help than that you'll need to post what you've done that has waisted your time.

Thanks a lot, that was fast!!!! By the way my script works as I needed....

:D:D

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