Skip to main content

War of the Realms Scenarios (Phase 5, IMPLEMENTED 2026-07-18)

War of the Realms Scenarios (Phase 5, IMPLEMENTED 2026-07-18)

Status: IMPLEMENTED 2026-07-18 (Phase 5 of the vision build path).

Last updated: September 18, 2026

Blood Lineage — War of the Realms Scenarios (Phase 5, IMPLEMENTED 2026-07-18)

Status: IMPLEMENTED 2026-07-18 (Phase 5 of the vision build path).

Parent: index.md. Governed by: vision.md § "Mode 3 — War of the Realms" (the north-star spec this doc implements). Draws its roster from factions.md. Reuses combat/movement from military.md and AI personalities from diplomacy.md. Turn processing reuses progression.md's pipeline and for the multiplayer path. Bound by empire-4x-layer.md § "The seven voice-memory rules" (re-readable, pull, ends in a handoff).

Why this doc exists

vision.md names Mode 3 as the one framing that "does not exist as code yet" — a pre-set board, a chosen faction, a clear stated objective, and a difficulty, playable solo against AI or multiplayer against real players, all on the existing engine. It is deliberately "a Campaign with the sandbox cut away and a single sharp objective bolted on" — same kingdom/military/diplomacy/magic code, a narrower shape. This doc locks in the scenario schema and the first four scenarios so the framing exists.

The scenario schema

A Scenario is:

  1. A chosen faction — the player picks which of the six factions.md roster kingdoms they lead (The Iron Compact, The Gilded League, The Ashen Covenant, The Verdant Throne, The Pale Court, The Sunfire Dynasty). Their kingdom is named for the faction, so every existing faction-flavor wiring (diplomacy handler's "list kingdoms" agenda line, the AI-personality-by-name lookup) already applies to the human player's own realm too.
  2. A fixed starting board — a fresh, deterministic-shape world: the player's capital at map center, a set roster of enemy AI kingdoms placed symmetrically (the existing LineageWorldInitializer corner/edge placement), unclaimed frontier tiles generated the same way every Local game already is. "Fixed" means the SHAPE is the same recipe every time (not a literal fixed seed) — enemy faction identities and positions are deterministic in structure, randomized in exact tile terrain the same way the existing Local world already randomizes terrain.
  3. A clear, stated + re-readable objective — spoken in full when the scenario begins, and re-readable at any time via objective / scenario objective / my objective / what is my objective. The objective is checked every turn () and resolves the game the moment it is met or failed — never a silent, ongoing state the player must infer.
  4. Difficulty knobs — enemy faction count, AI aggression, AI competence, and a player handicap, selected as one of four named tiers (below). Applies uniformly across all four scenarios.
  5. Solo or multiplayer — single-player against AI factions first (LineageWorldInitializer. initializeScenarioGame, hosted in the existing single-player LineageGameMap slot, same as the Campaign); multiplayer via the existing shared-map and party-world creation path, with AI factions filling any seats a human party does not.

The initial four scenarios

All four are expressible in existing mechanics — no new combat, diplomacy, or economy system. Each maps onto one of four objective kinds, and each (except the survival scenario) resolves in defeat if its turn limit passes unmet, so a scenario always ends — it is never a silent hang.

Scenario (LineageScenarioType) Objective (spoken) Objective kind Turn window Required target faction
Unite the Broken Coast (UNITE_BROKEN_COAST) "Control every enemy crown territory by turn 40." CROWN_TERRITORIES 40 (turn cap) none
Break the Iron Compact (BREAK_IRON_COMPACT) "Eliminate the Iron Compact's dynasty." ELIMINATE_TARGET 100 (turn cap) The Iron Compact
Hold the Ashen Gate (HOLD_ASHEN_GATE) "Survive twenty turns of siege." SURVIVE_TURNS 20 (survive duration from scenario start) none
The Merchant's Gambit (MERCHANTS_GAMBIT) "Reach 60,000 gold before the Gilded League does." GOLD_RACE 100 (turn cap) The Gilded League

A player may never choose to play AS a scenario's required target faction (the scenario picker excludes it) — you cannot be assigned to eliminate or out-race yourself.

Objective kind mechanics (reuse of existing systems, no new state machinery)

  • CROWN_TERRITORIES — at scenario setup each enemy AI kingdom's capital territory becomes a "crown territory" (so the count scales with the difficulty's enemy faction count, two on Easy to five on Hardcore, not always three) — together the "crown territories" (LineageWorld.scenarioCrownTerritoryIds). Win the instant the player's kingdom owns them all (existing territory-ownership check, the same field LineageTerritory.ownerKingdomId the DOMINATION victory already reads). This deliberately ties crown-control to conquering/annexing enemy capitals, which the Phase 0 capital-capture-and-surrender resolution (military.md) already resolves in one step, so "unite the coast" is really "conquer the three rival capitals" restated as a bespoke, faster win than the 50%-of-all-territories DOMINATION victory.
  • ELIMINATE_TARGET — win the instant LineageWorld.scenarioTargetKingdomId (the Iron Compact, resolved to a real kingdom id at scenario setup) has isEliminated = true — the exact field the existing capital-capture/annexation flow and already set.
  • SURVIVE_TURNS — win once currentTurn - scenarioStartTurn >= 20. Loss is implicit: if the player's OWN capital falls, the symmetric capital-capture-and-surrender resolution (military.md) marks the player kingdom isEliminated = true the same way it eliminates an AI, and the scenario check (below) resolves that as an immediate scenario defeat rather than waiting for the whole game to whittle down to one survivor.
  • GOLD_RACE — win once the player's gold resource reaches 60,000 and the target faction (the Gilded League) has not already reached it with a higher balance; lose if the target reaches 60,000 gold first. MERCHANTS_GAMBIT_GOLD_TARGET = 60_000 is a single named constant in , matching 's pattern (60% of the standard ECONOMIC victory's 100,000 target, so a two-party race resolves faster than the open Campaign's economic path).

Every objective kind (except SURVIVE_TURNS, whose only failure is elimination) also resolves in scenario defeat once currentTurn > LineageWorld.scenarioTurnLimit with the objective unmet — the scenario never runs forever waiting for a win that will not come.

Difficulty knobs (`LineageScenarioDifficulty`)

Four named tiers, selected once at scenario start and applied uniformly:

Difficulty Enemy faction count AI aggression bonus AI competence (LineageAIKingdom.difficultyLevel) Player gold handicap
Easy 2 −10 3 ×1.25 (bonus starting gold)
Normal 3 0 5 ×1.0 (unchanged)
Hard 4 +15 7 ×0.85 (reduced starting gold)
Hardcore 5 +25 9 ×0.65 (reduced starting gold)
  • Enemy faction count — how many of the roster's other five factions populate the board (LineageWorldInitializer.resolveScenarioEnemyNames, the scenario's required target faction — when one exists — is always included first so the objective is always reachable; remaining slots are filled from a shuffled subset of the rest).
  • AI aggression — added to the aggression trait (clamped 0-100) of every AI kingdom created for the scenario, applied once at first-contact personality creation (, called from when it reads a non-null LineageWorld.scenarioAiAggressionBonus). Higher aggression means the AI's existing AIPersonality.calculateWarLikelihood formula (diplomacy.md) returns a higher war likelihood sooner.
  • AI competence — sets every scenario AI kingdom's LineageAIKingdom.difficultyLevel, the existing knob already gates action categories on (diplomacy.md Known Issues / military.md): at 5+ the AI researches and negotiates, not just fights and expands.
  • Player gold handicap — a one-time multiplier applied to the player's starting gold at world setup (LineageWorldInitializer.initializeScenarioGame) — no new economy system, just a starting condition, exactly like "Short Reign" / "Age of Legends" scale the Campaign length target (campaign.md) via a plain setting rather than new mechanics.

Objective statement + re-readability (voice-memory rules 1, 2, 7)

  • Stated up front — the full objective sentence is spoken the moment the scenario begins (, immediately after world creation).
  • Re-readable on demand — objective / scenario objective / my objective / what is my objective routes to LINEAGE_VIEW key OBJECTIVE (), which reads the objective plus LIVE progress (crown territories held / turns survived / gold race standing / turns remaining) and always ends with a handoff (view status, end turn). Nothing about the objective must be remembered between asks — the game holds the state, matching every other 4X pull-screen (advisor.md, campaign.md).
  • Checked every turn — runs from both (single-player) and . processSynchronizedTurn (multiplayer), narrating the win/loss and completing the world the instant the objective resolves (mirrors the existing Twilight-of-the-Age wiring in campaign.md, and is mutually exclusive with it — a scenario world never also rolls into a Twilight reckoning; it always resolves on its own bespoke objective or turn limit instead).

Victory resolution — the scenario objective AND the standard victories both apply (decided 2026-07-19)

A scenario world checks BOTH the standard five victory conditions (progression.md) AND its own bespoke objective every turn; whichever resolves first ends the game. The scenario objective is the intended, usually-FASTER path (conquering the rival capitals is quicker than the 50%-of-all-territories DOMINATION win), but a scenario player who happens to reach a standard victory — Domination, Economic, Diplomatic, Technological, or Magical — wins by that path too. The standard victories are NOT suppressed inside a scenario. This is intentional: a scenario is a specialized single-player or multiplayer world running on the full engine, and disabling the base win conditions would make an emergent Domination or Economic runaway feel broken rather than rewarded. A standard-victory win may offer the post-victory Empire "rule on" continuation as usual; a bespoke scenario-objective win completes the world outright. The Twilight-of-the-Age campaign reckoning does NOT fire in a scenario — that is campaign-only; only the standard victories plus the scenario objective are active here. Enforced in (single-player) and (multiplayer): the standard checkVictoryConditions runs first, then the scenario-outcome check.## Single-player then multiplayer wiring (vision.md's stated order)

  1. Single-player first. war of the realms / start scenario / new scenario (any time, not only at first launch) opens the scenario picker. delete kingdom, reset kingdom, restart kingdom, wipe my kingdom and start a new kingdom open it too: Lineage has no kingdom deletion, and this picker is the designed way to replace a kingdom, so a player asking to start over lands where starting over is possible, is warned before anything is replaced, and can cancel. The chain is scenario picker → faction picker → difficulty picker (), storing the in-progress choice on . pendingScenarioType / pendingScenarioFaction (mirrors the existing pendingRecruitArmyIndex pattern in military.md — non-transient so it survives the cache round-trip across the three picker steps). Completing the chain calls LineageWorldInitializer.initializeScenarioGame, which seeds a fresh world in the SAME single-player LineageGameMap slot the Campaign already uses (sp_{userId}) — a scenario is a specialized single-player world, not a fourth LineageGameMode. Starting a new scenario replaces any existing single-player kingdom, exactly as choosing "single player" does for a brand-new player; the picker states this plainly before the player commits.
  2. Multiplayer reuses the existing shared-map service. When the player who completes the difficulty picker is in an active chat party, LineageWorldInitializer. initializeScenarioMultiplayerGame seeds the SAME scenario board inside the party's multiplayer LineageGameMap (mp_{partyRef}) instead — the creator's kingdom is named for their chosen faction, any other party members get the existing generic "Kingdom of Player N" placeholder (a scenario-aware per-member faction picker is a documented follow-up, not required for the first four scenarios), and AI factions fill every remaining seat up to the chosen difficulty's enemy count — exactly vision.md's "AI factions fill empty seats so a 1-human scenario is still a full board." Turn processing is , wholly unchanged apart from the new scenario-outcome check.

What this doc is NOT

  • Not a rebalance of combat, diplomacy, or economy — every objective kind reads existing fields (territory ownership, elimination flag, gold resource) with no new formulas.
  • Not a per-party-member scenario faction picker — every non-creator party member gets the existing generic placeholder name; letting each human player pick their own faction is a documented follow-up.
  • Not a literal fixed RNG seed — "fixed starting board" means the deterministic SHAPE (capital at center, symmetric enemy placement, the same frontier-generation recipe every Local game already uses), not byte-identical terrain across runs.
  • vision.md — the north-star spec this doc implements (§ "Mode 3 — War of the Realms").
  • factions.md — the six-faction roster scenarios draw from.
  • military.md — combat, movement, and the capital-capture-and-surrender resolution every elimination-based objective reuses.
  • diplomacy.md — the AIPersonality archetypes and difficulty-level gating the aggression/competence knobs tune.
  • campaign.md — the sibling bounded-mode shape (Twilight reckoning) this mode's turn-limit-defeat pattern mirrors.
  • empire-4x-layer.md — the seven voice-memory rules this mode is bound by.