pezo89 Posted August 6, 2009 Share Posted August 6, 2009 is there a solution to my little issue?hey guys, just wondering, how can i use mouseclick within the area? code im trying to get to work is this send ("{Pause}") Opt("MouseClickDelay", 5) ; adjust as needed ; Alters the length of the brief pause in between mouse clicks. ; Time in milliseconds to pause (default=10). Opt("MouseClickDownDelay", 1) ; adjust as needed ; Alters the length a click is held down before release. ; Time in milliseconds to pause (default=10). HotKeySet("{ESC}", "Terminate") For $y = 72 To 839 Step 35 For $x = 0 To 1759 Step 25 MouseClick("left", $x, $y, 1, 0) ;MouseMove($x, $y, 5) Next Nexthowever, i kinda need it to go be tilted like a few degrees >_< Link to comment Share on other sites More sharing options...
pezo89 Posted August 9, 2009 Author Share Posted August 9, 2009 bump >_ Link to comment Share on other sites More sharing options...
Malkey Posted August 10, 2009 Share Posted August 10, 2009 is there a solution to my little issue? hey guys, just wondering, how can i use mouseclick within the area? code im trying to get to work is this send ("{Pause}") Opt("MouseClickDelay", 5) ; adjust as needed ; Alters the length of the brief pause in between mouse clicks. ; Time in milliseconds to pause (default=10). Opt("MouseClickDownDelay", 1) ; adjust as needed ; Alters the length a click is held down before release. ; Time in milliseconds to pause (default=10). HotKeySet("{ESC}", "Terminate") For $y = 72 To 839 Step 35 For $x = 0 To 1759 Step 25 MouseClick("left", $x, $y, 1, 0) ;MouseMove($x, $y, 5) Next Next however, i kinda need it to go be tilted like a few degrees Try this. expandcollapse popup; Opt("MouseClickDelay", 5) ; adjust as needed ; Alters the length of the brief pause in between mouse clicks. ; Time in milliseconds to pause (default=10). Opt("MouseClickDownDelay", 1) ; adjust as needed ; Alters the length a click is held down before release. ; Time in milliseconds to pause (default=10). HotKeySet("{ESC}", "Terminate") _DiamondScan(215, 490, 640, 278, 1063, 490, 640, 705) ; For Diamond shape $xL, $yL - Left x,y coordinate etc. Func _DiamondScan($xL, $yL, $xTop, $yTop, $xR, $tR, $xB, $yB, $xSpacing = 12, $ySpacing = 12) Local $width = $xR - $xL Local $Height = $yB - $yTop Local $rat = $width / $Height Local $x1, $y1, $Grad = ($Height - $Height / $rat) / ($width - $width / $rat) ConsoleWrite("$Height " & $Height & @CRLF) ConsoleWrite("@DesktopWidth / 2 " & $width / $rat & @CRLF) For $y = $Height To $Height / $rat Step -Int(($Height - $Height / $rat) / $ySpacing) For $x = ($width / $rat) To $width Step Int(($width - $width / $rat) / $xSpacing) $x1 = $x + ($y - $Height) / $Grad + $xL $y1 = $y - ($x - $width / $rat) * $Grad + $yTop ;MouseClick("left", $x1, $y1, 1, 0) MouseMove($x1, $y1, 1) Next Next EndFunc ;==>_DiamondScan Func Terminate() Exit 0 EndFunc ;==>Terminate ; Link to comment Share on other sites More sharing options...
pezo89 Posted August 13, 2009 Author Share Posted August 13, 2009 (edited) Try this. expandcollapse popup; Opt("MouseClickDelay", 5) ; adjust as needed ; Alters the length of the brief pause in between mouse clicks. ; Time in milliseconds to pause (default=10). Opt("MouseClickDownDelay", 1) ; adjust as needed ; Alters the length a click is held down before release. ; Time in milliseconds to pause (default=10). HotKeySet("{ESC}", "Terminate") _DiamondScan(215, 490, 640, 278, 1063, 490, 640, 705) ; For Diamond shape $xL, $yL - Left x,y coordinate etc. Func _DiamondScan($xL, $yL, $xTop, $yTop, $xR, $tR, $xB, $yB, $xSpacing = 12, $ySpacing = 12) Local $width = $xR - $xL Local $Height = $yB - $yTop Local $rat = $width / $Height Local $x1, $y1, $Grad = ($Height - $Height / $rat) / ($width - $width / $rat) ConsoleWrite("$Height " & $Height & @CRLF) ConsoleWrite("@DesktopWidth / 2 " & $width / $rat & @CRLF) For $y = $Height To $Height / $rat Step -Int(($Height - $Height / $rat) / $ySpacing) For $x = ($width / $rat) To $width Step Int(($width - $width / $rat) / $xSpacing) $x1 = $x + ($y - $Height) / $Grad + $xL $y1 = $y - ($x - $width / $rat) * $Grad + $yTop ;MouseClick("left", $x1, $y1, 1, 0) MouseMove($x1, $y1, 1) Next Next EndFunc ;==>_DiamondScan Func Terminate() Exit 0 EndFunc ;==>Terminate ; Works like a charm thx alot >_< Edited August 13, 2009 by pezo89 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