Page 1 of 1

Press/hold X = X+Num6

Posted: 28 Mar 2023, 03:37
by Pounc3r
I want both Z and Num6 to trigger when I hold down Z, any help is appreciated!

Re: Press/hold X = X+Num6

Posted: 28 Mar 2023, 05:55
by mikeyww

Code: Select all

#Requires AutoHotkey v2.0
~z::Numpad6

Re: Press/hold X = X+Num6

Posted: 28 Mar 2023, 06:35
by Pounc3r
i figured out the logic sort of, just dont know how to do it
while x down, x down num6 down
on x up, x up num6 up

Re: Press/hold X = X+Num6

Posted: 28 Mar 2023, 06:56
by Pounc3r
mikeyww wrote:
28 Mar 2023, 05:55

Code: Select all

#Requires AutoHotkey v2.0
~z::Numpad6
This works great! however, due to latency, i need to add about 30ms latency between when i press Z and Num6, i tried using sleep but i am not sure how to implement it in this fashion, can you help?

Re: Press/hold X = X+Num6

Posted: 28 Mar 2023, 07:26
by mikeyww

Code: Select all

#Requires AutoHotkey v2.0
$z::SetKeyDelay(30), SendEvent('z{NumPad6}')

Re: Press/hold X = X+Num6

Posted: 28 Mar 2023, 07:42
by Pounc3r
ok the problem appears to be different...i need Num6 to be pressed once when i press or hold x

Re: Press/hold X = X+Num6

Posted: 28 Mar 2023, 08:53
by mikeyww
Test in Notepad.

Code: Select all

#Requires AutoHotkey v2.0
x::Send('{Numpad6}'), KeyWait(ThisHotkey)
Perhaps you get the idea here. You have a hotkey followed by ::. You can then use the :arrow: Send function to send any keys that you want.

Explained: Introduction and simple examples