From bd1fa8ff8b89f4e8d68b392d4b2e914a91c7ab57 Mon Sep 17 00:00:00 2001 From: Wickedness Date: Thu, 18 Jun 2026 00:42:00 +0900 Subject: [PATCH] Add Guanzhong foothold scenario --- README.md | 3 +- data/campaign/campaign.json | 5 + data/scenarios/037_guanzhong_foothold.json | 359 +++++++++++++++++++++ docs/DATA_MODEL.md | 4 +- docs/ROADMAP.md | 5 +- 5 files changed, 372 insertions(+), 4 deletions(-) create mode 100644 data/scenarios/037_guanzhong_foothold.json diff --git a/README.md b/README.md index 41eb6a3..fc56248 100644 --- a/README.md +++ b/README.md @@ -4,7 +4,7 @@ Godot 4 tactical RPG prototype inspired by classic turn-based Romance of the Thr ## Current Slice -- Thirty-six campaign scenarios. +- Thirty-seven campaign scenarios. - Grid movement. - Unit selection. - Move, attack, wait, end turn. @@ -57,6 +57,7 @@ Godot 4 tactical RPG prototype inspired by classic turn-based Romance of the Thr - Ma Chao Counterstroke consumes the Tong Pass Vanguard branch flags and tests Cao Cao's pass line against the western cavalry charge. - Weishui Camps consumes the Ma Chao Counterstroke branch flags and turns the Wei River line into a test of ground and alliance trust. - Weishui Crossing consumes the Weishui Camps branch flags and turns the western campaign from river defense into a Guanzhong foothold. +- Guanzhong Foothold consumes the Weishui Crossing branch flags and turns the seized riverbank into a western base against Ma Chao's rearguard. - Post-battle choices can save campaign flags that branch later briefing text, shop stock, and scenario events. - Scenario post-battle dialogue can play before the victory result panel. - Basic battle EXP, level-ups, and core first-tier class promotion routes. diff --git a/data/campaign/campaign.json b/data/campaign/campaign.json index 07169a1..d1f6bd1 100644 --- a/data/campaign/campaign.json +++ b/data/campaign/campaign.json @@ -183,6 +183,11 @@ "id": "036_weishui_crossing", "title": "Weishui Crossing", "path": "res://data/scenarios/036_weishui_crossing.json" + }, + { + "id": "037_guanzhong_foothold", + "title": "Guanzhong Foothold", + "path": "res://data/scenarios/037_guanzhong_foothold.json" } ] } diff --git a/data/scenarios/037_guanzhong_foothold.json b/data/scenarios/037_guanzhong_foothold.json new file mode 100644 index 0000000..fb0460d --- /dev/null +++ b/data/scenarios/037_guanzhong_foothold.json @@ -0,0 +1,359 @@ +{ + "id": "037_guanzhong_foothold", + "name": "Guanzhong Foothold", + "objectives": { + "victory": "Reach the Guanzhong foothold with Cao Cao, then defeat the western alliance rearguard.", + "defeat": "Cao Cao is defeated or the battle reaches Turn 18." + }, + "conditions": { + "victory": { "type": "all_units_defeated", "team": "enemy", "after_event": "guanzhong_foothold_reached" }, + "defeat": [ + { "type": "any_officer_defeated", "team": "player", "officer_ids": ["cao_cao"] }, + { "type": "turn_reached", "turn": 18, "team": "player" } + ] + }, + "briefing": { + "title": "Guanzhong Foothold", + "location": "Guanzhong Plain, 211 CE", + "lines": [ + "The Wei River crossing gives Cao Cao a road into Guanzhong, but a road is not yet a province.", + "Ma Chao's rearguard and Han Sui's uncertain captains gather near the first foothold, where the western campaign can either settle or scatter." + ], + "conditional_lines": [ + { + "campaign_flags": { "secured_guanzhong_foothold": true }, + "lines": [ + "The secured crossing has become a real foothold, giving Cao Cao a firm base for the next push across Guanzhong." + ] + }, + { + "campaign_flags": { "split_western_alliance": true }, + "lines": [ + "The western alliance is split enough that every Ma clan order must first pass through suspicion." + ] + } + ] + }, + "shop": { + "items": [ + "bean", + "wine", + "iron_sword", + "training_spear", + "short_bow", + "hand_axe", + "war_axe", + "leather_armor", + "iron_armor" + ], + "conditional_items": [ + { + "campaign_flags": { "secured_guanzhong_foothold": true }, + "items": ["imperial_seal"] + }, + { + "campaign_flags": { "split_western_alliance": true }, + "items": ["war_drum"] + } + ] + }, + "roster": { + "max_units": 7, + "required_officers": ["cao_cao", "guo_jia"] + }, + "formation": { + "cells": [[1, 3], [1, 4], [1, 5], [2, 2], [2, 3], [2, 4], [2, 5], [2, 6], [3, 2], [3, 3], [3, 4], [3, 5], [3, 6]] + }, + "map": { + "width": 18, + "height": 11, + "terrain": [ + "GGGGHHGGGGGGHHGGGG", + "GGFFHHGGRRGGHHFFGG", + "GGRRRRRRRRRRRRFFGG", + "GGGFGHGGGGRRGGGGGG", + "RRRRRRRRRRRRRRRRRR", + "GGGGGHHGGGRRGFFGGG", + "GGHHGFFFGGFFFGGHHG", + "GGHHGFFFGGFFFGGHHG", + "GGGGGGFFGGHHHGGGGG", + "GGFFGGGGGGHHHFFGGG", + "GGGGGGGGGGGGGGGGGG" + ] + }, + "deployments": [ + { + "unit_id": "cao_cao_ch37", + "officer_id": "cao_cao", + "team": "player", + "pos": [1, 4] + }, + { + "unit_id": "guo_jia_ch37", + "officer_id": "guo_jia", + "team": "player", + "requires_joined": true, + "pos": [2, 4] + }, + { + "unit_id": "zhang_he_ch37", + "officer_id": "zhang_he", + "team": "player", + "requires_joined": true, + "pos": [2, 3] + }, + { + "unit_id": "xiahou_dun_ch37", + "officer_id": "xiahou_dun", + "team": "player", + "pos": [1, 5] + }, + { + "unit_id": "dian_wei_ch37", + "officer_id": "dian_wei", + "team": "player", + "requires_joined": true, + "pos": [2, 5] + }, + { + "unit_id": "xiahou_yuan_ch37", + "officer_id": "xiahou_yuan", + "team": "player", + "requires_joined": true, + "pos": [3, 3] + }, + { + "unit_id": "cao_ren_ch37", + "officer_id": "cao_ren", + "team": "player", + "requires_joined": true, + "pos": [3, 4] + }, + { + "unit_id": "ma_chao_rearguard", + "name": "Ma Chao Rearguard", + "class_id": "elite_cavalry", + "team": "enemy", + "level": 35, + "pos": [14, 4], + "base": { "hp": 140, "mp": 16, "atk": 40, "def": 28, "int": 14, "agi": 29 } + }, + { + "unit_id": "han_sui_divided_captain", + "name": "Han Sui Divided Captain", + "class_id": "commander", + "team": "enemy", + "level": 34, + "pos": [15, 5], + "base": { "hp": 122, "mp": 48, "atk": 36, "def": 28, "int": 28, "agi": 20 } + }, + { + "unit_id": "guanzhong_gate_captain", + "name": "Guanzhong Gate Captain", + "class_id": "guard_captain", + "team": "enemy", + "level": 34, + "pos": [12, 4], + "base": { "hp": 100, "atk": 35, "def": 28 } + }, + { + "unit_id": "foothold_tactic_advisor", + "name": "Foothold Tactic Advisor", + "class_id": "military_advisor", + "team": "enemy", + "level": 34, + "pos": [13, 5], + "skills": ["blaze", "great_mend"], + "base": { "hp": 88, "mp": 72, "atk": 8, "def": 17, "int": 37, "agi": 18 } + }, + { + "unit_id": "guanzhong_spear_north", + "name": "Guanzhong Spear Guard", + "class_id": "infantry", + "team": "enemy", + "level": 34, + "pos": [12, 3], + "base": { "hp": 90, "atk": 35, "def": 25 } + }, + { + "unit_id": "guanzhong_spear_south", + "name": "Guanzhong Spear Guard", + "class_id": "infantry", + "team": "enemy", + "level": 34, + "pos": [12, 5], + "base": { "hp": 90, "atk": 35, "def": 25 } + }, + { + "unit_id": "guanzhong_marksman", + "name": "Guanzhong Marksman", + "class_id": "marksman", + "team": "enemy", + "level": 34, + "pos": [13, 2], + "base": { "hp": 82, "atk": 36, "def": 13, "agi": 26 } + } + ], + "events": [ + { + "id": "opening", + "once": true, + "when": { "type": "battle_start" }, + "actions": [ + { "type": "log", "text": "Cao Cao pushes from the Wei River crossing toward a Guanzhong foothold as the western alliance strains." } + ] + }, + { + "id": "opening_dialogue", + "once": true, + "when": { "type": "battle_begin" }, + "actions": [ + { + "type": "dialogue", + "lines": [ + { "speaker": "Cao Ren", "text": "The crossing behind us is firm. The foothold ahead is where the west begins to answer." }, + { "speaker": "Guo Jia", "text": "A foothold is not just earth. It is the moment the enemy starts measuring loss." }, + { "speaker": "Cao Cao", "text": "Then give them something worth measuring." } + ] + } + ] + }, + { + "id": "secured_foothold_supplies_advance", + "once": true, + "when": { "type": "turn_start", "team": "player", "turn": 2, "campaign_flags": { "secured_guanzhong_foothold": true } }, + "actions": [ + { + "type": "dialogue", + "lines": [ + { "speaker": "Cao Ren", "text": "Supply is moving from the crossing into the foothold. The line can hold if Ma Chao turns back." }, + { "speaker": "Cao Cao", "text": "A held line invites the next decision." } + ] + } + ] + }, + { + "id": "split_alliance_confuses_rearguard", + "once": true, + "when": { "type": "turn_start", "team": "enemy", "turn": 2, "campaign_flags": { "split_western_alliance": true } }, + "actions": [ + { + "type": "dialogue", + "lines": [ + { "speaker": "Han Sui Divided Captain", "text": "Ma Chao demands we cover his withdrawal, but Han Sui's seals say to preserve our own wing." }, + { "speaker": "Guo Jia", "text": "When two orders arrive together, neither arrives first." } + ] + }, + { + "type": "spawn_deployment", + "deployment": { + "unit_id": "fractured_alliance_riders", + "name": "Fractured Alliance Riders", + "class_id": "cavalry", + "team": "enemy", + "level": 34, + "pos": [16, 3], + "base": { "hp": 82, "atk": 32, "def": 18, "agi": 23 } + } + } + ] + }, + { + "id": "turn_4_ma_chao_rearguard", + "once": true, + "when": { "type": "turn_start", "team": "enemy", "turn": 4 }, + "actions": [ + { + "type": "dialogue", + "lines": [ + { "speaker": "Ma Chao Rearguard", "text": "If Cao Cao plants himself in Guanzhong, the west will have to fight on his road. Cut the foothold now!" }, + { "speaker": "Xiahou Yuan", "text": "He sees the same ground we do. Good." } + ] + } + ] + }, + { + "id": "guanzhong_foothold_reached", + "once": true, + "when": { "type": "unit_reaches_tile", "team": "player", "officer_ids": ["cao_cao"], "pos": [10, 4] }, + "actions": [ + { + "type": "set_objective", + "victory": "The Guanzhong foothold is reached. Defeat the western alliance rearguard.", + "defeat": "Cao Cao is defeated or the battle reaches Turn 18." + }, + { + "type": "dialogue", + "lines": [ + { "speaker": "Cao Cao", "text": "This foothold is where Guanzhong begins to change hands. Break the rearguard." }, + { "speaker": "Ma Chao Rearguard", "text": "You have crossed a river, not conquered a people." } + ] + }, + { + "type": "spawn_deployments", + "deployments": [ + { + "unit_id": "guanzhong_halberd_guard", + "name": "Guanzhong Halberd Guard", + "class_id": "guard_captain", + "team": "enemy", + "level": 34, + "pos": [16, 4], + "base": { "hp": 98, "atk": 35, "def": 28 } + }, + { + "unit_id": "foothold_arrow_screen", + "name": "Foothold Arrow Screen", + "class_id": "archer", + "team": "enemy", + "level": 34, + "pos": [16, 5], + "base": { "hp": 76, "atk": 34, "def": 11, "agi": 24 } + } + ] + } + ] + }, + { + "id": "turn_9_foothold_holds", + "once": true, + "when": { "type": "turn_start", "team": "player", "turn": 9 }, + "actions": [ + { + "type": "dialogue", + "lines": [ + { "speaker": "Zhang He", "text": "The foothold is taking shape. Their rearguard is fighting over yesterday's road." }, + { "speaker": "Cao Cao", "text": "Then make tomorrow's road ours." } + ] + } + ] + } + ], + "rewards": { + "gold": 7200, + "items": ["bean", "wine", "war_drum"] + }, + "post_battle_dialogue": [ + { "speaker": "Guo Jia", "text": "The Guanzhong foothold stands. Ma Chao can still flee west, but the alliance now leaves tracks in different directions." }, + { "speaker": "Xiahou Yuan", "text": "We can secure the commandery and pull its stores into our line, or press Ma Chao before he rebuilds pride into another charge." }, + { "speaker": "Cao Cao", "text": "A province is held by grain or pursuit. Choose the first hand we close." } + ], + "post_battle_choices": [ + { + "id": "secure_guanzhong_commandery", + "label": "Secure Commandery", + "description": "Cao Cao secures Guanzhong stores and commandery offices before the next advance.", + "set_flags": { "secured_guanzhong_commandery": true, "pressed_ma_chao_retreat": false }, + "gold": 1100, + "items": ["imperial_seal"] + }, + { + "id": "press_ma_chao_retreat", + "label": "Press Retreat", + "description": "Cao Cao presses Ma Chao's retreat before the western riders can rally.", + "set_flags": { "secured_guanzhong_commandery": false, "pressed_ma_chao_retreat": true }, + "gold": 900, + "items": ["war_drum"] + } + ] +} diff --git a/docs/DATA_MODEL.md b/docs/DATA_MODEL.md index ef9bdc3..59854e1 100644 --- a/docs/DATA_MODEL.md +++ b/docs/DATA_MODEL.md @@ -47,6 +47,7 @@ data/scenarios/033_tong_pass_vanguard.json data/scenarios/034_ma_chao_counterstroke.json data/scenarios/035_weishui_camps.json data/scenarios/036_weishui_crossing.json +data/scenarios/037_guanzhong_foothold.json ``` ## Campaign @@ -95,7 +96,8 @@ The campaign file defines scenario order, resource paths, and officers who are a { "id": "033_tong_pass_vanguard", "title": "Tong Pass Vanguard", "path": "res://data/scenarios/033_tong_pass_vanguard.json" }, { "id": "034_ma_chao_counterstroke", "title": "Ma Chao Counterstroke", "path": "res://data/scenarios/034_ma_chao_counterstroke.json" }, { "id": "035_weishui_camps", "title": "Weishui Camps", "path": "res://data/scenarios/035_weishui_camps.json" }, - { "id": "036_weishui_crossing", "title": "Weishui Crossing", "path": "res://data/scenarios/036_weishui_crossing.json" } + { "id": "036_weishui_crossing", "title": "Weishui Crossing", "path": "res://data/scenarios/036_weishui_crossing.json" }, + { "id": "037_guanzhong_foothold", "title": "Guanzhong Foothold", "path": "res://data/scenarios/037_guanzhong_foothold.json" } ] } ``` diff --git a/docs/ROADMAP.md b/docs/ROADMAP.md index 13a61a9..ad18628 100644 --- a/docs/ROADMAP.md +++ b/docs/ROADMAP.md @@ -21,7 +21,7 @@ - Destination victory conditions and objective map markers exist. - Turn-limit conditions and HUD turn-limit display exist. - Victory reward summary is visible. -- Next-battle flow exists across the current thirty-six-scenario campaign. +- Next-battle flow exists across the current thirty-seven-scenario campaign. - Campaign completion and new-campaign reset exist. - Reward inventory can be brought into the next battle. @@ -52,7 +52,7 @@ - Party roster persistence has a first save-file skeleton. - Level, experience, and equipment persistence. - Chapter selection and save/load. -- Linear thirty-six-scenario campaign order exists. +- Linear thirty-seven-scenario campaign order exists. - Save reset exists. - Victory rewards, consumable counts, equipment stock, and equipped gear persist. - A basic pre-battle shop with scenario-specific stock exists. Sell-back and richer item management are still planned. @@ -96,6 +96,7 @@ - Thirty-fourth-scenario content exists with Ma Chao's counterstroke, Tong Pass fortification pressure, Han Sui alliance tension, and 033 branch reactions. - Thirty-fifth-scenario content exists with Wei River camp pressure, Ma Chao river assaults, Han Sui mistrust, and 034 branch reactions. - Thirty-sixth-scenario content exists with Wei River crossing pressure, Guanzhong foothold stakes, western alliance strain, and 035 branch reactions. +- Thirty-seventh-scenario content exists with Guanzhong foothold pressure, Ma Chao's rearguard, split-alliance tension, and 036 branch reactions. ## Milestone 5: Presentation