Refine ancient UI wording

This commit is contained in:
2026-06-19 01:39:19 +09:00
parent 0be2cadb9f
commit 539053c032
3 changed files with 132 additions and 132 deletions

View File

@@ -459,12 +459,12 @@ func _create_hud() -> void:
top_row.add_child(campaign_status_label)
restart_button = Button.new()
restart_button.text = "Restart"
restart_button.text = "Re-form"
restart_button.pressed.connect(_on_restart_pressed)
top_row.add_child(restart_button)
new_campaign_button = Button.new()
new_campaign_button.text = "New Campaign"
new_campaign_button.text = "New Chronicle"
new_campaign_button.pressed.connect(_on_new_campaign_pressed)
top_row.add_child(new_campaign_button)
@@ -531,7 +531,7 @@ func _create_hud() -> void:
selected_row.add_child(selected_label)
mission_title_label = Label.new()
mission_title_label.text = "Objective"
mission_title_label.text = "War Order"
mission_title_label.add_theme_font_size_override("font_size", 14)
_apply_label_style(mission_title_label, UI_OLD_BRONZE)
side_column.add_child(mission_title_label)
@@ -891,37 +891,37 @@ func _create_hud() -> void:
briefing_column.add_child(prep_button_row)
chapter_button = Button.new()
chapter_button.text = "Chapters"
chapter_button.text = "Chronicle"
chapter_button.pressed.connect(_on_chapter_pressed)
prep_button_row.add_child(chapter_button)
shop_button = Button.new()
shop_button.text = "Shop"
shop_button.text = "Market"
shop_button.pressed.connect(_on_shop_pressed)
prep_button_row.add_child(shop_button)
talk_button = Button.new()
talk_button.text = "Talk"
talk_button.text = "Council"
talk_button.pressed.connect(_on_talk_pressed)
prep_button_row.add_child(talk_button)
armory_button = Button.new()
armory_button.text = "Armory"
armory_button.text = "Arsenal"
armory_button.pressed.connect(_on_armory_pressed)
prep_button_row.add_child(armory_button)
roster_button = Button.new()
roster_button.text = "Roster"
roster_button.text = "Muster"
roster_button.pressed.connect(_on_roster_pressed)
prep_button_row.add_child(roster_button)
formation_button = Button.new()
formation_button.text = "Formation"
formation_button.text = "Array"
formation_button.pressed.connect(_on_formation_pressed)
prep_button_row.add_child(formation_button)
save_button = Button.new()
save_button.text = "Save"
save_button.text = "Record"
save_button.pressed.connect(_on_save_pressed)
prep_button_row.add_child(save_button)
@@ -961,12 +961,12 @@ func _create_hud() -> void:
shop_menu.add_child(shop_mode_row)
shop_buy_button = Button.new()
shop_buy_button.text = "Buy"
shop_buy_button.text = "Acquire"
shop_buy_button.pressed.connect(_on_shop_buy_mode_pressed)
shop_mode_row.add_child(shop_buy_button)
shop_sell_button = Button.new()
shop_sell_button.text = "Sell"
shop_sell_button.text = "Offer"
shop_sell_button.pressed.connect(_on_shop_sell_mode_pressed)
shop_mode_row.add_child(shop_sell_button)
@@ -1075,17 +1075,17 @@ func _create_hud() -> void:
save_menu.add_child(save_action_row)
manual_save_button = Button.new()
manual_save_button.text = "Save Checkpoint"
manual_save_button.text = "Record Seal"
manual_save_button.pressed.connect(_on_manual_save_pressed)
save_action_row.add_child(manual_save_button)
manual_load_button = Button.new()
manual_load_button.text = "Load Checkpoint"
manual_load_button.text = "Restore Seal"
manual_load_button.pressed.connect(_on_manual_load_pressed)
save_action_row.add_child(manual_load_button)
var begin_button := Button.new()
begin_button.text = "Begin Battle"
begin_button.text = "Take Field"
begin_button.pressed.connect(_on_begin_battle_pressed)
briefing_column.add_child(begin_button)
@@ -1172,14 +1172,14 @@ func _create_hud() -> void:
dialogue_control_row.add_child(dialogue_progress_label)
dialogue_previous_button = Button.new()
dialogue_previous_button.text = "Prior"
dialogue_previous_button.text = "Recall"
dialogue_previous_button.disabled = true
dialogue_previous_button.custom_minimum_size = Vector2(88, 32)
dialogue_previous_button.pressed.connect(_retreat_dialogue)
dialogue_control_row.add_child(dialogue_previous_button)
dialogue_continue_button = Button.new()
dialogue_continue_button.text = "Continue"
dialogue_continue_button.text = "Advance"
dialogue_continue_button.custom_minimum_size = Vector2(120, 32)
dialogue_continue_button.pressed.connect(_advance_dialogue)
dialogue_control_row.add_child(dialogue_continue_button)
@@ -1208,12 +1208,12 @@ func _create_hud() -> void:
result_column.add_child(result_choice_list)
result_restart_button = Button.new()
result_restart_button.text = "Restart Battle"
result_restart_button.text = "Re-form Army"
result_restart_button.pressed.connect(_on_restart_pressed)
result_column.add_child(result_restart_button)
next_battle_button = Button.new()
next_battle_button.text = "Next Battle"
next_battle_button.text = "March On"
next_battle_button.pressed.connect(_on_next_battle_pressed)
result_column.add_child(next_battle_button)
@@ -2929,8 +2929,8 @@ func _update_hud() -> void:
func _format_objective_hud_text() -> String:
var text := String(state.objectives.get("victory", "Defeat all enemies."))
if text.is_empty():
return "Objective"
return "Objective: %s" % text
return "War Order"
return "War Order: %s" % text
func _format_unit_focus_text(unit: Dictionary, prefix: String) -> String:
@@ -2964,7 +2964,7 @@ func _format_unit_focus_text(unit: Dictionary, prefix: String) -> String:
int(unit.get("int", 0)),
int(unit.get("agi", 0))
])
lines.append("Move %d (%s) Attack range %d-%d" % [
lines.append("March %d (%s) Strike reach %d-%d" % [
int(unit.get("move", 0)),
_format_move_type(str(unit.get("move_type", "foot"))),
int(unit.get("min_range", 1)),
@@ -2983,33 +2983,33 @@ func _format_unit_focus_text(unit: Dictionary, prefix: String) -> String:
func _unit_action_status_text(unit: Dictionary) -> String:
var unit_id := str(unit.get("id", ""))
if unit_id.is_empty():
return "Action: Unavailable"
return "Order: Unavailable"
var team := str(unit.get("team", ""))
if team != BattleState.TEAM_PLAYER:
return "Action: Enemy AI"
return "Order: Enemy command"
if not bool(unit.get("controllable", true)):
return "Action: Protected escort"
return "Order: Protected escort"
if not bool(unit.get("alive", true)) or not bool(unit.get("deployed", true)):
return "Action: Unavailable"
return "Order: Unavailable"
if bool(unit.get("acted", false)):
return "Action: Done"
return "Order: Done"
if not state.can_player_act():
return "Action: Waiting turn"
return "Order: Awaiting turn"
var actions: Array[String] = []
if not bool(unit.get("moved", false)) and not state.get_movement_range(unit_id).is_empty():
actions.append("Move")
actions.append("March")
if not state.get_attack_cells(unit_id).is_empty():
actions.append("Attack")
actions.append("Strike")
var skill_id := state.get_first_usable_skill_id(unit_id)
if not skill_id.is_empty() and not state.get_skill_cells(unit_id, skill_id).is_empty():
actions.append("Tactic")
if _unit_has_usable_item_target(unit_id):
actions.append("Item")
actions.append("Supply")
if not bool(unit.get("moved", false)):
actions.append("Equip")
actions.append("Arms")
actions.append("Wait")
var suffix := " (moved)" if bool(unit.get("moved", false)) else ""
return "Action: %s%s" % [_join_strings(actions, ", "), suffix]
var suffix := " (marched)" if bool(unit.get("moved", false)) else ""
return "Order: %s%s" % [_join_strings(actions, ", "), suffix]
func _unit_has_usable_item_target(unit_id: String) -> bool:
@@ -3072,7 +3072,7 @@ func _unit_current_terrain_text(unit: Dictionary) -> String:
var cell: Vector2i = unit.get("pos", Vector2i(-1, -1))
if not state.is_inside(cell):
return ""
return "Tile %d,%d %s Cost %d DEF +%d AVO +%d%%" % [
return "Ground %d,%d %s March %d Guard +%d Dodge +%d%%" % [
cell.x + 1,
cell.y + 1,
state.get_terrain_name(cell),
@@ -3092,19 +3092,19 @@ func _format_mission_panel_text() -> String:
var lines := []
var victory := str(state.objectives.get("victory", ""))
if not victory.is_empty():
lines.append("Win: %s" % victory)
lines.append("Edict: %s" % victory)
var progress_lines := state.get_objective_progress_lines(false, false)
if not progress_lines.is_empty():
lines.append("Progress:")
lines.append("War Report:")
for progress_line in progress_lines:
lines.append(" %s" % progress_line)
var risk_lines := state.get_defeat_progress_lines()
if not risk_lines.is_empty():
lines.append("Risk:")
lines.append("Ill Omen:")
for risk_line in risk_lines:
lines.append(" %s" % risk_line)
if lines.is_empty():
return "No objective data."
return "No war order."
return _join_strings(lines, "\n")
@@ -3137,12 +3137,12 @@ func _update_hud_unit_portrait(unit: Dictionary) -> void:
func _update_cell_info() -> void:
if not state.is_inside(hover_cell):
cell_info_label.text = "Tile: -"
cell_info_label.text = "Ground: -"
return
var summary := state.get_cell_summary(hover_cell)
var cell: Vector2i = summary["cell"]
var text := "Tile %d,%d %s\nMove cost %d DEF +%d AVO +%d%%" % [
var text := "Ground %d,%d %s\nMarch %d Guard +%d Dodge +%d%%" % [
cell.x + 1,
cell.y + 1,
summary["terrain"],
@@ -3151,16 +3151,16 @@ func _update_cell_info() -> void:
summary.get("avoid", 0)
]
if state.get_objective_cells().has(cell):
text += "\nObjective marker"
text += "\nEdict marker"
if show_threat_overlay:
var threat_names := state.get_threatening_unit_names(cell, BattleState.TEAM_ENEMY)
if not threat_names.is_empty():
text += "\nThreatened by %s" % _compact_name_list(threat_names, 3)
text += "\nWatched by %s" % _compact_name_list(threat_names, 3)
var unit: Dictionary = summary["unit"]
if not unit.is_empty():
var control_label := " Protected" if not bool(unit.get("controllable", true)) else ""
text += "\nUnit: %s%s %s Lv.%d\n%s %s HP %d/%d MP %d/%d\nGear: %s" % [
text += "\nTroop: %s%s %s Lv.%d\n%s %s HP %d/%d MP %d/%d\nArms: %s" % [
unit["name"],
control_label,
str(unit["team"]).capitalize(),
@@ -3175,14 +3175,14 @@ func _update_cell_info() -> void:
]
var status_effects := state.get_status_effect_summary(unit["id"])
if not status_effects.is_empty():
text += "\nEffects: %s" % status_effects
text += "\nConditions: %s" % status_effects
if show_threat_overlay:
var physical_threats := state.get_physical_threat_previews(cell, BattleState.TEAM_ENEMY)
if not physical_threats.is_empty():
text += "\nPhysical threat: %s" % _format_physical_threat_preview_text(physical_threats, 3)
text += "\nWeapon threat: %s" % _format_physical_threat_preview_text(physical_threats, 3)
var skill_threats := state.get_skill_threat_previews(cell, BattleState.TEAM_ENEMY)
if not skill_threats.is_empty():
text += "\nSkill threat: %s" % _format_skill_threat_preview_text(skill_threats, 3)
text += "\nTactic threat: %s" % _format_skill_threat_preview_text(skill_threats, 3)
cell_info_label.text = text
@@ -3479,7 +3479,7 @@ func _update_result_panel() -> void:
result_restart_button.visible = false
if next_battle_button != null:
next_battle_button.visible = false
result_label.text = "%s Chronicle Complete\nAll current scenarios cleared.\nGold %d\nStart a new campaign to replay." % [
result_label.text = "%s Chronicle Complete\nAll current scrolls cleared.\nTreasury %dG\nBegin a new chronicle to replay." % [
campaign_state.campaign_title,
campaign_state.gold
]
@@ -3511,7 +3511,7 @@ func _update_result_panel() -> void:
result_restart_button.visible = true
if next_battle_button != null:
next_battle_button.visible = false
result_label.text = "Defeat Report\n%s" % state.objectives.get("defeat", "")
result_label.text = "Defeat Memorial\n%s" % state.objectives.get("defeat", "")
else:
_clear_result_choices()
result_panel.visible = false
@@ -3888,10 +3888,10 @@ func _render_dialogue_line() -> void:
func _update_dialogue_controls() -> void:
if dialogue_progress_label != null:
dialogue_progress_label.text = "Scroll %d / %d" % [active_dialogue_index + 1, active_dialogue_lines.size()]
dialogue_progress_label.text = "Slip %d / %d" % [active_dialogue_index + 1, active_dialogue_lines.size()]
if dialogue_previous_button != null:
dialogue_previous_button.disabled = active_dialogue_index <= 0
dialogue_continue_button.text = "Close" if active_dialogue_index >= active_dialogue_lines.size() - 1 else "Continue"
dialogue_continue_button.text = "Seal" if active_dialogue_index >= active_dialogue_lines.size() - 1 else "Advance"
func _apply_dialogue_side(side: String) -> void:
@@ -4227,12 +4227,12 @@ func _format_briefing_title(briefing: Dictionary) -> String:
var chapter_position := campaign_state.get_chapter_position_for_scenario(active_scenario_id)
var chapter_count := campaign_state.get_chapter_count()
if chapter_position > 0 and chapter_count > 0:
return "Chapter %02d/%02d - %s" % [chapter_position, chapter_count, chapter_title]
return "Scroll %02d/%02d - %s" % [chapter_position, chapter_count, chapter_title]
return chapter_title
var position := campaign_state.get_scenario_position(active_scenario_id)
var count := campaign_state.get_scenario_count()
if position > 0 and count > 0:
return "Battle %02d/%02d - %s" % [position, count, title]
return "Field %02d/%02d - %s" % [position, count, title]
return title
@@ -4243,12 +4243,12 @@ func _format_briefing_location(briefing: Dictionary) -> String:
var battle_text := _format_briefing_chapter_battle_text(briefing)
if location.is_empty():
return battle_text
return "%s | %s" % [battle_text, location]
return "%s - %s" % [battle_text, location]
if campaign_state.campaign_title.is_empty():
return location
if location.is_empty():
return campaign_state.campaign_title
return "%s | %s" % [campaign_state.campaign_title, location]
return "%s - %s" % [campaign_state.campaign_title, location]
func _format_briefing_chapter_battle_text(briefing: Dictionary) -> String:
@@ -4258,7 +4258,7 @@ func _format_briefing_chapter_battle_text(briefing: Dictionary) -> String:
var position := campaign_state.get_scenario_position_in_chapter(active_scenario_id)
var count := campaign_state.get_scenario_count_in_chapter(active_scenario_id)
if position > 0 and count > 0:
return "Battle %02d/%02d: %s" % [position, count, title]
return "Field %02d/%02d: %s" % [position, count, title]
return title
@@ -4334,7 +4334,7 @@ func _format_briefing_camp_overview_text(briefing: Dictionary, prep_locked: bool
var location := str(briefing.get("location", "")).strip_edges()
if not location.is_empty():
parts.append(location)
parts.append("Gold %dG" % campaign_state.gold)
parts.append("Treasury %dG" % campaign_state.gold)
var talk_text := _format_briefing_talk_overview_text()
if not talk_text.is_empty():
parts.append(talk_text)
@@ -4348,10 +4348,10 @@ func _format_briefing_camp_overview_text(briefing: Dictionary, prep_locked: bool
if not formation_text.is_empty():
parts.append(formation_text)
if not state.get_controllable_player_units().is_empty():
parts.append("Armory ready")
parts.append("Arsenal ready")
if prep_locked:
parts.append("Replay prep locked")
return _join_strings(parts, " | ")
parts.append("Replay camp sealed")
return _join_strings(parts, " - ")
func _format_briefing_talk_overview_text() -> String:
@@ -4361,7 +4361,7 @@ func _format_briefing_talk_overview_text() -> String:
var supply_counts := _camp_conversation_supply_counts(conversations)
var ready := int(supply_counts.get("ready", 0))
var claimed := int(supply_counts.get("claimed", 0))
var parts := ["Talk %d" % conversations.size()]
var parts := ["Council %d" % conversations.size()]
if ready > 0:
parts.append("%d supply" % ready)
if claimed > 0:
@@ -4375,8 +4375,8 @@ func _format_briefing_shop_overview_text() -> String:
if buy_count <= 0 and sell_count <= 0:
return ""
if sell_count > 0:
return "Shop %d buy, %d sell" % [buy_count, sell_count]
return "Shop %d buy" % buy_count
return "Market %d goods, %d sale" % [buy_count, sell_count]
return "Market %d goods" % buy_count
func _format_briefing_roster_overview_text() -> String:
@@ -4385,15 +4385,15 @@ func _format_briefing_roster_overview_text() -> String:
var deployed_count := state.get_deployed_player_count()
var max_units := state.get_deployment_max_units()
if max_units > 0:
return "Deploy %d/%d" % [deployed_count, max_units]
return "Deploy %d" % deployed_count
return "Muster %d/%d" % [deployed_count, max_units]
return "Muster %d" % deployed_count
func _format_briefing_formation_overview_text() -> String:
var formation_count := state.get_formation_cells().size()
if formation_count <= 0:
return ""
return "Formation %d tiles" % formation_count
return "Array %d tiles" % formation_count
func _camp_conversation_supply_counts(conversations: Array) -> Dictionary:
@@ -4519,7 +4519,7 @@ func _rebuild_chapter_menu() -> void:
child.queue_free()
var entries := campaign_state.get_chapter_progress_entries()
if chapter_status_label != null:
chapter_status_label.text = "%s chapters | %d/%d battles complete" % [
chapter_status_label.text = "%s scrolls - %d/%d fields sealed" % [
campaign_state.campaign_title,
campaign_state.completed_scenarios.size(),
campaign_state.get_scenario_count()
@@ -4823,7 +4823,7 @@ func _format_camp_conversation_preview_text(conversation: Dictionary) -> String:
parts.append(_short_preview_text(first_text, 96))
if parts.is_empty():
return "No preview text"
return _join_strings(parts, " | ")
return _join_strings(parts, " - ")
func _camp_conversation_preview_speaker(conversation: Dictionary) -> String:
@@ -5085,7 +5085,7 @@ func _format_current_checkpoint_text() -> String:
var title := campaign_state.get_scenario_title(campaign_state.current_scenario_id)
if title.is_empty():
title = campaign_state.get_scenario_title(campaign_state.get_start_scenario_id())
return "Current: %s | %d/%d complete | Gold %d" % [
return "Current Seal: %s - %d/%d sealed - Treasury %dG" % [
title,
campaign_state.completed_scenarios.size(),
campaign_state.get_scenario_count(),
@@ -5096,12 +5096,12 @@ func _format_current_checkpoint_text() -> String:
func _format_manual_checkpoint_text() -> String:
var summary := campaign_state.get_manual_save_summary()
if summary.is_empty():
return "Manual: empty"
return "Manual Seal: empty"
var title := str(summary.get("current_scenario_title", ""))
if title.is_empty():
title = str(summary.get("current_scenario_id", "Unknown"))
var pending_suffix := " | choice pending" if bool(summary.get("pending_choice", false)) else ""
return "Manual: %s | %d/%d complete | Gold %d%s" % [
var pending_suffix := " - council pending" if bool(summary.get("pending_choice", false)) else ""
return "Manual Seal: %s - %d/%d sealed - Treasury %dG%s" % [
title,
int(summary.get("completed_count", 0)),
int(summary.get("total_count", 0)),
@@ -5265,9 +5265,9 @@ func _rebuild_formation_menu() -> void:
if formation_status_label != null:
var selected := state.get_unit(formation_unit_id)
if selected.is_empty():
formation_status_label.text = "Formation"
formation_status_label.text = "Array"
else:
formation_status_label.text = "Formation: %s at %s" % [
formation_status_label.text = "Array: %s at %s" % [
str(selected.get("name", "Officer")),
_format_cell_label(selected.get("pos", Vector2i.ZERO))
]
@@ -5487,8 +5487,8 @@ func _rebuild_shop_menu() -> void:
return
_clear_shop_list()
if shop_status_label != null:
var mode_text := "Sell" if shop_sell_mode else "Buy"
shop_status_label.text = "%s | Gold %d | %s" % [
var mode_text := "Offer" if shop_sell_mode else "Acquire"
shop_status_label.text = "%s - Treasury %dG - %s" % [
mode_text,
campaign_state.gold,
_format_inventory_status_text()
@@ -5677,11 +5677,11 @@ func _make_shop_item_icon_panel(item_id: String, item: Dictionary) -> PanelConta
func _format_shop_buy_action_text(item_id: String, _item: Dictionary, price: int) -> String:
return "Buy %s %dG" % [_item_display_name(item_id), price]
return "Acquire %s %dG" % [_item_display_name(item_id), price]
func _format_shop_sell_action_text(item_id: String, _item: Dictionary, sale_price: int) -> String:
return "Sell %s %dG" % [_item_display_name(item_id), sale_price]
return "Offer %s %dG" % [_item_display_name(item_id), sale_price]
func _format_shop_buy_item_detail_text(_item_id: String, item: Dictionary, price: int, owned: int, stock_limit: int = -1, remaining: int = -1) -> String:
@@ -5692,13 +5692,13 @@ func _format_shop_buy_item_detail_text(_item_id: String, item: Dictionary, price
parts.append("Sold out")
elif campaign_state.gold < price:
parts.append("Need %dG" % (price - campaign_state.gold))
return _join_strings(parts, " | ")
return _join_strings(parts, " - ")
func _format_shop_sell_item_detail_text(_item_id: String, item: Dictionary, _sale_price: int, owned: int) -> String:
var parts := _shop_item_common_detail_parts(item, owned)
parts.append("Half-price sale")
return _join_strings(parts, " | ")
return _join_strings(parts, " - ")
func _shop_item_common_detail_parts(item: Dictionary, owned: int) -> Array:
@@ -5739,7 +5739,7 @@ func _format_shop_item_button_text(item_id: String, item: Dictionary, price: int
func _format_shop_sell_item_button_text(item_id: String, item: Dictionary, sale_price: int, owned: int) -> String:
return "%s Sell %dG %s Owned x%d" % [
return "%s Offer %dG %s Owned x%d" % [
_item_display_name(item_id),
sale_price,
_format_shop_item_effect_text(item),
@@ -5927,7 +5927,7 @@ func _format_post_battle_choice_text(choice: Dictionary) -> String:
else:
text = "%s - %s" % [label, description]
if not reward_text.is_empty():
text += "\nRewards: %s" % reward_text
text += "\nSpoils: %s" % reward_text
return text
@@ -6007,22 +6007,22 @@ func _format_battle_result_summary() -> String:
return ""
if battle_result_summary.get("pending_choice", false):
var pending_next := str(battle_result_summary.get("next_scenario_title", ""))
var pending_text := "Campaign\n Saved\nChoice\n Select a campaign response."
var pending_text := "Chronicle\n Sealed\nCouncil\n Select a response."
if not pending_next.is_empty():
pending_text += "\nNext\n %s" % pending_next
pending_text += "\nNext March\n %s" % pending_next
return pending_text
if battle_result_summary.get("already_completed", false):
var already_saved := "Campaign unchanged." if battle_result_summary.get("saved", false) else "Campaign replay failed."
var already_saved := "Chronicle unchanged." if battle_result_summary.get("saved", false) else "Chronicle replay failed."
var already_next := str(battle_result_summary.get("next_scenario_title", ""))
var replay_lines := [
"Rewards\n Already claimed",
"Campaign\n %s" % already_saved
"Spoils\n Already claimed",
"Chronicle\n %s" % already_saved
]
if not already_next.is_empty():
replay_lines.append("Next\n %s" % already_next)
replay_lines.append("Next March\n %s" % already_next)
var replay_preview := _format_next_camp_preview_text(str(battle_result_summary.get("next_scenario_id", "")))
if not replay_preview.is_empty():
replay_lines.append("Next Camp\n %s" % replay_preview)
replay_lines.append("Next Encampment\n %s" % replay_preview)
return _join_strings(replay_lines, "\n")
var items: Array = battle_result_summary.get("items", [])
@@ -6033,9 +6033,9 @@ func _format_battle_result_summary() -> String:
if gold_reward > 0:
reward_lines.append("Gold +%d" % gold_reward)
if item_text != "none":
reward_lines.append("Items: %s" % item_text)
reward_lines.append("Goods: %s" % item_text)
else:
reward_lines.append("Not applied")
reward_lines.append("Not recorded")
var roster_lines := []
var joined_officers: Array = battle_result_summary.get("joined_officers", [])
@@ -6046,30 +6046,30 @@ func _format_battle_result_summary() -> String:
roster_lines.append("Left: %s" % _format_officer_id_list(left_officers))
var sections := [
"Rewards\n %s" % _join_strings(reward_lines, "\n ")
"Spoils\n %s" % _join_strings(reward_lines, "\n ")
]
if not roster_lines.is_empty():
sections.append("Roster\n %s" % _join_strings(roster_lines, "\n "))
sections.append("Muster\n %s" % _join_strings(roster_lines, "\n "))
var progression_text := _format_progression_events(battle_result_summary.get("progression_events", []))
if not progression_text.is_empty():
sections.append("Growth\n %s" % progression_text)
var saved_text := "Campaign saved." if battle_result_summary.get("saved", false) else "Campaign save failed."
var next_text := "Campaign complete."
sections.append("Merit\n %s" % progression_text)
var saved_text := "Chronicle sealed." if battle_result_summary.get("saved", false) else "Chronicle seal failed."
var next_text := "Chronicle complete."
var next_title := str(battle_result_summary.get("next_scenario_title", ""))
if not next_title.is_empty():
next_text = "Next: %s" % next_title
sections.append("Campaign\n Total gold: %d\n %s\n %s" % [
next_text = "Next March: %s" % next_title
sections.append("Chronicle\n Treasury: %dG\n %s\n %s" % [
campaign_state.gold,
saved_text,
next_text
])
if not bool(battle_result_summary.get("choice_applied", true)):
sections.append("Choice\n Select a campaign response.")
sections.append("Council\n Select a response.")
elif not str(battle_result_summary.get("choice_label", "")).is_empty():
sections.append("Choice\n %s" % str(battle_result_summary.get("choice_label", "")))
sections.append("Council\n %s" % str(battle_result_summary.get("choice_label", "")))
var next_preview := _format_next_camp_preview_text(str(battle_result_summary.get("next_scenario_id", "")))
if not next_preview.is_empty() and bool(battle_result_summary.get("saved", false)):
sections.append("Next Camp\n %s" % next_preview)
sections.append("Next Encampment\n %s" % next_preview)
return _join_strings(sections, "\n")
@@ -6106,19 +6106,19 @@ func _format_next_camp_preview_text(next_scenario_id: String) -> String:
parts.append(location)
var talk_count := _briefing_camp_conversation_count(briefing)
if talk_count > 0:
parts.append("Talk %d" % talk_count)
parts.append("Council %d" % talk_count)
var shop_count := preview_state.get_shop_item_ids().size()
if shop_count > 0:
parts.append("Shop %d goods" % shop_count)
parts.append("Market %d goods" % shop_count)
if preview_state.has_deployment_roster():
parts.append("Deploy %d/%d" % [
parts.append("Muster %d/%d" % [
preview_state.get_deployed_player_count(),
preview_state.get_deployment_max_units()
])
var formation_count := preview_state.get_formation_cells().size()
if formation_count > 0:
parts.append("Formation %d tiles" % formation_count)
return _join_strings(parts, " | ")
parts.append("Array %d tiles" % formation_count)
return _join_strings(parts, " - ")
func _briefing_camp_conversation_count(briefing: Dictionary) -> int:
@@ -6217,7 +6217,7 @@ func _format_inventory_by_category(inventory: Dictionary) -> String:
sections.append("Other: %s" % _format_inventory_items(other))
if sections.is_empty():
return "none"
return _join_strings(sections, " | ")
return _join_strings(sections, " - ")
func _format_officer_id_list(values) -> String:

View File

@@ -35,18 +35,18 @@ func _init() -> void:
"choice_label": ""
}
var result_text: String = scene._format_battle_result_summary()
_check_contains(failures, "reward section", result_text, "Rewards")
_check_contains(failures, "reward section", result_text, "Spoils")
_check_contains(failures, "gold reward", result_text, "Gold +100")
_check_contains(failures, "item reward", result_text, "Bean x2")
_check_contains(failures, "roster section", result_text, "Joined: Dian Wei")
_check_contains(failures, "growth section", result_text, "Cao Cao Lv.2")
_check_contains(failures, "campaign section", result_text, "Next: Sishui Gate")
_check_contains(failures, "next camp section", result_text, "Next Camp")
_check_contains(failures, "campaign section", result_text, "Next March: Sishui Gate")
_check_contains(failures, "next camp section", result_text, "Next Encampment")
_check_contains(failures, "next camp location", result_text, "Sishui Gate, 190 CE")
_check_contains(failures, "next camp talk", result_text, "Talk 3")
_check_contains(failures, "next camp shop", result_text, "Shop 6 goods")
_check_contains(failures, "next camp deploy", result_text, "Deploy 2/3")
_check_contains(failures, "next camp formation", result_text, "Formation 6 tiles")
_check_contains(failures, "next camp talk", result_text, "Council 3")
_check_contains(failures, "next camp shop", result_text, "Market 6 goods")
_check_contains(failures, "next camp deploy", result_text, "Muster 2/3")
_check_contains(failures, "next camp formation", result_text, "Array 6 tiles")
scene.battle_result_summary = {
"saved": false,
@@ -63,8 +63,8 @@ func _init() -> void:
"choice_label": ""
}
var failed_save_text: String = scene._format_battle_result_summary()
_check_contains(failures, "failed rewards", failed_save_text, "Not applied")
_check_contains(failures, "failed save", failed_save_text, "Campaign save failed")
_check_contains(failures, "failed rewards", failed_save_text, "Not recorded")
_check_contains(failures, "failed save", failed_save_text, "Chronicle seal failed")
scene.battle_result_summary = {
"saved": true,
@@ -77,13 +77,13 @@ func _init() -> void:
failures,
"pending choice prompt",
pending_choice_text,
"Select a campaign response"
"Select a response"
)
_check_not_contains(
failures,
"pending choice should wait for response before next camp preview",
pending_choice_text,
"Next Camp"
"Next Encampment"
)
scene.battle_result_summary = {

View File

@@ -1101,7 +1101,7 @@ func _check_scene_texture_loading(failures: Array[String]) -> void:
if not merchant_notice.contains("Camp Merchant") or not merchant_notice.contains("Roadside stores"):
failures.append("shop merchant notice should include name and flavor lines")
var camp_overview := scene._format_briefing_camp_overview_text(scene.state.get_briefing(), false)
for expected in ["Yingchuan, 184 CE", "Gold 0G", "Talk 3", "1 supply", "Shop 2 buy", "Deploy 2/2", "Formation 4 tiles", "Armory ready"]:
for expected in ["Yingchuan, 184 CE", "Treasury 0G", "Council 3", "1 supply", "Market 2 goods", "Muster 2/2", "Array 4 tiles", "Arsenal ready"]:
if not camp_overview.contains(expected):
failures.append("camp overview should include %s: %s" % [expected, camp_overview])
var bean: Dictionary = scene.state.get_item_def("bean")
@@ -1119,7 +1119,7 @@ func _check_scene_texture_loading(failures: Array[String]) -> void:
if not sell_detail.contains("Half-price sale") or not sell_detail.contains("Owned x2"):
failures.append("shop sell detail should summarize sale rule and owned count")
var bean_action := scene._format_shop_buy_action_text("bean", bean, int(bean.get("price", 0)))
if not bean_action.contains("Buy Bean") or not bean_action.contains("50G"):
if not bean_action.contains("Acquire Bean") or not bean_action.contains("50G"):
failures.append("shop buy action should be concise and priced")
var bean_tooltip := scene._format_shop_item_tooltip_text(
scene._format_shop_item_button_text("bean", bean, int(bean.get("price", 0)), 0),
@@ -1164,28 +1164,28 @@ func _check_hud_focus_text(failures: Array[String]) -> void:
var cao_text := scene._format_unit_focus_text(cao_cao, "Selected")
if not cao_text.contains("Command tactics"):
failures.append("Cao Cao HUD focus should describe command role: %s" % cao_text)
if not cao_text.contains("Move 4 (Foot)") or not cao_text.contains("Attack range 1-1"):
if not cao_text.contains("March 4 (Foot)") or not cao_text.contains("Strike reach 1-1"):
failures.append("Cao Cao HUD focus should clarify move/attack affordance: %s" % cao_text)
if not cao_text.contains("Action:") or not cao_text.contains("Move") or not cao_text.contains("Attack") or not cao_text.contains("Tactic") or not cao_text.contains("Equip") or not cao_text.contains("Wait"):
if not cao_text.contains("Order:") or not cao_text.contains("March") or not cao_text.contains("Strike") or not cao_text.contains("Tactic") or not cao_text.contains("Arms") or not cao_text.contains("Wait"):
failures.append("Cao Cao HUD focus should summarize available actions: %s" % cao_text)
if not cao_text.contains("Tile 2,4"):
if not cao_text.contains("Ground 2,4"):
failures.append("Cao Cao HUD focus should include current tile: %s" % cao_text)
if not cao_text.contains("Cost 1"):
if not cao_text.contains("March 1"):
failures.append("Cao Cao HUD focus should include terrain move cost: %s" % cao_text)
if not cao_text.contains("DEF +0"):
if not cao_text.contains("Guard +0"):
failures.append("Cao Cao HUD focus should include terrain defense: %s" % cao_text)
var xiahou_dun: Dictionary = scene.state.get_unit("xiahou_dun")
xiahou_dun["pos"] = Vector2i(3, 1)
var forest_text := scene._unit_current_terrain_text(xiahou_dun)
if not forest_text.contains("Forest") or not forest_text.contains("Cost 3"):
if not forest_text.contains("Forest") or not forest_text.contains("March 3"):
failures.append("Cavalry movement should use mounted move_type cost on forest: %s" % forest_text)
var archer: Dictionary = scene.state.get_unit("yellow_turban_3")
var archer_text := scene._format_unit_focus_text(archer, "Hover")
if not archer_text.contains("Ranged pressure"):
failures.append("Archer HUD focus should describe ranged role: %s" % archer_text)
if not archer_text.contains("Move 4 (Archer)") or not archer_text.contains("Attack range 2-2"):
if not archer_text.contains("March 4 (Archer)") or not archer_text.contains("Strike reach 2-2"):
failures.append("Archer HUD focus should clarify ranged attack affordance: %s" % archer_text)
if not archer_text.contains("Action: Enemy AI"):
if not archer_text.contains("Order: Enemy command"):
failures.append("Enemy archer HUD focus should describe enemy control: %s" % archer_text)
if not scene._unit_current_terrain_text(archer).contains("Plain"):
failures.append("Archer terrain text should reflect its current plain tile")
@@ -1212,10 +1212,10 @@ func _check_ancient_ui_theme(failures: Array[String]) -> void:
_check_panel_style_fill(failures, scene.dialogue_portrait_panel, "dialogue portrait panel", Color(0.055, 0.025, 0.016, 1.0))
_check_panel_style_fill(failures, scene.dialogue_speaker_panel, "dialogue speaker seal panel", Color(0.32, 0.025, 0.016, 1.0))
_check_panel_style_fill(failures, scene.dialogue_text_panel, "dialogue text scroll panel", Color(0.76, 0.64, 0.43, 0.98))
if scene.dialogue_continue_button == null or scene.dialogue_continue_button.text != "Continue":
failures.append("dialogue continue button should use ancient continue text")
if scene.dialogue_previous_button == null or scene.dialogue_previous_button.text != "Prior":
failures.append("dialogue previous button should use ancient prior text")
if scene.dialogue_continue_button == null or scene.dialogue_continue_button.text != "Advance":
failures.append("dialogue continue button should use ancient advance text")
if scene.dialogue_previous_button == null or scene.dialogue_previous_button.text != "Recall":
failures.append("dialogue previous button should use ancient recall text")
_check_panel_style_fill(failures, scene.result_panel, "result panel", Color(0.66, 0.55, 0.36, 0.97))
scene.free()