Starcraft 2 woes: Hotkey system

nvmd
5 min readNov 16, 2017

Ever since SC2’s inception, one of the things Blizzard set out to improve compared to the game’s older brothers was the hotkey system. And they did, so SC2 came with more convenient hotkey customization capabilities. But that wasn’t without some caveats, that need fixing going forward.

Compared to Warcraft 3, whose hotkey editing was done through a unnecessarily confusing, painful, and hard to get right way by messing around with the infamous CustomKeys.txt, SC2 comes with a in-game hotkey editor that’s easy to use and has preset layouts. And if you ever needed to bind more than 2 hotkeys to a single function, you could always do so by editing the *.SC2Hotkeys file. Fully customized hotkey layouts became possible.

However, possible doesn’t mean practical, particularly in this case. Issues with the system since the beginning hinder both functionality, and potential of this tool to help interacting with the game. The issues are listed below from broader to more specific. For the sake of clarity, consider modes to be Co-Op, Campaign, Arcade and Ladder.

Hotkeys shared globally across all modes

If you’re a programmer, this is what happens when you break encapsulation in OOP design. This is consistency done wrong. Since hotkeys are global and common to all modes, switching between them generally requires you to adjust your hotkeys each time because of conflicts. It happens mostly when you switch between Campaign and Ladder, as the former has more units and more abilities, sometimes making you change hotkeys for certain abilities that are identical across modes. This forces people to create separate custom hotkey profiles for each mode, and also forces them to manually switch between them each time they want to play the other mode.

Changing the hotkeys already bound, like the Spectre’s Nuke, also change Ghost’s abilities when you play Ladder

Inconsistency

Some hotkeys are correctly bound for Ladder, but they aren’t in the Campaign. Hotkeys also don’t deal well with toggle conflicts, and abilities that disable toggleable abilities are unbound. (FIXED in patch 4.1)

MULE bound for CC, but not for Orbital Command.

Co-Op hotkeys are a nightmare

Here’s why I don’t play Co-Op. No, seriously. It’s a literal nightmare that will turn off every custom layout user out there.

I’m pretty sure Alarak doesn’t need all this, as well as every other commander, yet all of them share this ludicrous nonsense.

Hotkey file is another nightmare

The confusing syntax and lack of uniformity points to commands being initially written by someone who definitely hated his job; the lexical order sorting and bottom-up hierarchy of commands (secondary entity coming before primary) make parsing and dealing with it very confusing. But above all, total lack of modularity, which only worsens as you add more hotkeys, consequently worsening all of these 3 problems. All contribute to make sure no one will or should ever touch it. See it for yourself.

Also special mention to the bug(?) that shows the hotkey setup of the last mode you played, even after you already left the game. I remember someone saying this one is intentional, as it’s the only way to change settings of a mode through the client outside of an actual match.

Out of the Campaign, but showing Campaign layout.

Last but not least, I would love to know if there are XML or similar files somewhere that lists all hotkey commands and their relationships with regards to conflicts so we could use it to create a web-based custom keys generator. Unfortunately, I’m not aware of its existence. And even if that was the case, it’s hard to digest the idea that we should depend on 3rd parties.

How to fix it

The ideal fix would be a major rework of the hotkey system into something more fitting for the current state of the game, as well as the ability to scale as needed, and improving and maintaining user experience.

Since the hotkeys file is the foundation of it all, change the syntax for something more readable. Fix the weird names, use PascalCase, reorder the commands to a “primary entity/secondary entity” hierarchy and also apply a top-down sorting hierarchy to the commands to make them more human-friendly. Ludicrous? Tedious? Sure, but it has to be done.

Fix the Co-Op hotkeys. Again, fix Co-Op hotkeys. At least make it make sense.

Next is fixing the inconsistencies by unifying the commands across modes, especially Campaigns. In other words, make so the command Calldown:MULE, disabling toggleable abilities, etc, work across all modes if they do the same thing and/or belong to the same unit, regardless of whether it’s exactly the same unit (WoL MULE vs LotV MULE, etc). This means that, unlike sharing hotkeys globally, the first time I play a new mode, every layout will create a copy from the Versus layout with the relevant commands and hotkeys to the new particular mode, and start from there. From that time onward, whenever I switch from any mode to another, whether Allow Toggle Conflicts is enabled or not, all abilities I have already bound to a key previously, even in other modes, will already be defined in the hotkeys file and in the Campaign, with the Campaign-specific units and abilities being the only ones left.

And most importantly, the one that helps or even partially fix the other issues: modularity. Create different folders with different hotkeys files for each one of them for each mode, including each of the Campaigns and each Arcade map, on demand. Allow us to have different hotkeys files for the same mode or Arcade map. And next, add a drop-down menu on the hotkey editing screen for changing between Campaigns’ hotkeys, other modes, and Arcade maps, and changing between multiple files of the same mode or map in case I have different setups. That way we won’t have to rely on the post game hotkey layout bug to change hotkeys outside of the game mode.

Modularity alone solves the inconsistency problem, especially when paired up with what I said in the paragraph above; it solves the encapsulation problem; and it helps with the scalability problem of the hotkeys files. And while it’s the most efficient way, I posted the other ideas out of pure hope.

That’s all for now, folks.

--

--