Jump to content

attaching a send to a mouseclick


Recommended Posts

Hey guys,

I would like to attach another keystroke to a mouseclick, like when i click the mouse i would like it to be able to click say the s button. And want to be able to toggle in and out of doing so. Here is what i have so far, any suggestions? Thanks in advance!

Global $Changed
HotKeySet("{INSERT}", "ToggleChanged")


While 1
    Sleep(100)
WEnd


  Func ToggleChanged()
    $Changed = NOT $Changed
    
    While $Changed
        If MouseClick("left") Then
            send("s")
            sleep(200)
            MouseClick("left")
            sleep(20)
        EndIf
    WEnd

EndFunc
Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...