Skip to content

0xWhoa/a3_keymaker

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

4 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

Rendered keymap โ€” fully collapsed initial view

Keymaker - ARMA 3 Keybind Explorer (a3_keymaker)

See every Arma 3 keybinding in one searchable HTML page. Vanilla, old-style mods, and CBA addons โ€” all together, grouped exactly the way the in-game dialog shows them.

  • ๐Ÿ” Filter by category, action name, or keybind
  • ๐Ÿ“Œ Build a cheatsheet by pinning the rows you care about
  • โš  Find and resolve keybind collisions

๐Ÿ“ธ What you'll get

A single self-contained HTML file. The page has two top-level collapsable sections โ€” Configure Base and Configure Addons โ€” each with sub-categories (Common, Weapons, View, Commandโ€ฆ) preserving the in-game order.

Rendered keymap โ€” sections expanded showing categories

๐Ÿ” Filter by category, action name, or keybind.

Filtering for "radio" โ€” matches action names across multiple categories

Filtering for "+T" โ€” matches keybinds across multiple categories

๐Ÿ“Œ Build your cheatsheet by pinning the rows you actually use.

Cheatsheet view โ€” Show Pinned active, โš  markers visible

โš  Find and resolve keybind collisions (hover or click the โš  marker)

Hover any โš  marker to see every other action sharing that key

Click any โš  to isolate the conflict group โ€” only the keys shared with the clicked action stay highlighted


๐Ÿš€ Quick start

Requires Python 3.10+ and Arma 3.

๐Ÿ’ก No Python? Grab the standalone Windows binary from the latest release โ€” drop it anywhere and run a3_keymaker.exe instead of a3_keymaker in the steps below. Each release lists a SHA-256 hash and VirusTotal scan link for verification.

Unsigned binary โ€” Windows may warn on first run. Click More info โ†’ Run anyway.

  1. Open a terminal in the project directory
  2. Setup once (Python users): pip install -e . โ€” skip if using the .exe
  3. Execute Keymaker: run a3_keymaker โ€” copies the Arma 3 script to your clipboard
  4. In Arma 3: pause the game, paste the script into Debug Console, click LOCAL EXEC. The script waits for the Controls dialog to open.
  5. Open the Controls dialog: The script walks through the categories extracting keybindings. Then click Configure Addons and let the script walk through the addons.

๐Ÿ’ก When the script finishes, the keybinding dump will be on your clipboard.

  1. Save the dump to a text file (e.g. dump.txt)
  2. Execute Keymaker with the dump file: a3_keymaker dump.txt โ€” writes the final HTML file.

Full step-by-step below. โฌ‡


๐Ÿ’ป Setup (Python users, ~30 seconds)

cd a3_keymaker
pip install -e .

Installs the a3_keymaker CLI on your PATH. You only do this once.


๐ŸŽฎ Generate your keymap (~2 minutes)

1. Launch Arma 3 with your usual modset.

2. Open Singleplayer mode.

Play โ†’ Play Singleplayer (or just press Enter). You'll spawn into the game.

3. Open the Debug Console.

Press Esc โ†’ you should see the Debug Console in the pause menu.

4. Copy the extractor SQF script to your clipboard.

In a terminal (no arguments):

a3_keymaker

You'll see "Keybind extraction script copied to clipboard. Paste it into Arma 3's Debug Console (LOCAL EXEC)."

5. Paste the script into the Debug Console's Execute box and click LOCAL EXEC.

โš  Important: the script runs silently in the background. You won't see any output yet. This is expected โ€” it's waiting for you to open the Controls dialog.

6. Open OPTIONS โ†’ CONTROLS.

The SHOW dropdown will visibly start cycling through every category. Don't touch anything.

7. Click CONFIGURE ADDONS when the cycling stops.

The ADDON dropdown will cycle through every mod.

8. Click CANCEL when cycling stops again.

9. Paste your clipboard into a text file.

For example, C:\tmp\dump.txt.

10. Render the HTML.

a3_keymaker C:\tmp\dump.txt

Writes YYYY_MM_DD-Arma3_Keymaker.html (today's date) in the current directory. Open it in any browser. โœ…

๐Ÿ’ก Clipboard not cooperating? Open extract_all.sqf in any text editor, select all, and copy directly.

Optional flags

a3_keymaker C:\tmp\dump.txt -o C:\path\to\keymap.html --json C:\path\to\keymap.json
Flag Default Purpose
-o, --output YYYY_MM_DD-Arma3_Keymaker.html Output HTML path
--json (none) Also emit a parallel JSON dump (handy for tooling, diffs, automation)

๐Ÿ“– Using the keymap

๐Ÿ” Filter

  • Substring match against category, action label, action ID, and key text in one shot.
  • Multiple words are AND'd: ctrl m matches rows with both "ctrl" and "m" anywhere.
  • Sections and categories with matching rows auto-expand while filtering. Manual open/closed state is preserved when the filter clears.
  • Esc clears any active filter. Press again to collapse everything. Spam Esc to fully reset.

๐Ÿ“Œ Pin / Show Pinned / Hide Unbound

  • Pin any row or category โ€” pin checkboxes appear on hover. Pins persist across refreshes (stored in your browser).
  • Show Pinned (N) toggle โ€” show only your pinned rows.
  • Hide Unbound (N) toggle โ€” hide rows with no key assigned.
  • Unpin all wipes everything in one click.
  • Pinning a category pins every visible row in it โ€” combine with the filter to bulk-pin a subset.

โš  Investigate conflicts

  • A โš  marker appears next to any key bound by more than one action.
  • Hover for the list of all parties involved.
  • Click any โš  to isolate the page to that conflict group โ€” the clicked marker becomes an amber chip. Click again (or press Esc) to exit.
  • Inside collision view, only the keys actually shared with the clicked row are highlighted red โ€” so context-disambiguated overlaps (W = walk forward / accelerate vehicle) don't visually scream at you.

๐Ÿงญ Navigate the page

  • Sticky stack โ€” the controls bar, section summary, === Mods === separator, and current category summary all stick to the top while you scroll. You always know where you are.
  • Collapse all / Expand all buttons in the action bar.
  • Hover any action label โ†’ tooltip shows the full path (Configure Base > Category > Action) so you can navigate straight to it in-game.
  • Open/closed layout survives refreshes (also saved in your browser).

๐Ÿ“Š What's covered

The extractor combines five data sources to maximize coverage:

Source Covers
UI walk of CONTROLS dialog Every label in every category, in dropdown order
actionKeysNames over the BIS wiki's 446 engine action IDs Every vanilla action's current binding
CfgDefaultKeysPresets >> * >> Mappings (all 8 sibling presets, deduped) Old-style mod IDs that have a default key
CfgUserActions walk Old-style mod IDs without default keys
UI walk of CONFIGURE ADDONS Every CBA-registered mod's bindings, label + key inline

For a typical heavily-modded install: ~1000 actions across ~50 categories.


For developers

Project layout

a3_keymaker/
โ”œโ”€โ”€ pyproject.toml
โ”œโ”€โ”€ README.md                       # this file
โ”œโ”€โ”€ ARCHITECTURE.md                 # design rationale, component-level details
โ”œโ”€โ”€ src/
โ”‚   โ””โ”€โ”€ a3_keymaker/
โ”‚       โ”œโ”€โ”€ __init__.py
โ”‚       โ”œโ”€โ”€ cli.py                  # CLI entry point
โ”‚       โ”œโ”€โ”€ model.py                # Action, Report dataclasses
โ”‚       โ”œโ”€โ”€ parser.py               # SQF dump โ†’ ParsedDump (handles "" escaping + clipboard mojibake)
โ”‚       โ”œโ”€โ”€ merger.py               # ParsedDump + wiki JSON โ†’ list[Action]
โ”‚       โ”œโ”€โ”€ render.py               # list[Action] โ†’ self-contained HTML
โ”‚       โ”œโ”€โ”€ data/                   # vanilla_actions.json (446 wiki entries) + keymaker_banner.png
โ”‚       โ””โ”€โ”€ scripts/                # extract_all.sqf (in-game extractor)
โ””โ”€โ”€ tests/
    โ”œโ”€โ”€ test_pipeline.py            # 18 tests, runs against a captured dump fixture
    โ””โ”€โ”€ fixtures/sample_dump.txt    # real dump used by the test suite

Development & Testing

pip install -e .[dev]
pytest -v

The fixture tests/fixtures/sample_dump.txt is a real captured dump from a heavily-modded install, so the tests exercise every code path against realistic data.

See ARCHITECTURE.md for design rationale and component-level details (parser, merger, renderer internals; SQF extractor phases; sticky-stack rendering).