Sign in to follow this  
Followers 0
Andrew Chen

How/Can you detect a pixel color change?

3 posts in this topic

Is there some way to write a script to watch and detect a single pixel to change colors?

Share this post


Link to post
Share on other sites



just use a loop with pixelgetcolor()

Share this post


Link to post
Share on other sites

HotKeySet("{esc}","quit")
$pix=PixelGetColor(500,500)
$quit=False
Do
    
sleep(500);check every half a second
$pix2=PixelGetColor(500,500)
if $pix <> $pix2 then 
MsgBox(0,"", "That Pixel Has Changed",0)
$pix=PixelGetColor(500,500)
EndIf
until $quit=true

func quit()
    $quit=True
MsgBox(0,"","Bye",0)
EndFunc

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