need help if anyone willing? Topic is solved

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

need help if anyone willing?

22 Feb 2018, 00:05

HI guys I'm struggling to combine some code, but with what I have I can only get half of it to work.
The following is what im trying to achieve.
While right mouse button is held down I want to achieve 2 things: "'\'' to be held down(but not spammed or released), until right mouse is released, but also ''['' to be spammed repeatedly until right mouse button is released. I can get one or the other to work but not both at the same time with one Right mouse button hold. Heres what I have so far, any help completeing this code would be greatly appreciated :)


~RButton:: ;"~": When the hotkey fires, its key's native function will not be blocked
sleep 100

While GetKeyState("RButton","P")
Send, {[}

SEND, {\ Down}
KeyWait, RButton
SEND, {\ Up}

Return
User avatar
Nwb
Posts: 444
Joined: 29 Nov 2016, 08:56

Re: need help if anyone willing?  Topic is solved

22 Feb 2018, 01:30

Try. Should work as you mentioned, let me know if it doesn't.

Code: Select all

~Rbutton::
Send, {\ Down}

Loop {
sleep 100
Send, {[} 
GetKeyState,  state, Rbutton, 
if state = U
break
}
return

~Rbutton UP:: 
Send, {[ Up}

esc::ExitApp
;closes script
return
I am your average ahk newbie. Just.. a tat more cute. ;)

Return to “Gaming Help (v1)”

Who is online

Users browsing this forum: No registered users and 73 guests