i need help about script click F1 - F2 Topic is solved

Ask gaming related questions (AHK v1.1 and older)
Guest

i need help about script click F1 - F2

07 Sep 2018, 19:21

hi .. i want scrpit click F1 - F2 Faster Because I need an online game .. thanks
User avatar
Onimuru
Posts: 107
Joined: 08 Sep 2018, 18:35
Contact:

Re: i need help about script click F1 - F2

11 Sep 2018, 06:46

Code: Select all

*$1::
	#MaxHotkeysPerInterval 20000
	#HotkeyInterval 20
	SetKeyDelay, -1, -1
	Random, r, 50, 85
	Loop
	{
		If !GetKeyState("1", "P")
			Break
		Send {F1}
		Sleep r
		Send {F2}
		Sleep r
	}
	Return
This will spam {F1}, {F2} as long as you hold down 1
kmasotra
Posts: 3
Joined: 07 Sep 2018, 19:07

Re: i need help about script click F1 - F2  Topic is solved

11 Sep 2018, 08:57

Onimuru wrote:

Code: Select all

*$1::
	#MaxHotkeysPerInterval 20000
	#HotkeyInterval 20
	SetKeyDelay, -1, -1
	Random, r, 50, 85
	Loop
	{
		If !GetKeyState("1", "P")
			Break
		Send {F1}
		Sleep r
		Send {F2}
		Sleep r
	}
	Return
This will spam {F1}, {F2} as long as you hold down 1

thank you so much bro :dance: but he click only at F2 But F1 Not Work i don't know why ... Any idya you have ? :D
kmasotra
Posts: 3
Joined: 07 Sep 2018, 19:07

Re: i need help about script click F1 - F2

11 Sep 2018, 09:41

I want the power key to work automatically and stand when I press the 1 key. Also the speed is very low I want it to be very fast .. Thank you so much my friend
User avatar
Onimuru
Posts: 107
Joined: 08 Sep 2018, 18:35
Contact:

Re: i need help about script click F1 - F2

11 Sep 2018, 11:16

Not sure why it isn't registering F2, try with SendMode, Input and Down/up. You can test the speed in notepad if you change {F1} and {F2} to a and s for instance. Should be really really fast spam. If {F2} still won't fire, it could be because of animation lock and the {F1} action taking priority over the {F2} action. In that case you will need to increase the sleep time to match, just test and adjust.

Code: Select all

#SingleInstance Force
SendMode Input
Process, Priority, , Realtime
SetBatchLines, -1

*$1::
	#MaxHotkeysPerInterval 20000
	#HotkeyInterval 20
	SetKeyDelay, -1, -1
	Random, r, 50, 85		;Make the Min, Max here less to increase the spam speed
	Loop
	{
		If !GetKeyState("1", "P")
			Break
		Send {F1 Down}		;Replace me to test
		Sleep 5
		Send {F1 Up}
		Sleep r
		Send {F2 Down}		;Replace me to test
		Sleep 5
		Send {F2 Up}
		Sleep r
	}
	Return
kmasotra
Posts: 3
Joined: 07 Sep 2018, 19:07

Re: i need help about script click F1 - F2

12 Sep 2018, 10:54

Onimuru wrote:Not sure why it isn't registering F2, try with SendMode, Input and Down/up. You can test the speed in notepad if you change {F1} and {F2} to a and s for instance. Should be really really fast spam. If {F2} still won't fire, it could be because of animation lock and the {F1} action taking priority over the {F2} action. In that case you will need to increase the sleep time to match, just test and adjust.

Code: Select all

#SingleInstance Force
SendMode Input
Process, Priority, , Realtime
SetBatchLines, -1

*$1::
	#MaxHotkeysPerInterval 20000
	#HotkeyInterval 20
	SetKeyDelay, -1, -1
	Random, r, 50, 85		;Make the Min, Max here less to increase the spam speed
	Loop
	{
		If !GetKeyState("1", "P")
			Break
		Send {F1 Down}		;Replace me to test
		Sleep 5
		Send {F1 Up}
		Sleep r
		Send {F2 Down}		;Replace me to test
		Sleep 5
		Send {F2 Up}
		Sleep r
	}
	Return

Still Have 2 Problem .. Frist Very Slow :headwall: Two .. i want when i click Number 1 He Work Automatic And when i click againe Number 1 He Stop .. i Hop you understand me .. And Thanks For Help :xmas:

Return to “Gaming Help (v1)”

Who is online

Users browsing this forum: No registered users and 41 guests