Azaw Posted June 4, 2009 Posted June 4, 2009 im kinda new with scripting, have done some small stuff changes before but now i got some problem with this the three first works but when it come to writing the links it just spam write "link" all the time i have no idee how to fix it so please help me expandcollapse popupGlobal $paused HotKeySet("{F3}", "togglepause") HotKeySet("{ESC}", "terminate") HotKeySet("1", "ett") HotKeySet("2", "tva") HotKeySet("3", "tre") HotKeySet("4", "fyra") HotKeySet("5", "fem") HotKeySet("6", "sex") HotKeySet("7", "sju") Func TogglePause() $paused = Not $paused While $paused Sleep(100) ToolTip('Script is "Paused"', 0, 0) WEnd ToolTip('Script is "Running"', 0, 0) EndFunc ;==>TogglePause Func Terminate() Exit 0 EndFunc ;==>Terminate While 1 Sleep(2500) WEnd Func ett() MouseClick("left", 311, 379) Sleep(500) Send("{ENTER}") EndFunc ;==>one While 2 Sleep(2500) WEnd Func tva() MouseClick("left", 305, 404) Sleep(500) Send("{ENTER}") EndFunc ;==>tva While 3 Sleep(2500) WEnd Func tre() MouseClick("left", 309, 432) Sleep(500) Send("{ENTER}") EndFunc ;==>tre While 4() Sleep(25000) WEnd Func fyra() MouseClick("left", 946, 67) Sleep(1000) Send("link4") Sleep(1000) Send("{ENTER}") EndFunc ;==>fyra While 5() Sleep(2500) WEnd Func fem() MouseClick("left", 946, 67) Sleep(1000) Send("link5") sleep(1000) Send("{ENTER}") EndFunc ;==>fem While 5() Sleep(2500) WEnd Func sex() MouseClick("left", 946, 67) Sleep(1000) Send("link6") Sleep(1000) Send("{ENTER}") EndFunc ;==>sex While 7() Sleep(2500) WEnd Func sju() MouseClick("left", 946, 67) Sleep(1000) Send("link7") Sleep(1000) Send("{ENTER}") EndFunc ;==>sju
6105 Posted June 4, 2009 Posted June 4, 2009 (edited) write link i test it work im new here tooFunc fyra() MouseClick("left", 946, 67) Sleep(1000) Send("http://www.faces.md/") Sleep(1000) Send("{ENTER}") EndFunc;==>fyraPS! u can see here how u can help me too Edited June 4, 2009 by toader [center][font=courier new,courier,monospace]Die die die my darling[/font][/center][center][font=courier new,courier,monospace]Don't utter a single word[/font][/center][center][font=courier new,courier,monospace]Die die die my darling[/font][/center][center][font=courier new,courier,monospace]Just shut your pretty mouth[/font][/center][center][font=courier new,courier,monospace]I'll be seeing you again[/font][/center][center][font=courier new,courier,monospace]I'll be seeing you[/font][/center][center][font=courier new,courier,monospace]In hell[/font][/center]
Skruge Posted June 4, 2009 Posted June 4, 2009 Welcome to the forums! (Välkommen till Forum!) Your function is simulating keypresses when it sends the text "link4", "link5", etc... When it sends the number, it is triggering your hotkey and thus getting stuck in an endless loop. The solution can be to use hotkeys that won't trigger themselves or others, or to temporarily disable the hotkeys: Func fyra() HotKeySet("4") ; Disable this hotkey MouseClick("left", 946, 67) Sleep(1000) Send("link4") Sleep(1000) Send("{ENTER}") HotKeySet("4", "fyra") ; Re-enable it for the next use EndFunc ;==>fyra Also, speaking of endless loops... The While 2, While 3, etc... loops will never be reached because execution is trapped in the first While 1 loop. [font="Tahoma"]"Tougher than the toughies and smarter than the smarties"[/font]
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