Kelsidavis-WoWee/tools/editor/cli_action_bars_catalog.hpp

13 lines
233 B
C++
Raw Normal View History

feat(editor): add WACT (Action Bar Layout) open catalog format Open replacement for the hardcoded per-class default action bar bindings. Defines which abilities auto-populate which action button slots when a new character is created or a class is reset. A Warrior's button 1 binds Heroic Strike, button 2 Charge, button 3 Rend, etc. — new characters of that class get those buttons pre-populated so the action bar isn't empty on first login. Distinct from WKBD (Keybindings) which maps physical keys to action button slots — WACT maps action button slots to abilities. The two together complete the default-control configuration: Key 1 -> Action Slot 1 (WKBD) -> Heroic Strike (WACT). Seven barMode values cover the major action bar contexts: - Main (slots 0-11, standard 12-button bar) - Pet (hunter/warlock pet action bar) - Vehicle (mounted/vehicle action bar) - Stance1/2/3 (warrior battle/defensive/berserker; druid bear/cat/tree) - Custom (server-custom bar overlay) Cross-references back to WCHC (classMask layout), WSPL (spellId for the bound ability), and WIT (itemId for item-macro bindings like Hearthstone in slot 12). findByClass(classBit, barMode) returns the bindings sorted by buttonSlot — used directly by character creation to populate action bars. Three preset emitters: --gen-act (10 Warrior starter bindings on Main bar with canonical 3.3.5a abilities), --gen-act-mage (10 Mage starter bindings including Counterspell + Polymorph), --gen-act-pet (10 Hunter pet-bar bindings using barMode=Pet for Attack/Stance/Bite/Claw/Dismiss). Validation enforces id+name+classMask presence, barMode 0..6, no duplicate ids; warns on: - buttonSlot > 143 (max is 12 bars × 12 slots = 144) - both spellId and itemId set (engine prefers spellId, item is silently ignored) - both spellId=0 AND itemId=0 (button will render empty) - (classMask + barMode + buttonSlot) collisions for overlapping classes — multiple bindings fighting for the same physical slot Wired through the cross-format table; WACT appears in all 18 cross-format utilities. Format count 94 -> 95; CLI flag count 1083 -> 1088.
2026-05-10 00:11:53 -07:00
#pragma once
namespace wowee {
namespace editor {
namespace cli {
bool handleActionBarsCatalog(int& i, int argc, char** argv,
int& outRc);
} // namespace cli
} // namespace editor
} // namespace wowee