My macro is stuck

Ask gaming related questions (AHK v1.1 and older)
yetek453
Posts: 8
Joined: 30 Nov 2023, 08:46

My macro is stuck

Post by yetek453 » 06 Dec 2023, 16:08

Code: Select all

#If WinActive("Roblox")
F1::
Suspend, Toggle
return
~$w::
Send w{w down}
KeyWait w
Send {w up}
Return
$LButton::
{
While GetKeyState("LButton", "P")
	Click
        Sleep 20  ;  milliseconds
Return
}
#If
Its the macro rn... The problem is- when I hold W key and run normally... I m just holding LButton for auto clicking and my screen is like freezing sometimes ? Even if I stop holding W key after that it keeps going and clicking ? It's like the macros are conflicting- I tried removing $ and adding other things but nothing worked... :problem:

User avatar
mikeyww
Posts: 27192
Joined: 09 Sep 2014, 18:38

Re: My macro is stuck

Post by mikeyww » 07 Dec 2023, 08:54

Use braces after a While statement if you intend to have a :arrow: code block.

Why do you need a tilde for your hotkey?

Post Reply

Return to “Gaming Help (v1)”