Small script for testing Topic is solved

Ask gaming related questions (AHK v1.1 and older)
Drognan
Posts: 8
Joined: 22 May 2018, 12:58

Small script for testing

22 May 2018, 18:38

Hello,

i need help for a small script. I think its not difficult, but i its not working. Here is my code:

Numpad0::
Send {Numpad1 down}
Sleep 10
Loop 30
{
Send {RButton down}
Sleep 60
}
Send {RButton up}
Send {Numpad1 up}
Return
#::ExitApp ; schließt das Skript bei Drücken von Win (="#")

Every time when the Button Numpad1 is pressed then the RButton from the mouse should be pressed and hold for 2 seconds, BUT after a very short waiting time, for ... 0,2 second. This dont work.
I would be thankful for any help.

Regards
Rohwedder
Posts: 7644
Joined: 04 Jun 2014, 08:33
Location: Germany

Re: Small script for testing  Topic is solved

23 May 2018, 01:27

Hallo,
I assume you want this:

Code: Select all

~*Numpad1::
Sleep, 200
Send {Blind}{RButton Down}
Sleep, 2000
Send {Blind}{RButton up}
Return
#::ExitApp ; schließt das Skript bei Drücken von Win (="#")
Drognan
Posts: 8
Joined: 22 May 2018, 12:58

Re: Small script for testing

23 May 2018, 05:43

thanks, you think i dont need a loop ? Its not auto repeating, i have read the tutorial. But i have tested it, and it works.

1. Press Numpad 1
2. wait 0,7 second (better value)
3. Press and hold Numpad 3 for 2 seconds

Return to “Gaming Help (v1)”

Who is online

Users browsing this forum: ReyAHK and 95 guests