Commit graph

29 commits

Author SHA1 Message Date
Kelsi
8fb7690ea1 feat(editor): add --export-png CLI for terrain preview rendering
Renders heightmap, normal-map, and zone-map PNGs alongside a
WHM/WOT terrain pair. Useful for portfolio screenshots, ground-
truth map comparison, and quick visual validation without
launching the GUI.
2026-05-06 08:22:26 -07:00
Kelsi
21078f8806 feat(editor): add --build-woc CLI for headless collision generation
Loads a WHM/WOT terrain pair and writes a .woc collision mesh
alongside it. Terrain triangles only (no WMO overlays — those need
the asset manager) but enough for first-pass walkability while
authoring.

Verified end-to-end: scaffold-zone → build-woc → info-woc reports
32k triangles for a flat 256-chunk tile.
2026-05-06 08:21:14 -07:00
Kelsi
81832ea676 feat(editor): add --pack-wcp CLI for headless zone packaging
Mirrors --unpack-wcp. Accepts either a zone name (auto-resolved
under custom_zones/ then output/) or a directory path. Default
output is <name>.wcp in the current directory. Combined with
--scaffold-zone and --unpack-wcp, the editor can do the full
zone authoring round-trip from the command line.
2026-05-06 08:19:42 -07:00
Kelsi
b2fa4cd509 feat(editor): add --unpack-wcp CLI for headless extraction
Mirrors --info-wcp / --list-wcp. Default destination is
custom_zones/ (matches the GUI's preferred location). With both
this and --scaffold-zone, the editor binary can fully bootstrap
a zone install without launching the GUI.
2026-05-06 08:18:21 -07:00
Kelsi
ab5d574758 feat(editor): add --scaffold-zone CLI for empty zone bootstrap
Creates custom_zones/<slug>/ with a flat-terrain WHM, default WOT,
and minimal zone.json — score 3/7 on --validate, ready to open in
the GUI for further authoring. Saves the round-trip of launching
the GUI just to make a starter directory.
2026-05-06 08:17:33 -07:00
Kelsi
a0876bbe3d fix(cli): error on non-GUI options that are missing their argument
Previously '--info-wcp' (no path) silently dropped into the GUI
because the option-parse loop's i+1<argc guard hid the typo. Pre-
scan and bail out with a helpful message before trying to start
the editor, so users get fast feedback on bad invocations.
2026-05-06 08:08:05 -07:00
Kelsi
9d944ed2f9 feat(editor): add --list-wcp CLI to print every file in a WCP archive
--info-wcp gives counts and totals; --list-wcp gives the full file
listing sorted by path. Useful for spotting missing texture/model
entries before unpacking and shipping a zone.
2026-05-06 07:30:26 -07:00
Kelsi
a2a554dff7 feat(editor): add --info-quests CLI for quests.json summary
Completes the --info-* family. Reports total/chained quest counts,
reward/item counts, total XP awarded, objective-type breakdown
(kill/collect/talk), and any quest-chain validation errors. Lets
zone authors spot broken chains, missing rewards, and lopsided XP
balance from the command line.
2026-05-06 07:16:27 -07:00
Kelsi
df2027463a feat(editor): add --info-objects CLI for objects.json summary
Mirrors --info-creatures and the other format inspectors. Reports
total placement count, M2/WMO breakdown, unique source paths, and
scale range. Useful for spotting empty zones, accidental scale
extremes, or duplicated placements before packing.
2026-05-06 07:15:40 -07:00
Kelsi
93e67ae31b feat(editor): add --info-creatures CLI for creature.json summary
Mirrors the existing --info-wom/wob/woc/wot/wcp inspectors. Reports
total spawn count, hostile/questgiver/vendor/trainer flag counts,
behavior breakdown (stationary/wander/patrol), and unique displayId
count. Useful for triaging zone NPC content from the command line.
2026-05-06 07:14:42 -07:00
Kelsi
5af4bba556 feat(validate): report file counts and per-format invalid totals
The previous --validate output told you whether *some* file of each
type existed, which was hard to act on for partially-valid zones.
Now reports the per-format file count and how many failed magic
validation, e.g. 'WOM (12 invalid: 2)' so a zone author can spot
missing or corrupted models without grepping through file listings.
2026-05-06 07:12:04 -07:00
Kelsi
6651eccf3b feat(editor): add --info-wot CLI for inspecting terrain metadata
Mirrors the existing --info-wom/--info-wob/--info-woc/--info-wcp
inspectors. Reports the tile coord, populated chunks, layer count,
water count, texture/doodad/WMO counts, and computed height range
across all chunks. Useful for triaging zones from the command line
without opening the GUI.
2026-05-06 06:58:34 -07:00
Kelsi
079ff5bfb5 feat(editor): --info-wcp CLI prints content pack metadata
Reports name/author/description/version/format/mapId, total file count,
per-category breakdown (terrain/model/building/texture/data), and total
on-disk bytes. Useful for inspecting third-party WCPs before importing
or for sanity-checking your own exports.
2026-05-06 04:36:40 -07:00
Kelsi
f18976ced9 feat(editor): --info-woc CLI prints collision mesh metadata
Completes the --info* CLI family. Reports tile coords, triangle count,
walkable/steep classification breakdown, and world-space bounds — useful
for verifying that collision exports cover the expected area.
2026-05-06 03:17:10 -07:00
Kelsi
8787b13dc1 feat(editor): --info-wob CLI prints WOB building metadata
Companion to --info for WOM. Reports name, group/portal/doodad counts,
total vertex/triangle/material counts. Useful for verifying converted
WMOs and debugging building rendering issues without launching the GUI.
2026-05-06 03:15:43 -07:00
Kelsi
683d703fbc feat(editor): --info <wom> CLI prints model metadata for inspection
Useful for verifying WOM exports and debugging conversion issues without
loading the GUI. Accepts either /path/to/file.wom or /path/to/file
(loader expects no extension). Reports version, name, geometry counts,
texture/bone/animation/batch counts, and bound radius.
2026-05-06 03:14:12 -07:00
Kelsi
0be537e73d feat(editor): --validate <zoneDir> CLI scores zone open-format completeness
New CLI option that runs ContentPacker::validateZone on a zone directory
and prints the open-format score (0-7) with per-file breakdown including
magic-byte validity. Exits 0 if 7/7, 1 otherwise — useful for CI checks
on exported zones.
2026-05-06 03:09:56 -07:00
Kelsi
b30b44ab7e chore(cli): --convert-m2 reports WOM version + batch count in success message 2026-05-06 02:45:23 -07:00
Kelsi
fde1fa8129 fix(editor): batch convert CLI has visible output and proper exit codes
Some checks are pending
Build / Build (arm64) (push) Waiting to run
Build / Build (x86-64) (push) Waiting to run
Build / Build (macOS arm64) (push) Waiting to run
Build / Build (windows-arm64) (push) Waiting to run
Build / Build (windows-x86-64) (push) Waiting to run
Security / CodeQL (C/C++) (push) Waiting to run
Security / Semgrep (push) Waiting to run
Security / Sanitizer Build (ASan/UBSan) (push) Waiting to run
- --convert-m2 and --convert-wmo now print progress and results to
  stdout (was LOG_INFO to log file only, invisible to user)
- Failures return exit code 1 (was always 0, breaking scripting)
- Success output shows vertex/bone counts (M2) or group count (WMO)
- Error messages go to stderr for proper pipe handling
2026-05-05 16:57:06 -07:00
Kelsi
1337a963a0 fix(editor): CLI output visible on stdout (was silent LOG_INFO)
--help, --version, and --list-zones now print to stdout via printf
instead of LOG_INFO which writes to log file only. Users running
CLI commands would see no output at all — critical first-impression
bug for new users.

Also updated --version format list to include WOC.
2026-05-05 16:54:03 -07:00
Kelsi
4fc0361f7a feat: complete client integration for all 6 open formats
- Wire WOB buildings into WMO render pipeline (loads→converts→renders)
- Implement JSON DBC loading in DBCFile::loadJSON() with nlohmann/json
- Wire JSON DBC override into AssetManager (custom_zones/output scan)
- Add WMO→WOB conversion with full geometry (fromWMO)
- Replace placeholder WOB export with real WMO→WOB conversion in editor
- Add --convert-wmo CLI flag for batch WMO→WOB conversion
- Store discovered custom zones on Renderer with getCustomZones() accessor
- Add isCustomZone_ member to TerrainManager

All 6 Blizzard format replacements now fully load in the client:
  ADT→WOT/WHM, WDT→zone.json, BLP→PNG, DBC→JSON, M2→WOM, WMO→WOB
2026-05-05 12:41:19 -07:00
Kelsi
d8f2388635 milestone(editor): commit #200 — v1.0.0 complete, 11.5k lines, all formats open
200 commits building a complete world editor with novel open file
formats from scratch in a single development session.

Final stats:
- 11,532 lines across 55 files
- 6 editor modes, 30+ terrain tools, 3 noise types
- 5 novel binary formats: WHM1, WOM1, WOB1, WCP1, WOT
- All 6 Blizzard formats replaced with open alternatives
- 4/6 formats fully loading in client (terrain, textures, models, buildings)
- CLI: --help, --version, --list-zones, --convert-m2
- Project system with git collaboration
- Full content pipeline: create → export → pack → share → load

By Kelsi Davis
2026-05-05 12:21:00 -07:00
Kelsi
0fce340aa0 docs(editor): add --list-zones and --version to CLI help output 2026-05-05 12:19:53 -07:00
Kelsi
8ac36e2f05 feat(editor): --list-zones CLI flag to discover custom zones without GUI 2026-05-05 12:18:31 -07:00
Kelsi
c75337ed2c fix(editor): sync --version CLI output to v1.0.0 2026-05-05 12:16:21 -07:00
Kelsi
8f7a70e8cd feat(editor): --version CLI flag shows editor version and format info 2026-05-05 11:53:12 -07:00
Kelsi
e7cf125fda docs(editor): improved CLI help with format info and all options 2026-05-05 10:52:17 -07:00
Kelsi
4b94640cae feat(editor): CLI batch convert mode (--convert-m2) for M2→WOM conversion
- wowee_editor --convert-m2 <path> --data <datadir> converts a single
  M2 model to WOM open format without launching the GUI
- Output goes to output/models/ with same path structure
- Useful for batch scripts to convert entire asset directories
- Example: wowee_editor --data Data --convert-m2 creature\\bear\\bear.m2
2026-05-05 10:50:36 -07:00
Kelsi
2980ca83e7 feat(editor): add standalone world editor (rough/WIP)
Standalone wowee_editor tool for creating custom WoW zones.
This is a rough initial implementation — many features work but
M2/WMO rendering still has issues (frame sync, texture layout
transitions) and needs further polish.

Terrain:
- Create new blank terrain with 10 biome types (Grassland, Forest,
  Jungle, Desert, Barrens, Snow, Swamp, Rocky, Beach, Volcanic)
- Load existing ADT tiles from extracted game data
- Sculpt brushes: Raise, Lower, Smooth, Flatten, Level
- Chunk edge stitching prevents seams between tiles
- Undo/redo (100-deep stack, Ctrl+Z/Ctrl+Shift+Z)
- Save to WoW ADT/WDT format

Texture Painting:
- Paint/Erase/Replace Base modes
- Full tileset texture browser (1285 textures from manifest)
- Per-zone directory filtering and search
- Alpha map editing with 4-layer limit (auto-replaces weakest)

Object Placement:
- M2 and WMO model placement with full manifest browser (11k M2s, 2k WMOs)
- M2Renderer + WMORenderer integrated (loads .skin files for WotLK)
- Ghost preview follows cursor before placing
- Ctrl+click selection, right-click context menu
- Transform gizmo (Move/Rotate/Scale with axis constraints)
- Position/rotation/scale editing in properties panel

NPC/Monster System:
- 631 creature presets scanned from manifest, categorized
  (Critters, Beasts, Humanoids, Undead, Demons, etc.)
- Stats editor: level, health, mana, damage, armor, faction
- Behavior: Stationary, Patrol, Wander, Scripted
- Aggro/leash radius, respawn time, flags (hostile/vendor/etc.)
- Save creature spawns to JSON

Water:
- Place water at configurable height per chunk
- Liquid types: Water, Ocean, Magma, Slime
- Rendered as translucent colored quads
- Saved in ADT MH2O format

Infrastructure:
- Free-fly camera (WASD/QE, right-drag look, scroll speed)
- 5-mode toolbar: Sculpt | Paint | Objects | Water | NPCs
- Asset browser indexes full manifest on startup
- Editor water/marker shaders (pos+color vertex format)
- forceNoCull added to M2Renderer for editor use
- AssetManifest::getEntries() and AssetManager::getManifest() exposed

Known issues:
- M2/WMO rendering may not display on first placement (frame index
  sync between update/render was misaligned — now fixed but untested
  end-to-end)
- Validation layer errors on shutdown (resource cleanup ordering)
- Object placement on steep terrain can miss raycast
- No undo for texture painting or object placement yet
2026-05-05 03:47:03 -07:00