Polish story controls and command guidance

This commit is contained in:
2026-06-20 16:07:28 +09:00
parent 3ee22167a3
commit fead876200
5 changed files with 179 additions and 41 deletions

View File

@@ -226,6 +226,7 @@ func _check_scene_post_move_menu_flow(failures: Array[String]) -> void:
scene.post_move_wait_button,
scene.post_move_cancel_button
], "post-move action menu")
_check_post_move_command_guidance(failures, scene)
if cao_cao.get("pos", Vector2i.ZERO) != Vector2i(2, 3) or not bool(cao_cao.get("moved", false)) or bool(cao_cao.get("acted", false)):
failures.append("scene move should be pending with action still available")
if scene.state.get_selected_unit().is_empty():
@@ -1138,6 +1139,54 @@ func _check_local_command_button_tooltips_present(failures: Array[String], butto
failures.append("%s should explain icon function through hover tooltip" % label)
func _check_post_move_command_guidance(failures: Array[String], scene) -> void:
var expectations := [
{
"button": scene.post_move_attack_button,
"label": "타격령",
"hint": "적 표식 지목",
"detail": "이동과 타격을 한 군령"
},
{
"button": scene.post_move_tactic_button,
"label": "책략첩",
"hint": "죽간 펼침",
"detail": "빛나는 표식 칸"
},
{
"button": scene.post_move_item_button,
"label": "보급첩",
"hint": "보급 지목",
"detail": "회복이나 도구를 받을 부대"
},
{
"button": scene.post_move_wait_button,
"label": "대기령",
"hint": "그 자리 대기",
"detail": "군령을 마치고"
},
{
"button": scene.post_move_cancel_button,
"label": "발걸음 거두기",
"hint": "이동 취소",
"detail": "원래 자리에서 다시 군령"
}
]
for expectation in expectations:
var button: Button = expectation["button"]
if button == null:
failures.append("post-move command guidance button missing: %s" % str(expectation["label"]))
continue
if str(button.get_meta("command_label", "")) != str(expectation["label"]):
failures.append("post-move command should keep label metadata: %s" % str(button.get_meta("command_label", "")))
if str(button.get_meta("command_hint", "")) != str(expectation["hint"]):
failures.append("post-move command should keep short hover hint `%s`: %s" % [str(expectation["hint"]), str(button.get_meta("command_hint", ""))])
if not str(button.get_meta("command_hint_detail", "")).contains(str(expectation["detail"])):
failures.append("post-move command should keep rich hover detail `%s`: %s" % [str(expectation["detail"]), str(button.get_meta("command_hint_detail", ""))])
if not str(button.tooltip_text).contains(str(expectation["detail"])):
failures.append("post-move command tooltip should explain `%s`: %s" % [str(expectation["detail"]), str(button.tooltip_text)])
func _check_post_move_picker_option_tooltips_present(failures: Array[String], scene, label: String) -> void:
if scene.post_move_picker_list == null:
failures.append("%s should expose a picker option list" % label)

View File

@@ -307,11 +307,11 @@ func _check_title_menu_start_load_and_settings(failures: Array[String]) -> void:
if opening_story_strip.custom_minimum_size.x > 340.0 or opening_story_strip.custom_minimum_size.y > 54.0:
failures.append("opening story ledger should stay compact beside the chapter seal: %s" % str(opening_story_strip.custom_minimum_size))
_check_control_inside_design_view(failures, opening_story_strip as Control, "opening story ledger")
if scene.opening_prologue_next_button == null or scene.opening_prologue_next_button.text != "다음 기록":
if scene.opening_prologue_next_button == null or scene.opening_prologue_next_button.text != "기록 넘기기":
failures.append("opening prologue next button should read as a story action")
else:
_check_opening_story_button_art(failures, scene.opening_prologue_next_button, "opening next")
if scene.opening_prologue_skip_button == null or scene.opening_prologue_skip_button.text != "서문 접기":
if scene.opening_prologue_skip_button == null or scene.opening_prologue_skip_button.text != "군막으로 바로":
failures.append("opening prologue skip button should read as a contextual camp shortcut")
else:
_check_opening_story_button_art(failures, scene.opening_prologue_skip_button, "opening skip")
@@ -537,6 +537,8 @@ func _check_title_menu_button_art(failures: Array[String], button: Button, expec
failures.append("%s generated button texture should keep high-resolution source pixels: %dx%d" % [context, style.texture.get_width(), style.texture.get_height()])
if style.texture_margin_top > 24 or style.texture_margin_bottom > 24:
failures.append("%s generated button slice should stay shallow enough for the 720p title menu: %d/%d" % [context, style.texture_margin_top, style.texture_margin_bottom])
if style.axis_stretch_horizontal != StyleBoxTexture.AXIS_STRETCH_MODE_TILE_FIT or style.axis_stretch_vertical != StyleBoxTexture.AXIS_STRETCH_MODE_TILE_FIT:
failures.append("%s generated button surface should tile-fit its 9-slice center so QHD fullscreen does not smear the ornament" % context)
_check_button_texture_slice_fit(failures, button, context)
if str(button.tooltip_text).strip_edges().is_empty():
failures.append("%s should describe its command through a tooltip" % context)
@@ -561,6 +563,8 @@ func _check_opening_story_button_art(failures: Array[String], button: Button, co
var style := stylebox as StyleBoxTexture
if style.texture_margin_left < 24 or style.texture_margin_top < 10:
failures.append("%s generated button slices should preserve the ornamental frame at QHD: %d/%d" % [context, style.texture_margin_left, style.texture_margin_top])
if style.axis_stretch_horizontal != StyleBoxTexture.AXIS_STRETCH_MODE_TILE_FIT or style.axis_stretch_vertical != StyleBoxTexture.AXIS_STRETCH_MODE_TILE_FIT:
failures.append("%s generated button surface should tile-fit its 9-slice center at QHD" % context)
_check_button_texture_slice_fit(failures, button, context)
if button.get_theme_font_size("font_size") > 17:
failures.append("%s should stay visually quiet in the story caption" % context)

View File

@@ -3981,7 +3981,7 @@ func _check_opening_prologue_presentation(failures: Array[String]) -> void:
if scene.opening_prologue_next_button == null:
failures.append("opening prologue should expose a next button")
else:
if scene.opening_prologue_next_button.text != "다음 기록":
if scene.opening_prologue_next_button.text != "기록 넘기기":
failures.append("opening next button should use story-fluent Korean text")
if scene.opening_prologue_next_button.icon == null:
failures.append("opening next button should carry generated icon art")
@@ -3991,7 +3991,7 @@ func _check_opening_prologue_presentation(failures: Array[String]) -> void:
if scene.opening_prologue_skip_button == null:
failures.append("opening prologue should expose a skip button")
else:
if scene.opening_prologue_skip_button.text != "서문 접기":
if scene.opening_prologue_skip_button.text != "군막으로 바로":
failures.append("opening skip button should avoid modern skip-button wording")
if scene.opening_prologue_skip_button.icon == null:
failures.append("opening skip button should carry generated icon art")
@@ -4441,6 +4441,8 @@ func _check_button_uses_generated_surface(failures: Array[String], button: Butto
failures.append("%s generated icon button texture should keep high-resolution source pixels: %dx%d" % [context, style.texture.get_width(), style.texture.get_height()])
if abs(style.texture.get_width() - style.texture.get_height()) > 4:
failures.append("%s generated icon button texture should be square or near-square: %dx%d" % [context, style.texture.get_width(), style.texture.get_height()])
if style.axis_stretch_horizontal != StyleBoxTexture.AXIS_STRETCH_MODE_TILE_FIT or style.axis_stretch_vertical != StyleBoxTexture.AXIS_STRETCH_MODE_TILE_FIT:
failures.append("%s generated icon button surface should tile-fit its center for QHD fullscreen" % context)
_check_button_texture_slice_for_control(failures, button, style, context, 10, 10)
if style.content_margin_left < 5 or style.content_margin_top < 5:
failures.append("%s generated icon button texture should reserve icon content margins" % context)
@@ -4449,6 +4451,8 @@ func _check_button_uses_generated_surface(failures: Array[String], button: Butto
failures.append("%s text button should keep the wide generated button surface" % context)
if style.texture.get_width() < 512 or style.texture.get_height() < 192:
failures.append("%s generated button texture should keep high-resolution source pixels: %dx%d" % [context, style.texture.get_width(), style.texture.get_height()])
if style.axis_stretch_horizontal != StyleBoxTexture.AXIS_STRETCH_MODE_TILE_FIT or style.axis_stretch_vertical != StyleBoxTexture.AXIS_STRETCH_MODE_TILE_FIT:
failures.append("%s generated button surface should tile-fit its 9-slice center so QHD fullscreen does not smear the ornament" % context)
var min_top_margin := 10 if bool(button.get_meta("opening_story_button", false)) else 10
_check_button_texture_slice_for_control(failures, button, style, context, 16, min_top_margin)
var min_content_margin := 6 if bool(button.get_meta("opening_story_button", false)) else 8