Jump to content
Sign in to follow this  
asym

Double Pixel Search

Recommended Posts

asym

Ok... SO I wanna make a pixel search I already did one for 1 colour... But I want the pixel search to search for 2 colours, I dont need the coordinates of the colours I just need it to search for the 2 colours and if it finds at least one of them it does some defined action...

Is it possible?

Share this post


Link to post
Share on other sites
SmokNiszczyciel

I think this will work:

$a=pixelsearch(ur settings)
if $a=not @error then
$b=pixelsearch(yur settings 2)
if $b=not @error then
..ur script..
endif
endif

u can do this without variables

Share this post


Link to post
Share on other sites
asym

I think this will work:

$a=pixelsearch(ur settings)
if $a=not @error then
$b=pixelsearch(yur settings 2)
if $b=not @error then
..ur script..
endif
endif

u can do this without variables

But wont that script search for the 2nd color only if the 1st was found?

I want it to find any of the 2 colors it doesnt matters if it doesnt find one...

Share this post


Link to post
Share on other sites
JohnOne

$pixel = PixelSearch($l, $t, $r, $b, $Coloura)
If Not @error Then
    _myfunc()
Else
    $pixel = PixelSearch($l, $t, $r, $b, $Colourb)
    If Not @error Then
        _myfunc()
    EndIf
EndIf


AutoIt Absolute Beginners    Require a serial    Pause Script    Video Tutorials by Morthawt   ipify 

Monkey's are, like, natures humans.

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  

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.