Guest Mark7805 Posted May 23, 2005 Share Posted May 23, 2005 Ok want to make a bot that clicks a certain place every 2mins.So I need more help on Mouseclick commands and stuff.If possible I would LOVE if some1 could give me live support over msn. Link to comment Share on other sites More sharing options...
DaleHohm Posted May 23, 2005 Share Posted May 23, 2005 You may get a taker on the MSN-live-help, but I doubt it. You will likely get as much help as you need however if you post some sample code that you are working on and say what you are trying to do and what trouble you are having. The point is that no one wants to read the helpfile to you... show us the effort you've made first and you'll find this to be a very helpful place. Free Internet Tools: DebugBar, AutoIt IE Builder, HTTP UDF, MODIV2, IE Developer Toolbar, IEDocMon, Fiddler, HTML Validator, WGet, curl MSDN docs: InternetExplorer Object, Document Object, Overviews and Tutorials, DHTML Objects, DHTML Events, WinHttpRequest, XmlHttpRequest, Cross-Frame Scripting, Office object model Automate input type=file (Related) Alternative to _IECreateEmbedded? better: _IECreatePseudoEmbedded Better Better? IE.au3 issues with Vista - Workarounds SciTe Debug mode - it's magic: #AutoIt3Wrapper_run_debug_mode=Y Doesn't work needs to be ripped out of the troubleshooting lexicon. It means that what you tried did not produce the results you expected. It begs the questions 1) what did you try?, 2) what did you expect? and 3) what happened instead? Reproducer: a small (the smallest?) piece of stand-alone code that demonstrates your trouble Link to comment Share on other sites More sharing options...
Blue_Drache Posted May 23, 2005 Share Posted May 23, 2005 Ok want to make a bot that clicks a certain place every 2mins.So I need more help on Mouseclick commands and stuff.If possible I would LOVE if some1 could give me live support over msn.<{POST_SNAPBACK}>WinActivate()Send()ControlClick()MouseClick()This list of functions will get you on your way. Lofting the cyberwinds on teknoleather wings, I am...The Blue Drache Link to comment Share on other sites More sharing options...
scriptkitty Posted May 23, 2005 Share Posted May 23, 2005 (edited) while 1; simple loop start mouseclick("right",100,100,1,1); MouseClick ( "button" [, x, y [, clicks [, speed ]]] ) sleep(1000*60*2); pause for 1sec x 60 sec in a min x 2 wend; end loop be it known that coords don't always work in things like directX games, and make sure you use the right MouseCoordMode Edited May 23, 2005 by scriptkitty AutoIt3, the MACGYVER Pocket Knife for computers. Link to comment Share on other sites More sharing options...
Guest Mark7805 Posted May 23, 2005 Share Posted May 23, 2005 this is what I got right now: ;Autoit Version: 3.0 ;Language: English ;Platform:2000/XP ;Mark(Author) sleep(5000) MouseClick("left"0,131,141,559) Sleep(15000) Link to comment Share on other sites More sharing options...
MarkMarkMark Posted May 23, 2005 Share Posted May 23, 2005 this is what I got right now:;Autoit Version: 3.0;Language: English;Platform:2000/XP;Mark(Author)sleep(5000) MouseClick("left"0,131,141,559) Sleep(15000)<{POST_SNAPBACK}>while 1MouseClick("left"0,131,141,559) sleep(1000*60*2)wend Link to comment Share on other sites More sharing options...
Blue_Drache Posted May 23, 2005 Share Posted May 23, 2005 while 1MouseClick("left"0,131,141,559) sleep(1000*60*2)wend<{POST_SNAPBACK}>Clicking at x = 0, y = 131, for a total of 141 times with a delay of 559 seconds between each click?Re-examine your syntax. Lofting the cyberwinds on teknoleather wings, I am...The Blue Drache Link to comment Share on other sites More sharing options...
Guest Mark7805 Posted May 23, 2005 Share Posted May 23, 2005 (edited) sry I'm new..They don't have ranks on forums for no reason:| Edited May 23, 2005 by Mark7805 Link to comment Share on other sites More sharing options...
Blue_Drache Posted May 23, 2005 Share Posted May 23, 2005 sry I'm new..They don't have ranks on forums for no reason:|<{POST_SNAPBACK}> Yeah, I was at one time too. Don't worry, the shine will wear off and you'll get to be just like us. I find the language more intuitave than some of the other ones out there. Lofting the cyberwinds on teknoleather wings, I am...The Blue Drache Link to comment Share on other sites More sharing options...
scriptkitty Posted May 23, 2005 Share Posted May 23, 2005 (edited) while 1 MouseClick("left",0,131,141,559); make sure you add the , after the button. sleep(1000*60*2) wendwhile 1 MouseClick("left",0,131,141,559); make sure you add the , after the button. sleep(1000*60*2) wendthis would click 141 times559 means that it moves to that spot at a speed of 559, not a delay per tick of one I thinkParametersbutton The button to click: "left", "right", "middle", "main", "menu", "primary", "secondary". x, y [optional]The x/y coordinates to move the mouse to. If no x and y coords are given, the current position is used. clicks [optional] The number of times to click the mouse. Default is 1. speed [optional] the speed to move the mouse in the range 1 (fastest) to 100 (slowest). A speed of 0 will move the mouse instantly. Default speed is 10so you might just wantwhile 1 MouseClick("left",0,131,1,1); click left button at 0,131 once ;and move there almost instantly. sleep(1000*60*2); delay of 2 minutes wend Edited May 23, 2005 by scriptkitty AutoIt3, the MACGYVER Pocket Knife for computers. Link to comment Share on other sites More sharing options...
DaleHohm Posted May 23, 2005 Share Posted May 23, 2005 Syntax: MouseClick( button, x, y, clicks, speed) since clicks defaults to 1 and speed to a reasonable value, you probably want something more like:MouseClick("left",131,141) As Mark pointed out, placing this into an idle loop (While 1...WEnd) will make it execute until you stop it manually. So the following will sleep for 5 seconds, left-click at 131, 141, wait 15 seconds, click, wait 15 seconds, click etc. Sleep(5000) While 1 MouseClick( "left",131,141) Sleep(15000) WEnd The next step would be to create a way to get out of the pogram... The following will use the ESC key as a hotkey to exit: HotKeySet("{ESC}", "Terminate") Sleep(5000) While 1 MouseClick( "left",131,141) Sleep(15000) WEnd Func Terminate() Exit EndFunc Dale Free Internet Tools: DebugBar, AutoIt IE Builder, HTTP UDF, MODIV2, IE Developer Toolbar, IEDocMon, Fiddler, HTML Validator, WGet, curl MSDN docs: InternetExplorer Object, Document Object, Overviews and Tutorials, DHTML Objects, DHTML Events, WinHttpRequest, XmlHttpRequest, Cross-Frame Scripting, Office object model Automate input type=file (Related) Alternative to _IECreateEmbedded? better: _IECreatePseudoEmbedded Better Better? IE.au3 issues with Vista - Workarounds SciTe Debug mode - it's magic: #AutoIt3Wrapper_run_debug_mode=Y Doesn't work needs to be ripped out of the troubleshooting lexicon. It means that what you tried did not produce the results you expected. It begs the questions 1) what did you try?, 2) what did you expect? and 3) what happened instead? Reproducer: a small (the smallest?) piece of stand-alone code that demonstrates your trouble Link to comment Share on other sites More sharing options...
scriptkitty Posted May 23, 2005 Share Posted May 23, 2005 And then later, you might want to pause it Dim $p HotKeySet("{ESC}", "Terminate") hotkeyset("{pause}","pause_me") Sleep(5000) While 1 MouseClick( "left",131,141) Sleep(15000) WEnd Func Terminate() Exit EndFunc func pause_me() $p=NOT $p while $p sleep(10) tooltip("paused",0,0) WEnd tooltip() EndFunc AutoIt3, the MACGYVER Pocket Knife for computers. Link to comment Share on other sites More sharing options...
Blue_Drache Posted May 23, 2005 Share Posted May 23, 2005 And then later, you might want to pause it<{POST_SNAPBACK}>But only hog the hotkeys if the window affected window is active, and use a different method of timing.Dim $p,$mod Sleep(5000) While 1 Sleep(125) If WinActive("windowname") then HotKeySet("{ESC}", "Terminate") hotkeyset("{pause}","pause_me") Else HotKeySet("{ESC}") hotkeyset("{pause}") EndIf ; Fire off every two minutes by the computer's clock If Mod(@MIN, 2) = 0 And $mod = 0 Then MouseClick( "left",131,141) $mod = 1 ElseIf Mod(@MIN, 2) > 0 And $mod = 1 Then $mod = 0 EndIf WEnd Func Terminate() Exit EndFunc func pause_me() $p=NOT $p while $p sleep(10) tooltip("paused",0,0) WEnd tooltip() EndFunc Lofting the cyberwinds on teknoleather wings, I am...The Blue Drache Link to comment Share on other sites More sharing options...
herewasplato Posted May 25, 2005 Share Posted May 25, 2005 (edited) Ok want to make a bot that clicks a certain place every 2mins.So I need more help on Mouseclick commands and stuff.If possible I would LOVE if some1 could give me live support over msn.<{POST_SNAPBACK}>I'm sure that this thread is not related to this one: http://www.autoitscript.com/forum/index.php?showtopic=11832Edit: fixed link Edited May 25, 2005 by herewasplato [size="1"][font="Arial"].[u].[/u][/font][/size] 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