Jump to content

Help me with mouse clicks


Recommended Posts

Hi guys!

I'm really new to AutoIT, and I have little experience with scripting or any sort of programming. But I'm trying to learn!
Right now, what I'm trying to do is make a quick script that repeats a few functions while a key is held down. I want to see if I can make a quick-burst script that might work in Fallout 4 with machine guns
 

#include <Misc.au3>

$dll = DllOpen("user32.dll")

While 1
    Sleep(100)
    If _IsPressed("01", $dll) Then
        MouseDown("left")
        Sleep(320)
        MouseUp("left")
        Sleep(25)
    EndIf
WEnd
DllClose($dll)

Right now, when I hold down my left mouse button, it just repeats the script once - then I have to release and hold again to enable it again. Is it possible to to start it from the top and basically just repeats itself while I'm holding down my mouse button?

In advance, thank you!

Link to comment
Share on other sites

  • Moderators

@fishbones you seem to have missed the forum rules on your way in. Please read them now, especially the part about game automation, and you will see why you won't receive any help with these subjects.

"Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball

How to get your question answered on this forum!

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
 Share

×
×
  • Create New...