nowayhome2 Posted August 1, 2009 Posted August 1, 2009 (edited) say i have $Fighter = PixelSearch( 6, 28, 619, 408, $Color, 1, 0) If Not @error Then MouseClick("left", $Fighter[0], $Fighter[1], 1, 0) and i want my mouse to follow along the x axis but after it gets there i want it to quickly move up the y axis a couple pixels how would i do that ? Edited August 1, 2009 by nowayhome2
somdcomputerguy Posted August 1, 2009 Posted August 1, 2009 MouseMove - Bruce /*somdcomputerguy */ If you change the way you look at things, the things you look at change.
Info Posted August 1, 2009 Posted August 1, 2009 I really don't get what you're trying to say. Could you provide us more information? $Pixel = PixelSearch(0,0,100,100,0xffffff) ;Will look for the white color from coords 0,0 to coords 100,100. MouseMove($Pixel[0],$Pixel[1],3) ;Will move the cursor to there. MsgBox(64,"Found it!","X: "&$Pixel[0]&@CRLF&"Y: "&$Pixel[1])
nowayhome2 Posted August 1, 2009 Author Posted August 1, 2009 (edited) i want it to find the pixel color im looking for on the x axis get there then mouseclick at 5 pixels down directly from the found pixel if that makes any sense ?where the pink color is where i want the mouse to move the line represents i want it to go directly down from that and click on the orange circle.or not even move there just find that pixel color and move directly down from that point Edited August 1, 2009 by nowayhome2
Tvern Posted August 1, 2009 Posted August 1, 2009 (edited) i want it to find the pixel color im looking for on the x axis get there then mouseclick at 5 pixels down directly from the found pixel if that makes any sense ? where the pink color is where i want the mouse to move the line represents i want it to go directly down from that and click on the orange circle. or not even move there just find that pixel color and move directly down from that point Something like this? It will first move to the found pixel, then click 5 pixels lower. $Fighter = PixelSearch( 6, 28, 619, 408, $Color, 1, 0) If Not @error Then MouseMove($Fighter[0],$Fighter[1]) MouseClick("left", $Fighter[0], $Fighter[1]+5, 1, 0) EndFunc Edit: removed the image Edited August 1, 2009 by Tvern
nowayhome2 Posted August 1, 2009 Author Posted August 1, 2009 (edited) Something like this? It will first move to the found pixel, then click 5 pixels lower. $Fighter = PixelSearch( 6, 28, 619, 408, $Color, 1, 0) If Not @error Then MouseMove($Fighter[0],$Fighter[1]) MouseClick("left", $Fighter[0], $Fighter[1]+5, 1, 0) EndFunc Edit: removed the image thank you so much >_< now how would i move it up instead of down? i assume $Fighter = PixelSearch( 6, 28, 619, 408, $Color, 1, 0) If Not @error Then MouseMove($Fighter[0],$Fighter[1]) MouseClick("left", $Fighter[0], $Fighter[1]-5, 1, 0) EndFunc but then i get an error either way up or down Subscript used with non-array variable Edited August 1, 2009 by nowayhome2
Tvern Posted August 1, 2009 Posted August 1, 2009 Sorry auto complete made me write "EndFunc" It should be "EndIf" And yes Changing "$Fighter[1]+5" to "$Fighter[1]-5" will move the mouse up, instead if down. In the same way ""$Fighter[1]+50" will move 50 pixels down instead of 5.
eruvis Posted September 21, 2009 Posted September 21, 2009 i have a similar type of request but do not really understand the commands that well yet, this is what i tried to do: $color=PixelSearch(1,400,400,1,0xFFBA4A) mousemove($color) mouseclick("left") $color=PixelSearch(1,400,400,1,0x94BE42) mousemove($color) mouseclick("left") its supposed to search a rectangle of 400 length and width (im assuming left = 0, right = max, down = 0 and up = max) ? for color 1, 0xFFBA4A, move to that color, click it, then search for color 2, 0x94BE41 move to that color and then click it. thanks in advance to all who help =)
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