Add Xinye camp and Changban bridge

This commit is contained in:
2026-06-19 03:43:36 +09:00
parent 0026d5b904
commit 3ca9d9bb05
4 changed files with 332 additions and 2 deletions

View File

@@ -1592,6 +1592,17 @@ func _check_battle_visual_data(failures: Array[String]) -> void:
failures.append("could not load Xinye Advance data")
else:
_check_shop_items_unique(failures, xinye_state, "025 base")
var xinye_conversations: Array = xinye_state.get_briefing().get("camp_conversations", [])
if xinye_conversations.size() != 2:
failures.append("025 base briefing should expose exactly two camp conversations")
else:
_check_camp_conversation(failures, xinye_conversations[0], "xinye_southern_war_council", "topic", "")
_check_camp_conversation(failures, xinye_conversations[1], "xinye_zhang_he_south_road", "officer", "zhang_he")
var xinye_merchant := xinye_state.get_shop_merchant()
if str(xinye_merchant.get("name", "")) != "Xinye Road Sutler":
failures.append("025 shop should expose Xinye Road merchant name")
if (xinye_merchant.get("lines", []) as Array).size() < 2:
failures.append("025 shop should expose merchant flavor lines")
if xinye_state.get_unit("zhang_he_ch25").is_empty() or not xinye_state.is_required_deployment("zhang_he_ch25"):
failures.append("025 should deploy Zhang He as a required officer")
_check_shop_item_visibility(failures, xinye_state, "war_drum", false, "025 base")
@@ -1601,6 +1612,19 @@ func _check_battle_visual_data(failures: Array[String]) -> void:
if not xinye_terms_state.load_battle("res://data/scenarios/025_xinye_advance.json", {}, {}, {"accepted_liaodong_terms": true}, ["zhang_he"]):
failures.append("could not load Xinye accepted Liaodong terms data")
else:
var ordered_medicine: Dictionary = _find_camp_conversation(
xinye_terms_state.get_briefing().get("camp_conversations", []),
"xinye_ordered_medicine"
)
if ordered_medicine.is_empty():
failures.append("025 accepted Liaodong terms should expose ordered medicine")
else:
_check_camp_conversation_effect(failures, ordered_medicine, "panacea", 1)
if not _find_camp_conversation(
xinye_terms_state.get_briefing().get("camp_conversations", []),
"xinye_authority_wine"
).is_empty():
failures.append("025 accepted Liaodong terms should not expose authority wine")
_check_shop_item_visibility(failures, xinye_terms_state, "imperial_seal", true, "025 accepted Liaodong terms")
_check_shop_item_visibility(failures, xinye_terms_state, "war_drum", false, "025 accepted Liaodong terms")
@@ -1608,6 +1632,19 @@ func _check_battle_visual_data(failures: Array[String]) -> void:
if not xinye_authority_state.load_battle("res://data/scenarios/025_xinye_advance.json", {}, {}, {"pressed_liaodong_authority": true}, ["zhang_he"]):
failures.append("could not load Xinye pressed Liaodong authority data")
else:
var authority_wine: Dictionary = _find_camp_conversation(
xinye_authority_state.get_briefing().get("camp_conversations", []),
"xinye_authority_wine"
)
if authority_wine.is_empty():
failures.append("025 pressed Liaodong authority should expose authority wine")
else:
_check_camp_conversation_effect(failures, authority_wine, "wine", 1)
if not _find_camp_conversation(
xinye_authority_state.get_briefing().get("camp_conversations", []),
"xinye_ordered_medicine"
).is_empty():
failures.append("025 pressed Liaodong authority should not expose ordered medicine")
_check_shop_item_visibility(failures, xinye_authority_state, "war_drum", true, "025 pressed Liaodong authority")
_check_shop_item_visibility(failures, xinye_authority_state, "imperial_seal", false, "025 pressed Liaodong authority")
@@ -1618,6 +1655,48 @@ func _check_battle_visual_data(failures: Array[String]) -> void:
_check_shop_items_unique(failures, xinye_old_flags_state, "025 old Liaodong Pursuit flags")
_check_shop_item_visibility(failures, xinye_old_flags_state, "war_drum", false, "025 old Liaodong Pursuit flags")
_check_shop_item_visibility(failures, xinye_old_flags_state, "imperial_seal", false, "025 old Liaodong Pursuit flags")
if not _find_camp_conversation(
xinye_old_flags_state.get_briefing().get("camp_conversations", []),
"xinye_ordered_medicine"
).is_empty():
failures.append("025 old Liaodong Pursuit flags should not expose ordered medicine")
if not _find_camp_conversation(
xinye_old_flags_state.get_briefing().get("camp_conversations", []),
"xinye_authority_wine"
).is_empty():
failures.append("025 old Liaodong Pursuit flags should not expose authority wine")
var changban_state = BattleStateScript.new()
if not changban_state.load_battle("res://data/scenarios/026_changban_pursuit.json", {}, {}, {}, ["zhang_he"]):
failures.append("could not load Changban Pursuit data")
else:
_check_shop_items_unique(failures, changban_state, "026 base")
if changban_state.get_unit("zhang_he_ch26").is_empty() or not changban_state.is_required_deployment("zhang_he_ch26"):
failures.append("026 should deploy Zhang He as a required officer")
_check_shop_item_visibility(failures, changban_state, "war_drum", false, "026 base")
_check_shop_item_visibility(failures, changban_state, "imperial_seal", false, "026 base")
var changban_vanguard_state = BattleStateScript.new()
if not changban_vanguard_state.load_battle("res://data/scenarios/026_changban_pursuit.json", {}, {}, {"pressed_xinye_vanguard": true}, ["zhang_he"]):
failures.append("could not load Changban pressed Xinye vanguard data")
else:
_check_shop_item_visibility(failures, changban_vanguard_state, "war_drum", true, "026 pressed Xinye vanguard")
_check_shop_item_visibility(failures, changban_vanguard_state, "imperial_seal", false, "026 pressed Xinye vanguard")
var changban_supply_state = BattleStateScript.new()
if not changban_supply_state.load_battle("res://data/scenarios/026_changban_pursuit.json", {}, {}, {"secured_han_river_supply": true}, ["zhang_he"]):
failures.append("could not load Changban secured Han supply data")
else:
_check_shop_item_visibility(failures, changban_supply_state, "imperial_seal", true, "026 secured Han supply")
_check_shop_item_visibility(failures, changban_supply_state, "war_drum", false, "026 secured Han supply")
var changban_old_flags_state = BattleStateScript.new()
if not changban_old_flags_state.load_battle("res://data/scenarios/026_changban_pursuit.json", {}, {}, {"accepted_liaodong_terms": true, "pressed_liaodong_authority": true}, ["zhang_he"]):
failures.append("could not load Changban old Xinye setup flag data")
else:
_check_shop_items_unique(failures, changban_old_flags_state, "026 old Xinye setup flags")
_check_shop_item_visibility(failures, changban_old_flags_state, "war_drum", false, "026 old Xinye setup flags")
_check_shop_item_visibility(failures, changban_old_flags_state, "imperial_seal", false, "026 old Xinye setup flags")
for item_id in ["bronze_sword", "training_spear", "short_bow", "hand_axe", "iron_armor", "panacea"]:
var item := state.get_item_def(item_id)