FF14 Using ALT as a momentary switch

Ask gaming related questions (AHK v1.1 and older)
PanCubano
Posts: 2
Joined: 30 Jul 2021, 19:43

FF14 Using ALT as a momentary switch

Post by PanCubano » 30 Jul 2021, 20:02

Hello Everyone! I need some help if possible with a AHK script that isn't working quite right. I'm helping a friend of mine try to solve a UI layout issue he's having with his hotbars. The solution in game that we came up with was to somehow take two hotbars and assign them to (I believe this is the right term) a momentary switch. Let me describe the issue in full to give a better picture:

User presses and holds:

ALT - Toggles Hotbar 2 On, Toggles Hotbar 1 Off

User releases:

ALT - Toggles Hotbar 1 On, Toggles Hotbar 2 Off

So we have half of this equation solved via creating macros in game to handle the toggling of the bars. The issue we're trying to solve is the switching function. What we've come up with is binding the two toggle macros to specific keybinds. We went with ALT+\ and CTRL+\ in game.

So what this essentially boils down to is to somehow get AHK to do the switching function. I've never really worked with AHK before, but I was able to write up something small that worked initially:

Code: Select all

Alt::
	send !{\}
	KeyWait, Alt

Alt up::
	send ^{\}
	KeyWait, Alt
And this worked! It toggled the bars exactly how we wanted. It did however get stuck in the wrong state sometimes if you toggled it quickly in succession (for ex. When Alt is up, Hotbar 1's default state is on and Hotbar 2's default state is off. It would sometimes be reversed when Alt is up.). But the biggest issue is he could no longer do any keystroke combinations of ALT+<anything> which defeats the purpose of this entire implementation.

I'm still testing scripts and trying to come up with something on my own, but I'm at a loss as to how to solve the keystroke combinations issue. Any ideas?

Thank you everyone in advance!!
User avatar
mikeyww
Posts: 26882
Joined: 09 Sep 2014, 18:38

Re: FF14 Using ALT as a momentary switch

Post by mikeyww » 30 Jul 2021, 20:59

Could try:

Code: Select all

Alt Up::Send ^\
Alt::
Send !\
KeyWait, Alt
Return
PanCubano
Posts: 2
Joined: 30 Jul 2021, 19:43

Re: FF14 Using ALT as a momentary switch

Post by PanCubano » 30 Jul 2021, 21:55

Got it figured out! My buddy was pouring over the doc as I tested different scripts and came to this one:

Code: Select all

~Alt::
    send !\
    Keywait, Alt

Alt up::
    send ^\
    Keywait, Alt
This allowed us to toggle the hotbar and keep keystroke combinations working!
Post Reply

Return to “Gaming Help (v1)”