Add Ye campaign camp content
This commit is contained in:
@@ -789,6 +789,87 @@ func _check_battle_visual_data(failures: Array[String]) -> void:
|
||||
).is_empty():
|
||||
failures.append("014 old Wuchao flags should not expose Wuchao store medicine")
|
||||
|
||||
var ye_state = BattleStateScript.new()
|
||||
if not ye_state.load_battle("res://data/scenarios/015_ye_campaign.json"):
|
||||
failures.append("could not load Ye Campaign camp data")
|
||||
else:
|
||||
_check_shop_items_unique(failures, ye_state, "015 base")
|
||||
var ye_conversations: Array = ye_state.get_briefing().get("camp_conversations", [])
|
||||
if ye_conversations.size() != 2:
|
||||
failures.append("015 base briefing should expose exactly two camp conversations")
|
||||
else:
|
||||
_check_camp_conversation(failures, ye_conversations[0], "ye_outer_council", "topic", "")
|
||||
_check_camp_conversation(failures, ye_conversations[1], "ye_zhang_he_city_map", "officer", "zhang_he")
|
||||
var ye_merchant := ye_state.get_shop_merchant()
|
||||
if str(ye_merchant.get("name", "")) != "Ye Outskirts Sutler":
|
||||
failures.append("015 shop should expose Ye merchant name")
|
||||
if (ye_merchant.get("lines", []) as Array).size() < 2:
|
||||
failures.append("015 shop should expose merchant flavor lines")
|
||||
_check_shop_item_visibility(failures, ye_state, "war_drum", false, "015 base")
|
||||
_check_shop_item_visibility(failures, ye_state, "imperial_seal", false, "015 base")
|
||||
_check_shop_item_visibility(failures, ye_state, "wind_chaser_bow", false, "015 base")
|
||||
|
||||
var ye_advanced_state = BattleStateScript.new()
|
||||
if not ye_advanced_state.load_battle("res://data/scenarios/015_ye_campaign.json", {}, {}, {"advanced_to_ye": true}):
|
||||
failures.append("could not load Ye advanced camp data")
|
||||
else:
|
||||
_check_shop_items_unique(failures, ye_advanced_state, "015 advanced to Ye")
|
||||
var rapid_rations: Dictionary = _find_camp_conversation(
|
||||
ye_advanced_state.get_briefing().get("camp_conversations", []),
|
||||
"ye_rapid_march_rations"
|
||||
)
|
||||
if rapid_rations.is_empty():
|
||||
failures.append("015 advanced to Ye flag should expose rapid march rations")
|
||||
else:
|
||||
_check_camp_conversation_effect(failures, rapid_rations, "bean", 1)
|
||||
if not _find_camp_conversation(
|
||||
ye_advanced_state.get_briefing().get("camp_conversations", []),
|
||||
"ye_crossing_medicine"
|
||||
).is_empty():
|
||||
failures.append("015 advanced to Ye flag should not expose crossing medicine")
|
||||
_check_shop_item_visibility(failures, ye_advanced_state, "war_drum", true, "015 advanced to Ye")
|
||||
_check_shop_item_visibility(failures, ye_advanced_state, "imperial_seal", false, "015 advanced to Ye")
|
||||
_check_shop_item_visibility(failures, ye_advanced_state, "wind_chaser_bow", false, "015 advanced to Ye")
|
||||
|
||||
var ye_crossing_state = BattleStateScript.new()
|
||||
if not ye_crossing_state.load_battle("res://data/scenarios/015_ye_campaign.json", {}, {}, {"secured_hebei_crossings": true}):
|
||||
failures.append("could not load Ye secured crossings camp data")
|
||||
else:
|
||||
_check_shop_items_unique(failures, ye_crossing_state, "015 secured Hebei crossings")
|
||||
var crossing_medicine: Dictionary = _find_camp_conversation(
|
||||
ye_crossing_state.get_briefing().get("camp_conversations", []),
|
||||
"ye_crossing_medicine"
|
||||
)
|
||||
if crossing_medicine.is_empty():
|
||||
failures.append("015 secured Hebei crossings flag should expose crossing medicine")
|
||||
else:
|
||||
_check_camp_conversation_effect(failures, crossing_medicine, "panacea", 1)
|
||||
if not _find_camp_conversation(
|
||||
ye_crossing_state.get_briefing().get("camp_conversations", []),
|
||||
"ye_rapid_march_rations"
|
||||
).is_empty():
|
||||
failures.append("015 secured Hebei crossings flag should not expose rapid march rations")
|
||||
_check_shop_item_visibility(failures, ye_crossing_state, "war_drum", false, "015 secured Hebei crossings")
|
||||
_check_shop_item_visibility(failures, ye_crossing_state, "imperial_seal", true, "015 secured Hebei crossings")
|
||||
_check_shop_item_visibility(failures, ye_crossing_state, "wind_chaser_bow", false, "015 secured Hebei crossings")
|
||||
|
||||
var ye_old_flags_state = BattleStateScript.new()
|
||||
if not ye_old_flags_state.load_battle("res://data/scenarios/015_ye_campaign.json", {}, {}, {"pressed_yuan_rout": true, "secured_wuchao_stores": true}):
|
||||
failures.append("could not load Ye old Cangting flag camp data")
|
||||
else:
|
||||
_check_shop_item_visibility(failures, ye_old_flags_state, "war_drum", false, "015 old Cangting flags")
|
||||
_check_shop_item_visibility(failures, ye_old_flags_state, "imperial_seal", false, "015 old Cangting flags")
|
||||
if not _find_camp_conversation(
|
||||
ye_old_flags_state.get_briefing().get("camp_conversations", []),
|
||||
"ye_rapid_march_rations"
|
||||
).is_empty():
|
||||
failures.append("015 old Cangting flags should not expose rapid march rations")
|
||||
if not _find_camp_conversation(
|
||||
ye_old_flags_state.get_briefing().get("camp_conversations", []),
|
||||
"ye_crossing_medicine"
|
||||
).is_empty():
|
||||
failures.append("015 old Cangting flags should not expose crossing medicine")
|
||||
|
||||
for item_id in ["bronze_sword", "training_spear", "short_bow", "hand_axe", "iron_armor", "panacea"]:
|
||||
var item := state.get_item_def(item_id)
|
||||
if item.is_empty():
|
||||
|
||||
Reference in New Issue
Block a user