Map editor (minimal): paint terrain + statics on the iso grid #113
Labels
No labels
alpha:wave-0
alpha:wave-1
alpha:wave-2
alpha:wave-3
area:assets
area:combat
area:ecology
area:infra
area:render
area:scripting
area:ui
area:world
enhancement
epic
migration
post-alpha
roadmap
tech-debt
type:bug
type:chore
type:design
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
marco/IsoMmo#113
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Part of the Alpha epic (pillar 2), split out of #89. A minimal, cross-platform map authoring tool that reads/writes the static-content format (#89) so maps (starting with the arena, #109) are authored visually instead of by hand-editing text.
Scope
Sspawn marker), via aTileMapWriterinSharedsymmetric withTileMap.Load(round-trip tested).land/andstatic/namespaces), intersected withStaticCatalog/BiomeVisualsso the editor can only place content the server can load — no hardcoded tile list (design principle: auto-discovery).S). (Resurrection points are out of scope: they shipped in #129 as GM-placedAnkhworld items inworld.sav, not map content — set in-game via/place ankh.)Out of scope
Note
Not a hard blocker: a ~40x40 arena could be hand-authored in the #89 format. Build the editor because it is reused forever and hand-authoring statics is error-prone; if alpha time is tight it may slip to post-alpha, but the world-building track needs it regardless.
Definition of Done
Base DoD applies on top.
land//static/namespaces, intersected withStaticCatalog(so saved maps always load). Adding a new static kind = oneStaticCatalogrow + its art (fully code-free palette awaits the data-driven catalog #143).Technical design — agreed (critical-design-review, 2026-07-22)
Verdict: go-with-changes — agreed. This is an offline authoring tool, not a game client: it sends no intents, touches no
World/wire/world.sav; its output is a content file the server re-validates at load exactly as a hand-authored map today.Decisions settled
Ankhitems (world.savplaced-items, #129), not map content. Arena res point =/place ankhin-game.StaticCatalog(Option A) — the palette offers only pack statics that areStaticCatalog.IsKnown, so a saved map always loads. A new static = 1StaticCatalogrow + art; the fully code-free palette is deferred to #143.Build shape
Shared: add a pureTileMapWriter(model →.map/.staticstext), symmetric withLoad, round-trip unit-tested.TileMapstays immutable — mutability lives only in the tool (achar[,]grid + static rows), rendered by producing aTileMapviaParse/Load(which doubles as validation).tools/IsoMmo.MapEditor.Core(no MonoGame, refsShared): mutable model; brush/rect/fill/erase; picking (wrapsIsoProjection.ScreenToGrid); palette derivation. Unit-tested >85%.tools/IsoMmo.MapEditor(MonoGame DesktopGL exe): window/input/draw glue; refsIsoMmo.Clientto reuseGridRenderer/Camera2D/AssetPackLoader/BiomeVisuals(WYSIWYG). Add default-1.0ZoomtoCamera2D(backward-compatible).just map-editor+docs/map-editor.md.Invariants Check (every line of
## Design checklist)Sharedwriter, editor Core+exe) are necessary, not a new system.TileMap.Load; save-time round-trip +StaticCatalogpalette gate guarantee loadability.GmCommand/admin claim; edits local files.Shared/Protocol; map content is files, not wire.SystemNotice; button labels are dev-tool chrome (like AssetEditor).World/Simulation/tick.World.csHARD GATE — N/A: doesn't touch GameServer.ScreenHARD GATE — ✓ (spirit): rootGameonly wires+delegates; logic inMapEditor.Core/renderer/input controller, not a god-class.MapEditor.Core+Sharedwriter; exe is glue; reusesIsoProjection.ScreenToGrid.land//static/names ∩BiomeVisuals/StaticCatalog; no hand list/switch..map/.statics), neverworld.sav/PlayerStore(this is why res-ankhs aren't map content).GameOptions/IConfiguration.NativeFileDialogper-OS fallbacks.PlaceholderArtshape); biome ground tint exception applies for legibility.[tile/[add) + external tools over binary.mul; we diverge to an offline WYSIWYG diffable-text editor (our content is committed text), following the authoring/runtime split.docs/map-editor.md+just map-editor; DoD refined above.No HARD GATE tripped.
Design delta (post-#143, 2026-07-22) — implementation kickoff
#143 landed, which simplifies this issue:
TileData(content/tiledata.txt). The earlier 'gate the palette onStaticCatalog' decision is moot; anything in tiledata is loadable by definition, and a new kind is one tiledata row + art (no code).IMapFormat.WriteMap/WriteTileData. The 'load→edit→save→reload identical' DoD is largely de-risked.UI decision (owner): MonoGame + Dear ImGui, maximally off-the-shelf (internal tool, zero time on GUI):
MonoGame.ImGuiNet(ready-made MonoGame↔ImGui backend, restores clean) — no hand-written renderer.NativeFileDialogfor open/save.GridRenderer/Camera2D/AssetPackLoaderfor the WYSIWYG iso canvas; add a default-1.0ZoomtoCamera2D(backward-compatible).Build shape:
tools/IsoMmo.MapEditor.Core(no MonoGame, unit-tested: mutable model + brush/rect/fill/erase + picking viaIsoProjection.ScreenToGrid+ palette fromTileData) andtools/IsoMmo.MapEditor(MonoGame DesktopGL exe: ImGui chrome + canvas glue).just map-editor+docs/map-editor.md. Res markers still out of MVP (GM-placed ankhs).