shade123 Posted March 7, 2009 Share Posted March 7, 2009 okay, i want it so that when someone right clicks, it holds down the right click button until they press it again. whilst it is held down i want it to spam the f11 key 20 times then f12 key once then loop that until the right click hold is terminated. here is what i got so far but it wont work, says error with line 3 (the if {Rbutton} = pressed line): $clicked = 0 If {RButton} = pressed Then If $clicked = 1 Then $clicked = 0 MouseUp("right") Else $clicked = 1 MouseDown("right") Send("{F11 20}") Send("{F12}") EndIf Else Sleep(100) EndIf Link to comment Share on other sites More sharing options...
Zedna Posted March 7, 2009 Share Posted March 7, 2009 Use _IsPressed() to catch mouse rbutton down event. Resources UDF ResourcesEx UDF AutoIt Forum Search Link to comment Share on other sites More sharing options...
shade123 Posted March 8, 2009 Author Share Posted March 8, 2009 #Include <Misc.au3> $clicked = 0 While 1 If _IsPressed("{RButton}") Then If $clicked = 1 Then $clicked = 0 MouseUp("right") Else $clicked = 1 MouseDown("right") Send("{F11 20}") Send("{F12}") EndIf Else Sleep(100) EndIf WEnd that doesnt work, so what now? Link to comment Share on other sites More sharing options...
Authenticity Posted March 8, 2009 Share Posted March 8, 2009 _IsPress expecting to receive string representing a number. Read the help file again. "02" is for right mouse button. Link to comment Share on other sites More sharing options...
demandnothing Posted September 3, 2009 Share Posted September 3, 2009 too complicated.. tested this myself, i'll let you fill in the rest $x = MouseClick("right") If _IsPressed($x) = True Then MouseUp("right") Sleep(10) MouseDown("right") Link to comment Share on other sites More sharing options...
dbzfanatic Posted September 3, 2009 Share Posted September 3, 2009 No one's going to write this for you. If you're not going to put out the effort to learn for yourself why are you here? Go to my website. | My Zazzle Page (custom products)Al Bhed Translator | Direct linkScreenRec ProSimple Text Editor (STE) [TUTORIAL]Task Scheduler UDF <--- First ever UDF!_ControlPaste() UDF[quote name='renanzin' post='584064' date='Sep 26 2008, 07:00 AM']whats help ?[/quote] 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