matrix10657 Posted December 17, 2006 Posted December 17, 2006 (edited) $Enroute = Pixelsearch (799,171,834,487,0xFFFF00) sleep (5000) Pixelsearch (799,171,834,487,0xFFFF00) If not @error then mousemove ($Enroute[0], $Enroute[1], 5) sleep (250) mouseclick ("right",$Enroute[0], $Enroute[1]) sleep (250) $WTZx = ($Enroute[0] + 80) $WTZy = ($Enroute[1] + 10) mousemove ($WTZx, $WTZy, 5) sleep (100) mouseclick ("left" ,$WTZx, $WTZy) For some reason, I get the error message Mousemove ($enroute[0], $enroute[1], 5) mousemove ($enroute^Error Error: subscript used with non-array variable it was working just a few hours ago.. Edited December 17, 2006 by matrix10657
martin Posted December 17, 2006 Posted December 17, 2006 for some reasonWould you like to try again? Serial port communications UDF Includes functions for binary transmission and reception.printing UDF Useful for graphs, forms, labels, reports etc.Add User Call Tips to SciTE for functions in UDFs not included with AutoIt and for your own scripts.Functions with parameters in OnEvent mode and for Hot Keys One function replaces GuiSetOnEvent, GuiCtrlSetOnEvent and HotKeySet.UDF IsConnected2 for notification of status of connected state of many urls or IPs, without slowing the script.
matrix10657 Posted December 17, 2006 Author Posted December 17, 2006 Would you like to try again?... accidently hit enter
martin Posted December 17, 2006 Posted December 17, 2006 (edited) ... accidently hit enterNo problem.I think you need to say$Enroute = Pixelsearch (799,171,834,487,0xFFFF00)then $Enroute will be an array you can useEDIT ADDEDNot so sure now I look at your post again because you do have that set at the very first line. $Enroute should be an array if the color was found. What happens if you check @error after the first call to pixelsearch? Edited December 17, 2006 by martin Serial port communications UDF Includes functions for binary transmission and reception.printing UDF Useful for graphs, forms, labels, reports etc.Add User Call Tips to SciTE for functions in UDFs not included with AutoIt and for your own scripts.Functions with parameters in OnEvent mode and for Hot Keys One function replaces GuiSetOnEvent, GuiCtrlSetOnEvent and HotKeySet.UDF IsConnected2 for notification of status of connected state of many urls or IPs, without slowing the script.
matrix10657 Posted December 17, 2006 Author Posted December 17, 2006 thx. I'll use this thread to ask another question (in all of my noobishness) If I want to use the command pixelgetcolor, how do I make it so if it finds a certain color, it does something. for example- $notinwarp = Pixelgetcolor (1,27) if $notinwarp = 0xC1C6CF Then (whatever) does this mean that if $notinwarp is 0xc1c6cf then it will do (whatever). And also, is there a way to add a shade varience elemnt to get color and implement it in the way I need to?
martin Posted December 17, 2006 Posted December 17, 2006 thx. I'll use this thread to ask another question (in all of my noobishness)If I want to use the command pixelgetcolor, how do I make it so if it finds a certain color, it does something.for example-$notinwarp = Pixelgetcolor (1,27)if $notinwarp = 0xC1C6CF Then(whatever)does this mean that if $notinwarp is 0xc1c6cf then it will do (whatever). And also, is there a way to add a shade varience elemnt to get color and implement it in the way I need to?I'm no expert on colors, but you could try something like$var = 0x111111if $notinwarp > 0xC1C6CF - $var and $notinwarp < 0xC1C6CF + $var Then do thiselse do the otherendif Serial port communications UDF Includes functions for binary transmission and reception.printing UDF Useful for graphs, forms, labels, reports etc.Add User Call Tips to SciTE for functions in UDFs not included with AutoIt and for your own scripts.Functions with parameters in OnEvent mode and for Hot Keys One function replaces GuiSetOnEvent, GuiCtrlSetOnEvent and HotKeySet.UDF IsConnected2 for notification of status of connected state of many urls or IPs, without slowing the script.
Glyph Posted December 17, 2006 Posted December 17, 2006 Oh oh oh pick me!, i made a colorbot! try something like this! Func Char1() $Coords = PixelSearch( 390, 290,410, 310, 0xFFFFFF, 10) ;find the color white! then click it If @error Then Return MouseMove ($Coords[0], $Coords[1], 0) ;X and Y, 0 is the speed (instantly) MouseDown("left") Sleep(100) MouseUp("left") EndFunc tolle indicium
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