Add enemy inspection detail from overview
This commit is contained in:
@@ -102,30 +102,34 @@ func _capture_viewport_set(spec: Dictionary, output_dir: String, captures: Array
|
||||
await _settle()
|
||||
await _capture_frame(scene, output_dir, label, "07_battle_idle", captures, failures)
|
||||
|
||||
_prepare_enemy_inspection_frame(scene)
|
||||
await _settle()
|
||||
await _capture_frame(scene, output_dir, label, "08_battle_enemy_inspection", captures, failures)
|
||||
|
||||
_prepare_auto_attack_hint_frame(scene)
|
||||
await _settle()
|
||||
await _capture_frame(scene, output_dir, label, "08_battle_auto_attack_hint", captures, failures)
|
||||
await _capture_frame(scene, output_dir, label, "09_battle_auto_attack_hint", captures, failures)
|
||||
|
||||
scene._update_threat_button()
|
||||
scene._on_command_hint_button_mouse_entered(scene.threat_button)
|
||||
await _settle()
|
||||
await _capture_frame(scene, output_dir, label, "09_battle_threat_hint", captures, failures)
|
||||
await _capture_frame(scene, output_dir, label, "10_battle_threat_hint", captures, failures)
|
||||
|
||||
_prepare_post_move_action_frame(scene, "")
|
||||
await _settle()
|
||||
await _capture_frame(scene, output_dir, label, "10_post_move_actions", captures, failures)
|
||||
await _capture_frame(scene, output_dir, label, "11_post_move_actions", captures, failures)
|
||||
|
||||
_prepare_post_move_action_frame(scene, "tactic")
|
||||
await _settle()
|
||||
await _capture_frame(scene, output_dir, label, "11_post_move_tactic_picker", captures, failures)
|
||||
await _capture_frame(scene, output_dir, label, "12_post_move_tactic_picker", captures, failures)
|
||||
|
||||
_prepare_post_move_action_frame(scene, "item")
|
||||
await _settle()
|
||||
await _capture_frame(scene, output_dir, label, "12_post_move_item_picker", captures, failures)
|
||||
await _capture_frame(scene, output_dir, label, "13_post_move_item_picker", captures, failures)
|
||||
|
||||
_prepare_combat_result_frame(scene)
|
||||
await _settle()
|
||||
await _capture_frame(scene, output_dir, label, "13_battle_combat_result", captures, failures)
|
||||
await _capture_frame(scene, output_dir, label, "14_battle_combat_result", captures, failures)
|
||||
|
||||
scene.queue_free()
|
||||
await _settle()
|
||||
@@ -159,6 +163,35 @@ func _prepare_auto_attack_hint_frame(scene) -> void:
|
||||
scene.queue_redraw()
|
||||
|
||||
|
||||
func _prepare_enemy_inspection_frame(scene) -> void:
|
||||
scene._hide_command_hint()
|
||||
scene._hide_post_move_menu()
|
||||
scene._hide_post_move_picker()
|
||||
scene._hide_tactic_menu()
|
||||
scene._hide_item_menu()
|
||||
scene._hide_equip_menu()
|
||||
scene._clear_pending_move_state()
|
||||
scene.selected_skill_id = ""
|
||||
scene.selected_item_id = ""
|
||||
scene.basic_attack_targeting = false
|
||||
scene.state.clear_selection()
|
||||
scene.side_unit_overview_mode = "enemy"
|
||||
scene.side_inspected_unit_id = ""
|
||||
var enemy: Dictionary = scene.state.get_unit("yellow_turban_1")
|
||||
if enemy.is_empty():
|
||||
return
|
||||
enemy["alive"] = true
|
||||
var enemy_cell: Vector2i = enemy.get("pos", Vector2i(-1, -1))
|
||||
if not scene.state.is_inside(enemy_cell):
|
||||
enemy_cell = Vector2i(10, 4)
|
||||
enemy["pos"] = enemy_cell
|
||||
scene.hover_cell = enemy_cell
|
||||
scene._focus_board_on_cell(enemy_cell, true, true)
|
||||
scene._on_side_unit_overview_row_pressed("yellow_turban_1")
|
||||
scene._update_hud()
|
||||
scene.queue_redraw()
|
||||
|
||||
|
||||
func _prepare_post_move_action_frame(scene, picker_mode: String) -> void:
|
||||
scene._hide_command_hint()
|
||||
scene._hide_post_move_menu()
|
||||
|
||||
@@ -3625,6 +3625,25 @@ func _check_hud_focus_text(failures: Array[String]) -> void:
|
||||
failures.append("enemy overview row click should focus without selecting enemy units: %s" % scene.state.selected_unit_id)
|
||||
if not scene.move_cells.is_empty():
|
||||
failures.append("enemy overview row click should not leave player movement ranges visible")
|
||||
if scene.side_inspected_unit_id != "yellow_turban_1":
|
||||
failures.append("enemy overview row click should open an inspection card: %s" % scene.side_inspected_unit_id)
|
||||
if scene.side_unit_overview_panel == null or scene.side_unit_overview_panel.visible:
|
||||
failures.append("enemy inspection should replace the overview list with a unit detail card")
|
||||
if scene.hud_unit_focus_row == null or not scene.hud_unit_focus_row.visible:
|
||||
failures.append("enemy inspection should show the focused unit detail card")
|
||||
if scene.selected_label == null or not scene.selected_label.text.contains("정찰:"):
|
||||
failures.append("enemy inspection card should be labeled as scout detail: %s" % ("" if scene.selected_label == null else scene.selected_label.text))
|
||||
if scene.hud_command_grid != null and scene.hud_command_grid.visible:
|
||||
failures.append("enemy inspection should not expose player command buttons")
|
||||
if not scene._hover_info_badge().is_empty():
|
||||
failures.append("enemy inspection should keep duplicate map hover badges hidden")
|
||||
scene._handle_cancel_input()
|
||||
if scene.side_inspected_unit_id != "":
|
||||
failures.append("cancel should close enemy inspection: %s" % scene.side_inspected_unit_id)
|
||||
if scene.side_unit_overview_panel == null or not scene.side_unit_overview_panel.visible:
|
||||
failures.append("canceling enemy inspection should return to the overview list")
|
||||
if scene.side_unit_overview_enemy_button == null or not scene.side_unit_overview_enemy_button.button_pressed:
|
||||
failures.append("canceling enemy inspection should preserve the enemy overview tab")
|
||||
scene._on_side_unit_overview_tab_pressed("ally")
|
||||
if scene.inventory_label == null or scene.inventory_label.text != "군수 대기":
|
||||
failures.append("empty battle inventory line should not show noisy stock text: %s" % ("" if scene.inventory_label == null else scene.inventory_label.text))
|
||||
|
||||
Reference in New Issue
Block a user