mirror of
https://github.com/Kelsidavis/WoWee.git
synced 2026-05-10 02:53:51 +00:00
Two more boilerplate patterns repeated across cli_gen_mesh.cpp:
• init: 64 sites set wom.name = path-stem and wom.version = 3
in 3 lines. Hoisted to initWomDefaults(wom, base) — 1 line.
• save: 65 sites had identical 5-line "if save fails, fprintf
stderr and return 1" blocks. Hoisted to saveWomOrError(wom,
base, cmdName) returning bool, used as
`if (!saveWomOrError(...)) return 1;` — also 1 line.
Net cli_gen_mesh.cpp drops by ~254 lines (from 6424 to 6170).
Output bytes verified identical: firepit surface area 2.1100
m² unchanged, cube vertex/index/bounds counts unchanged.
After this batch's prior helpers (addFlatBox, addVertex,
stripExt, finalizeAsSingleBatch, parseOpt*), a typical new
gen-mesh handler now needs zero copy-paste boilerplate to
get a working primitive — every shared bit lives in
cli_box_emitter.hpp and cli_arg_parse.hpp.
|
||
|---|---|---|
| .. | ||
| asset_extract | ||
| auth_login_probe | ||
| auth_probe | ||
| blp_convert | ||
| dbc_to_csv | ||
| editor | ||
| asset_pipeline_gui.py | ||
| backup_assets.sh | ||
| diff_classic_turtle_opcodes.py | ||
| gen_opcode_registry.py | ||
| generate_ffx_sdk_vk_permutations.sh | ||
| m2_viewer.py | ||
| opcode_map_utils.py | ||
| validate_opcode_maps.py | ||