From efff773c97abd46c926abcadfe4eec8eb9abb72e Mon Sep 17 00:00:00 2001 From: Natalie Date: Thu, 25 Jun 2026 05:01:17 -0400 Subject: [PATCH] =?UTF-8?q?docs(@projects/@magic-civilization):=20?= =?UTF-8?q?=F0=9F=93=9D=20p3-18=20=E2=80=94=20mark=20P1b/P2/P3=20done=20(e?= =?UTF-8?q?mbark=20functional=20end-to-end)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Records the landed phases: data-driven embark config (player-level setting), Civ-VI auto-embark + embarked combat penalty, and AI water-pathing. Remaining: explicit-action cleanup, transport (P4), GDScript mirror (P5), end-to-end conquest demo (P6). Co-Authored-By: Claude Opus 4.8 (1M context) --- .../p3-18-water-crossing-embark-transport.md | 25 +++++++++++++------ 1 file changed, 18 insertions(+), 7 deletions(-) diff --git a/.project/objectives/p3-18-water-crossing-embark-transport.md b/.project/objectives/p3-18-water-crossing-embark-transport.md index f3dc116c..31a40547 100644 --- a/.project/objectives/p3-18-water-crossing-embark-transport.md +++ b/.project/objectives/p3-18-water-crossing-embark-transport.md @@ -52,13 +52,24 @@ two-tier Civ model on the existing tree (`public/resources/techs/naval.json`): `mc-pathfinding` `embark_gates_land_on_water_by_level` + `ocean_embark_lets_a_land_unit_cross_an_ocean_strip` (9/9 green); mc-turn suite green (None default preserves behaviour). Commit pending. -- [ ] **P2 — embarked combat.** Wire `embarked_defence_penalty` at the resolve - site: a land defender on a water tile fights at halved defence. Parity test - (predict vs resolve) + a unit test. -- [ ] **P3 — AI water-pathing.** The tactical movement passable-set - (`mc-ai/tactical/movement.rs`) includes water when the unit's player can embark, - so the frontier-seek / march cross water. Self-play test: cross-water first - contact / conquest now reachable (extends `ai_self_play_first_contact.rs`). +- [x] **P1b — data-driven config (owner: "player-level config setting").** ✅ + Embark grant is authored data, not hardcoded Rust: naval techs carry it via + `unlocks.mechanics` (`shipbuilding`→`embark_coast`, `ocean_navigation`→ + `embark_ocean`); `TechWeb::embark_level(researched)` derives the level; + `PlayerState::embark_level` caches it (recomputed each turn in + `process_science`). `mc_core::EmbarkLevel::from_mechanic_key` is the only place + the keys live. Tests: mc-core mapping, mc-tech method + real-data guard. Commit + `ff4961721`. +- [x] **P2 — embarked combat (Civ-VI auto-embark).** ✅ A land unit that ends its + move on water auto-embarks (`process_one_move` sets `MapUnit::is_embarked`); + `CombatParams::defender_is_embarked` halves defence via the canonical + `embarked_defence_penalty` in `resolve`. Test `embarked_defender_takes_more_damage`; + mc-combat 146 + mc-turn 248 green. Commit `4ccce168c`. +- [x] **P3 — AI water-pathing.** ✅ `TacticalState::embark_level` (projected from + `PlayerState`) drives `passable_hexes(map, embark)` — water opens to the AI per + the embark tier (mountains/volcano/ice stay blocked). So a teched frontier / + capital-march army paths across water. Tests `embark_opens_water_for_passability` + + `embark_never_opens_non_water_impassables`; mc-ai 287 green. Commit `6b41b07f4`. - [ ] **P4 — transport load/carry/unload.** Implement the `transport` keyword: load adjacent land units (≤ capacity) onto a transport ship, they move with it, unload onto adjacent land. Carried units protected. Unit tests.