kazhkaz Posted January 1, 2006 Share Posted January 1, 2006 Is it possible to command PixelSearch to search not for only one color, but for two,three or more? Link to comment Share on other sites More sharing options...
Moderators SmOke_N Posted January 1, 2006 Moderators Share Posted January 1, 2006 PixelSearch in it's 6 parameter has a shade variation, however if you are looking for 'multiple' colors all together you would have to do 'multiple' PixelSearch()'s with the specific colors you desire to find. 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. Link to comment Share on other sites More sharing options...
kazhkaz Posted January 1, 2006 Author Share Posted January 1, 2006 no i need that it find one of the colros listed Link to comment Share on other sites More sharing options...
Moderators SmOke_N Posted January 1, 2006 Moderators Share Posted January 1, 2006 no i need that it find one of the colros listed Right, that's what I'm saying... Example: Dim $Color_One = 0xFF0000 Dim $Color_Two = 0x0000FF Dim $Color_Three = 0xFFFF00 While 1 $PxSrch_One = PixelSearch(0, 0, 100, 100, $Color_One) $PxSrch_Two = PixelSearch(0, 0, 100, 100, $Color_Two) $PxSrch_Three = PixelSearch(0, 0, 100, 100, $Color_Three) If Not @error And IsArray($PxSrch_One) Then MsgBox(0, "", "X Coord is: " & $PxSrch_One[0] & " Y Coord is: " & $PxSrch_One[1]) ElseIf Not @error And IsArray($PxSrch_Two) Then MsgBox(0, "", "X Coord is: " & $PxSrch_Two[0] & " Y Coord is: " & $PxSrch_Two[1]) ElseIf Not @error And IsArray($PxSrch_Three) Then MsgBox(0, "", "X Coord is: " & $PxSrch_Three[0] & " Y Coord is: " & $PxSrch_Three[1]) EndIf Sleep(100) Wend 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. Link to comment Share on other sites More sharing options...
kazhkaz Posted January 1, 2006 Author Share Posted January 1, 2006 Thanks Link to comment Share on other sites More sharing options...
seandisanti Posted January 10, 2006 Share Posted January 10, 2006 Thanks look in scripts and scraps for _PixelSearchX 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