Oreoshakes Posted August 9, 2007 Share Posted August 9, 2007 $Target = 0xC4C1C4 $SearchResult = PixelSearch(252,196,768,487,$TargetG,5,3) how do i target more than one color? let me know if more info needed. Link to comment Share on other sites More sharing options...
Paulie Posted August 9, 2007 Share Posted August 9, 2007 $Target = 0xC4C1C4 $SearchResult = PixelSearch(252,196,768,487,$TargetG,5,3) how do i target more than one color? let me know if more info needed.Conduct multiple searches: $Target1 = 0xC4C1C4 $Target2 = 0xC4C1C4 $Target3 = 0xC4C1C4 $SearchResult1 = PixelSearch(252,196,768,487,$Target1,5,3) $SearchResult2 = PixelSearch(252,196,768,487,$Target2,5,3) $SearchResult3 = PixelSearch(252,196,768,487,$Target3,5,3) If Isarray($SearchResult1) Then ;Do somethingfor color 1 EndIf If Isarray($SearchResult2) Then ;Do somethingfor color 2 EndIf If Isarray($SearchResult3) Then ;Do somethingfor color 3 EndIf Link to comment Share on other sites More sharing options...
Oreoshakes Posted August 9, 2007 Author Share Posted August 9, 2007 Conduct multiple searches: $Target1 = 0xC4C1C4 $Target2 = 0xC4C1C4 $Target3 = 0xC4C1C4 $SearchResult1 = PixelSearch(252,196,768,487,$Target1,5,3) $SearchResult2 = PixelSearch(252,196,768,487,$Target2,5,3) $SearchResult3 = PixelSearch(252,196,768,487,$Target3,5,3) If Isarray($SearchResult1) Then ;Do somethingfor color 1 EndIf If Isarray($SearchResult2) Then ;Do somethingfor color 2 EndIf If Isarray($SearchResult3) Then ;Do somethingfor color 3 EndIf Thanks man Link to comment Share on other sites More sharing options...
Oreoshakes Posted August 9, 2007 Author Share Posted August 9, 2007 (edited) This is part of the script that i have but i don't know what to do with MouseClick($Click, $SearchResult1[0]+15, $SearchResult1[1]+45, 7, 3) to make it use both $SearchResult1 and $SearchResult2. $TargetG = 0x5B9600 $TargetW = 0xC4C1C4 $TargetR = 0xCD4800 $Click = "Right" While 1 = 1 Sleep(100) $SearchResult1 = PixelSearch(252,196,768,487,$TargetG,5,3) $SearchResult2 = PixelSearch(252,196,768,487,$TargetW,5,3) If @error <> 1 Then MouseClick($Click, $SearchResult1[0]+15, $SearchResult1[1]+45, 7, 3) Send("{F1}") Send("{F3}") if isarray $SearchResult1 = PixelSearch(237,193,806,638,$TargetG,5,1) Then endif if isarray $SearchResult2 = PixelSearch(237,193,806,638,$TargetW,5,1) Then endif Send("{Right}") Edited August 9, 2007 by Oreoshakes Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now