One key to cycle between two others
Posted: 07 Oct 2018, 20:05
Through research I found lots of questions & answers that dance around what I would like to do
GOAL:
Press "MButton" and draws Machine Gun which is key "3"
Press "MButton" again and switches to Knife which is key "4"
Press "MButton" again and switches back to Machine Gun key "3"
So each time I press "MButton", weapons are cycled between "3" & "4" so my character will have one or the other weapon, depending on how many times I press "MButton"
This page:>>>> https://autohotkey.com/board/topic/5614 ... ne-hotkey/<<<
MButton::
key++
if key = 1
Send, 3
else if key = 2
{
Send, 4
key = 0
}
Return
This seemed to be on the right track and tried multiple variations of what appeared might work, but did nothing in game
Any assistance would be greatly appreciated, Eric
GOAL:
Press "MButton" and draws Machine Gun which is key "3"
Press "MButton" again and switches to Knife which is key "4"
Press "MButton" again and switches back to Machine Gun key "3"
So each time I press "MButton", weapons are cycled between "3" & "4" so my character will have one or the other weapon, depending on how many times I press "MButton"
This page:>>>> https://autohotkey.com/board/topic/5614 ... ne-hotkey/<<<
MButton::
key++
if key = 1
Send, 3
else if key = 2
{
Send, 4
key = 0
}
Return
This seemed to be on the right track and tried multiple variations of what appeared might work, but did nothing in game
Any assistance would be greatly appreciated, Eric