mirror of
https://github.com/Kelsidavis/WoWee.git
synced 2026-05-10 11:03:51 +00:00
feat(editor): add WIFS JSON round-trip (--export/--import-wifs-json)
Closes the editing loop on the item-flag bit catalog: dump a
.wifs to JSON, hand-edit bitMask hex / flagKind / isPositive
(e.g. add a server-custom Heroic25man flag at bit 0x10000000,
re-tag NoLoot from Drop kind to Quality kind, mark BindToAccount
as positive for an account-wide-loot server), re-import to a
byte-identical binary.
Two dual-encoded fields:
- flagKind: int 0..6 OR "quality" / "drop" / "trade" /
"magic" / "account" / "server" / "misc"
- isPositive: bool OR int (machine-generated sidecars work
too)
Hex bitMasks export as raw uint32 — pasting "0x40000000" hex
values into JSON works directly.
Verified byte-identical round-trip on all three presets
(std / bind / srv). CLI flag count 1023 -> 1025.
This commit is contained in:
parent
0ceb70f3e7
commit
fd0e2cc50b
3 changed files with 150 additions and 0 deletions
|
|
@ -1963,6 +1963,10 @@ void printUsage(const char* argv0) {
|
|||
std::printf(" Print WIFS entries (id / bitMask hex / kind / +/- positivity / name) — handy for decoding raw item.flags integers\n");
|
||||
std::printf(" --validate-wifs <wifs-base> [--json]\n");
|
||||
std::printf(" Static checks: id+name+bitMask required, flagKind 0..6, no duplicate ids, no duplicate bitMasks (collision); warns on multi-bit masks (unusual, usually want a single bit)\n");
|
||||
std::printf(" --export-wifs-json <wifs-base> [out.json]\n");
|
||||
std::printf(" Export binary .wifs to a human-editable JSON sidecar (defaults to <base>.wifs.json)\n");
|
||||
std::printf(" --import-wifs-json <json-path> [out-base]\n");
|
||||
std::printf(" Import a .wifs.json sidecar back into binary .wifs (accepts flagKind int OR name; isPositive bool OR int)\n");
|
||||
std::printf(" --gen-weather-temperate <wow-base> [zoneName]\n");
|
||||
std::printf(" Emit .wow weather schedule: clear-dominant + occasional rain + fog (forest / grassland)\n");
|
||||
std::printf(" --gen-weather-arctic <wow-base> [zoneName]\n");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue