mirror of
https://github.com/Kelsidavis/WoWee.git
synced 2026-05-11 11:33:52 +00:00
feat(editor): add WSTM JSON round-trip (--export/--import-wstm-json)
Closes the editing loop on the stat-modifier-curve catalog: dump
a .wstm to JSON, hand-edit baseValue / perLevelDelta /
multiplier / level range / curveKind (e.g. retune SpellCrit base
from 1%% to 1.5%% for a higher-magic server, halve the
ManaPerSpirit slope by setting multiplier=0.5, restrict an armor
curve to lvl 60+ only by raising minLevel), re-import to a
byte-identical binary.
curveKind dual-encoded: int 0..6 OR human-readable name ("crit"
/ "hit" / "power" / "regen" / "resist" / "mitigation" / "misc").
Float fields (baseValue, perLevelDelta, multiplier) round-trip
through JSON's native number type — IEEE 754 single precision
preserves exactly.
Verified byte-identical round-trip on all three presets
(crit / regen / armor). CLI flag count 1081 -> 1083.
This commit is contained in:
parent
9a85cc029e
commit
48ca202716
3 changed files with 150 additions and 0 deletions
|
|
@ -2079,6 +2079,10 @@ void printUsage(const char* argv0) {
|
|||
std::printf(" Print WSTM entries (id / kind / minLvl / maxLvl / baseValue / perLevelDelta / multiplier / value@lvl80 sample / name)\n");
|
||||
std::printf(" --validate-wstm <wstm-base> [--json]\n");
|
||||
std::printf(" Static checks: id+name required, curveKind 0..6, minLevel<=maxLevel, no duplicate ids; warns on maxLevel>80, multiplier=0 (always 0), multiplier<0 (inverts), perLevelDelta<0 (shrinks)\n");
|
||||
std::printf(" --export-wstm-json <wstm-base> [out.json]\n");
|
||||
std::printf(" Export binary .wstm to a human-editable JSON sidecar (defaults to <base>.wstm.json)\n");
|
||||
std::printf(" --import-wstm-json <json-path> [out-base]\n");
|
||||
std::printf(" Import a .wstm.json sidecar back into binary .wstm (accepts curveKind int OR curveKindName string)\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