Improve Korean text readability surfaces

This commit is contained in:
2026-06-20 18:32:40 +09:00
parent 21aaaca441
commit 9da1833949
3 changed files with 93 additions and 53 deletions

View File

@@ -144,26 +144,26 @@ const DIALOGUE_COLUMN_SIZE := Vector2(850, 318)
const DIALOGUE_TEXT_SIZE := Vector2(830, 188) const DIALOGUE_TEXT_SIZE := Vector2(830, 188)
const OBJECTIVE_HUD_FONT_SIZE := 14 const OBJECTIVE_HUD_FONT_SIZE := 14
const OBJECTIVE_HUD_MIN_FONT_SIZE := 12 const OBJECTIVE_HUD_MIN_FONT_SIZE := 12
const OBJECTIVE_NOTICE_FONT_SIZE := 16 const OBJECTIVE_NOTICE_FONT_SIZE := 17
const OBJECTIVE_NOTICE_MIN_FONT_SIZE := 14 const OBJECTIVE_NOTICE_MIN_FONT_SIZE := 15
const BRIEFING_TITLE_FONT_SIZE := 22 const BRIEFING_TITLE_FONT_SIZE := 22
const BRIEFING_TITLE_MIN_FONT_SIZE := 18 const BRIEFING_TITLE_MIN_FONT_SIZE := 18
const BRIEFING_LOCATION_FONT_SIZE := 16 const BRIEFING_LOCATION_FONT_SIZE := 16
const BRIEFING_LOCATION_MIN_FONT_SIZE := 13 const BRIEFING_LOCATION_MIN_FONT_SIZE := 13
const BRIEFING_OBJECTIVE_FONT_SIZE := 17 const BRIEFING_OBJECTIVE_FONT_SIZE := 18
const BRIEFING_OBJECTIVE_MIN_FONT_SIZE := 14 const BRIEFING_OBJECTIVE_MIN_FONT_SIZE := 15
const BRIEFING_BODY_FONT_SIZE := 17 const BRIEFING_BODY_FONT_SIZE := 18
const BRIEFING_BODY_MIN_FONT_SIZE := 15 const BRIEFING_BODY_MIN_FONT_SIZE := 16
const BRIEFING_OVERVIEW_FONT_SIZE := 16 const BRIEFING_OVERVIEW_FONT_SIZE := 17
const BRIEFING_OVERVIEW_MIN_FONT_SIZE := 13 const BRIEFING_OVERVIEW_MIN_FONT_SIZE := 14
const BRIEFING_VISIBLE_BODY_LINES := 3 const BRIEFING_VISIBLE_BODY_LINES := 3
const BRIEFING_VISIBLE_BODY_CHARS := 46 const BRIEFING_VISIBLE_BODY_CHARS := 46
const COMMAND_NOTICE_VISIBLE_BODY_LINES := 2 const COMMAND_NOTICE_VISIBLE_BODY_LINES := 2
const COMMAND_NOTICE_VISIBLE_BODY_CHARS := 44 const COMMAND_NOTICE_VISIBLE_BODY_CHARS := 44
const DIALOGUE_SPEAKER_FONT_SIZE := 20 const DIALOGUE_SPEAKER_FONT_SIZE := 20
const DIALOGUE_SPEAKER_MIN_FONT_SIZE := 16 const DIALOGUE_SPEAKER_MIN_FONT_SIZE := 16
const DIALOGUE_TEXT_FONT_SIZE := 19 const DIALOGUE_TEXT_FONT_SIZE := 20
const DIALOGUE_TEXT_MIN_FONT_SIZE := 16 const DIALOGUE_TEXT_MIN_FONT_SIZE := 17
const DIALOGUE_VISIBLE_BODY_LINES := 5 const DIALOGUE_VISIBLE_BODY_LINES := 5
const DIALOGUE_VISIBLE_BODY_CHARS := 44 const DIALOGUE_VISIBLE_BODY_CHARS := 44
const OPENING_VISIBLE_BODY_LINES := 3 const OPENING_VISIBLE_BODY_LINES := 3
@@ -252,13 +252,13 @@ const LOCAL_COMMAND_PANEL_BOARD_PADDING := 4.0
const UI_RICE_PAPER := Color(0.48, 0.46, 0.39, 0.98) const UI_RICE_PAPER := Color(0.48, 0.46, 0.39, 0.98)
const UI_RICE_PAPER_LIGHT := Color(0.62, 0.59, 0.50, 0.99) const UI_RICE_PAPER_LIGHT := Color(0.62, 0.59, 0.50, 0.99)
const UI_RICE_PAPER_DARK := Color(0.18, 0.17, 0.14, 0.98) const UI_RICE_PAPER_DARK := Color(0.18, 0.17, 0.14, 0.98)
const UI_READABLE_PAPER := Color(0.66, 0.63, 0.53, 0.998) const UI_READABLE_PAPER := Color(0.64, 0.65, 0.60, 0.999)
const UI_READABLE_CARD := Color(0.58, 0.55, 0.47, 0.998) const UI_READABLE_CARD := Color(0.74, 0.74, 0.68, 0.999)
const UI_HUD_READABLE := Color(0.060, 0.056, 0.048, 0.982) const UI_HUD_READABLE := Color(0.060, 0.056, 0.048, 0.982)
const UI_TEXT_PAPER_SURFACE := Color(0.72, 0.69, 0.58, 0.998) const UI_TEXT_PAPER_SURFACE := Color(0.78, 0.77, 0.69, 0.999)
const UI_TEXT_DARK_SURFACE := Color(0.030, 0.028, 0.024, 0.996) const UI_TEXT_DARK_SURFACE := Color(0.030, 0.028, 0.024, 0.996)
const UI_TEXT_NOTICE_SURFACE := Color(0.68, 0.65, 0.55, 0.998) const UI_TEXT_NOTICE_SURFACE := Color(0.74, 0.73, 0.66, 0.999)
const UI_AGED_INK := Color(0.055, 0.060, 0.055, 1.0) const UI_AGED_INK := Color(0.020, 0.021, 0.018, 1.0)
const UI_DARK_LACQUER := Color(0.045, 0.038, 0.034, 0.988) const UI_DARK_LACQUER := Color(0.045, 0.038, 0.034, 0.988)
const UI_LACQUER_EDGE := Color(0.025, 0.023, 0.020, 1.0) const UI_LACQUER_EDGE := Color(0.025, 0.023, 0.020, 1.0)
const UI_CINNABAR := Color(0.52, 0.045, 0.025, 1.0) const UI_CINNABAR := Color(0.52, 0.045, 0.025, 1.0)
@@ -876,7 +876,9 @@ func _panel_variant_prefers_flat_text_surface(variant: String) -> bool:
"notice_edict", "notice_edict",
"target_hint", "target_hint",
"cinematic_caption", "cinematic_caption",
"story_caption" "story_caption",
"cinematic_text_plate",
"briefing_text_plate"
] ]
@@ -1063,6 +1065,20 @@ func _apply_panel_style(panel: PanelContainer, variant: String) -> void:
radius = 10 radius = 10
margin = 14 margin = 14
shadow_size = 22 shadow_size = 22
"cinematic_text_plate":
fill = Color(0.006, 0.006, 0.005, 0.992)
border = Color(0.46, 0.38, 0.24, 0.90)
border_width = 2
radius = 8
margin = 14
shadow_size = 10
"briefing_text_plate":
fill = Color(0.80, 0.79, 0.71, 0.999)
border = Color(0.19, 0.16, 0.11, 1.0)
border_width = 2
radius = 8
margin = 14
shadow_size = 5
"story_caption": "story_caption":
fill = Color(0.030, 0.026, 0.020, 0.988) fill = Color(0.030, 0.026, 0.020, 0.988)
border = UI_TARNISHED_BRONZE border = UI_TARNISHED_BRONZE
@@ -1323,7 +1339,7 @@ func _color_luminance(color: Color) -> float:
func _text_outline_color_for(font_color: Color) -> Color: func _text_outline_color_for(font_color: Color) -> Color:
if _color_luminance(font_color) >= 0.42: if _color_luminance(font_color) >= 0.42:
return UI_TEXT_DARK_OUTLINE return UI_TEXT_DARK_OUTLINE
return UI_TEXT_LIGHT_OUTLINE return Color(UI_TEXT_LIGHT_OUTLINE.r, UI_TEXT_LIGHT_OUTLINE.g, UI_TEXT_LIGHT_OUTLINE.b, 0.42)
func _apply_text_legibility(control: Control, font_color: Color, font_size: int = 0) -> void: func _apply_text_legibility(control: Control, font_color: Color, font_size: int = 0) -> void:
@@ -1332,14 +1348,17 @@ func _apply_text_legibility(control: Control, font_color: Color, font_size: int
var resolved_size := font_size var resolved_size := font_size
if resolved_size <= 0: if resolved_size <= 0:
resolved_size = control.get_theme_font_size("font_size") resolved_size = control.get_theme_font_size("font_size")
var outline_size := 3 if resolved_size >= 16 else (2 if resolved_size >= 12 else 1) var outline_size := 4 if resolved_size >= 18 else (3 if resolved_size >= 14 else 2)
control.add_theme_color_override("font_outline_color", _text_outline_color_for(font_color)) control.add_theme_color_override("font_outline_color", _text_outline_color_for(font_color))
control.add_theme_constant_override("outline_size", outline_size) control.add_theme_constant_override("outline_size", outline_size)
control.add_theme_color_override("font_shadow_color", UI_TEXT_SHADOW) var shadow_color := UI_TEXT_SHADOW
if _color_luminance(font_color) < 0.24:
shadow_color = Color(0.0, 0.0, 0.0, 0.38)
control.add_theme_color_override("font_shadow_color", shadow_color)
control.add_theme_constant_override("shadow_offset_x", 1) control.add_theme_constant_override("shadow_offset_x", 1)
control.add_theme_constant_override("shadow_offset_y", 1) control.add_theme_constant_override("shadow_offset_y", 1)
if control is Label: if control is Label:
control.add_theme_constant_override("line_spacing", 4 if resolved_size >= 16 else 3) control.add_theme_constant_override("line_spacing", 6 if resolved_size >= 17 else 4)
func _apply_strong_text_legibility(control: Control, font_color: Color, font_size: int = 0) -> void: func _apply_strong_text_legibility(control: Control, font_color: Color, font_size: int = 0) -> void:
@@ -2342,6 +2361,7 @@ func _icon_line(image: Image, from_point: Vector2i, to_point: Vector2i, color: C
func _apply_label_style(label: Label, font_color: Color, font_size: int = 0) -> void: func _apply_label_style(label: Label, font_color: Color, font_size: int = 0) -> void:
if label == null: if label == null:
return return
label.clip_text = false
label.add_theme_color_override("font_color", font_color) label.add_theme_color_override("font_color", font_color)
if font_size > 0: if font_size > 0:
label.add_theme_font_size_override("font_size", font_size) label.add_theme_font_size_override("font_size", font_size)
@@ -2381,6 +2401,7 @@ func _apply_opening_caption_text_style(label: Label, font_color: Color, font_siz
label.visible = true label.visible = true
label.modulate = Color(1.0, 1.0, 1.0, 1.0) label.modulate = Color(1.0, 1.0, 1.0, 1.0)
label.self_modulate = Color(1.0, 1.0, 1.0, 1.0) label.self_modulate = Color(1.0, 1.0, 1.0, 1.0)
label.clip_text = false
label.z_as_relative = false label.z_as_relative = false
label.z_index = 92 label.z_index = 92
label.add_theme_color_override("font_color", font_color) label.add_theme_color_override("font_color", font_color)
@@ -3181,7 +3202,7 @@ func _make_screen_backdrop() -> ColorRect:
var backdrop := ColorRect.new() var backdrop := ColorRect.new()
backdrop.visible = false backdrop.visible = false
backdrop.set_anchors_preset(Control.PRESET_FULL_RECT) backdrop.set_anchors_preset(Control.PRESET_FULL_RECT)
backdrop.color = Color(0.018, 0.009, 0.004, 0.74) backdrop.color = Color(0.018, 0.009, 0.004, 0.84)
backdrop.mouse_filter = Control.MOUSE_FILTER_IGNORE backdrop.mouse_filter = Control.MOUSE_FILTER_IGNORE
return backdrop return backdrop
@@ -3536,8 +3557,8 @@ func _create_hud() -> void:
objective_notice_panel = PanelContainer.new() objective_notice_panel = PanelContainer.new()
objective_notice_panel.visible = false objective_notice_panel.visible = false
objective_notice_panel.position = Vector2(338, 88) objective_notice_panel.position = Vector2(338, 88)
objective_notice_panel.size = Vector2(604, 190) objective_notice_panel.size = Vector2(604, 206)
objective_notice_panel.custom_minimum_size = Vector2(604, 190) objective_notice_panel.custom_minimum_size = Vector2(604, 206)
objective_notice_panel.mouse_filter = Control.MOUSE_FILTER_PASS objective_notice_panel.mouse_filter = Control.MOUSE_FILTER_PASS
_apply_panel_style(objective_notice_panel, "notice_edict") _apply_panel_style(objective_notice_panel, "notice_edict")
root.add_child(objective_notice_panel) root.add_child(objective_notice_panel)
@@ -3560,7 +3581,7 @@ func _create_hud() -> void:
objective_notice_label.horizontal_alignment = HORIZONTAL_ALIGNMENT_CENTER objective_notice_label.horizontal_alignment = HORIZONTAL_ALIGNMENT_CENTER
objective_notice_label.vertical_alignment = VERTICAL_ALIGNMENT_CENTER objective_notice_label.vertical_alignment = VERTICAL_ALIGNMENT_CENTER
objective_notice_label.autowrap_mode = TextServer.AUTOWRAP_WORD_SMART objective_notice_label.autowrap_mode = TextServer.AUTOWRAP_WORD_SMART
objective_notice_label.custom_minimum_size = Vector2(548, 72) objective_notice_label.custom_minimum_size = Vector2(548, 90)
_apply_label_style(objective_notice_label, UI_AGED_INK, OBJECTIVE_NOTICE_FONT_SIZE) _apply_label_style(objective_notice_label, UI_AGED_INK, OBJECTIVE_NOTICE_FONT_SIZE)
objective_notice_column.add_child(objective_notice_label) objective_notice_column.add_child(objective_notice_label)
objective_notice_column.add_child(_make_scroll_rod(548, 3)) objective_notice_column.add_child(_make_scroll_rod(548, 3))
@@ -4156,17 +4177,17 @@ func _create_hud() -> void:
opening_caption_readability_mat.name = "OpeningCaptionTextBacking" opening_caption_readability_mat.name = "OpeningCaptionTextBacking"
opening_caption_readability_mat.color = Color(0.0, 0.0, 0.0, 0.74) opening_caption_readability_mat.color = Color(0.0, 0.0, 0.0, 0.74)
opening_caption_readability_mat.mouse_filter = Control.MOUSE_FILTER_IGNORE opening_caption_readability_mat.mouse_filter = Control.MOUSE_FILTER_IGNORE
opening_caption_readability_mat.position = Vector2(30, 488) opening_caption_readability_mat.position = Vector2(24, 484)
opening_caption_readability_mat.size = Vector2(1220, 198) opening_caption_readability_mat.size = Vector2(1232, 206)
opening_caption_readability_mat.z_as_relative = false opening_caption_readability_mat.z_as_relative = false
opening_caption_readability_mat.z_index = 54 opening_caption_readability_mat.z_index = 54
opening_prologue_root.add_child(opening_caption_readability_mat) opening_prologue_root.add_child(opening_caption_readability_mat)
var opening_caption_panel := PanelContainer.new() var opening_caption_panel := PanelContainer.new()
opening_caption_panel.name = "OpeningCaptionScroll" opening_caption_panel.name = "OpeningCaptionScroll"
opening_caption_panel.position = Vector2(42, 500) opening_caption_panel.position = Vector2(32, 492)
opening_caption_panel.size = Vector2(1196, 174) opening_caption_panel.size = Vector2(1216, 182)
opening_caption_panel.custom_minimum_size = Vector2(1196, 174) opening_caption_panel.custom_minimum_size = Vector2(1216, 182)
opening_caption_panel.modulate = Color(1.0, 1.0, 1.0, 1.0) opening_caption_panel.modulate = Color(1.0, 1.0, 1.0, 1.0)
opening_caption_panel.z_as_relative = false opening_caption_panel.z_as_relative = false
opening_caption_panel.z_index = 68 opening_caption_panel.z_index = 68
@@ -4174,20 +4195,20 @@ func _create_hud() -> void:
opening_prologue_root.add_child(opening_caption_panel) opening_prologue_root.add_child(opening_caption_panel)
var opening_caption_row := HBoxContainer.new() var opening_caption_row := HBoxContainer.new()
opening_caption_row.custom_minimum_size = Vector2(1152, 126) opening_caption_row.custom_minimum_size = Vector2(1172, 134)
opening_caption_row.size_flags_horizontal = Control.SIZE_EXPAND_FILL opening_caption_row.size_flags_horizontal = Control.SIZE_EXPAND_FILL
opening_caption_row.size_flags_vertical = Control.SIZE_EXPAND_FILL opening_caption_row.size_flags_vertical = Control.SIZE_EXPAND_FILL
opening_caption_row.add_theme_constant_override("separation", 14) opening_caption_row.add_theme_constant_override("separation", 14)
opening_caption_panel.add_child(opening_caption_row) opening_caption_panel.add_child(opening_caption_row)
var opening_title_column := VBoxContainer.new() var opening_title_column := VBoxContainer.new()
opening_title_column.custom_minimum_size = Vector2(220, 126) opening_title_column.custom_minimum_size = Vector2(210, 134)
opening_title_column.add_theme_constant_override("separation", 5) opening_title_column.add_theme_constant_override("separation", 5)
opening_caption_row.add_child(opening_title_column) opening_caption_row.add_child(opening_title_column)
opening_title_column.add_child(_make_seal_ribbon(220, 10)) opening_title_column.add_child(_make_seal_ribbon(210, 10))
opening_prologue_title_label = Label.new() opening_prologue_title_label = Label.new()
opening_prologue_title_label.custom_minimum_size = Vector2(220, 42) opening_prologue_title_label.custom_minimum_size = Vector2(210, 44)
opening_prologue_title_label.horizontal_alignment = HORIZONTAL_ALIGNMENT_CENTER opening_prologue_title_label.horizontal_alignment = HORIZONTAL_ALIGNMENT_CENTER
opening_prologue_title_label.vertical_alignment = VERTICAL_ALIGNMENT_CENTER opening_prologue_title_label.vertical_alignment = VERTICAL_ALIGNMENT_CENTER
opening_prologue_title_label.autowrap_mode = TextServer.AUTOWRAP_WORD_SMART opening_prologue_title_label.autowrap_mode = TextServer.AUTOWRAP_WORD_SMART
@@ -4195,25 +4216,32 @@ func _create_hud() -> void:
opening_title_column.add_child(opening_prologue_title_label) opening_title_column.add_child(opening_prologue_title_label)
opening_prologue_step_label = Label.new() opening_prologue_step_label = Label.new()
opening_prologue_step_label.custom_minimum_size = Vector2(220, 24) opening_prologue_step_label.custom_minimum_size = Vector2(210, 26)
opening_prologue_step_label.horizontal_alignment = HORIZONTAL_ALIGNMENT_CENTER opening_prologue_step_label.horizontal_alignment = HORIZONTAL_ALIGNMENT_CENTER
opening_prologue_step_label.vertical_alignment = VERTICAL_ALIGNMENT_CENTER opening_prologue_step_label.vertical_alignment = VERTICAL_ALIGNMENT_CENTER
opening_prologue_step_label.autowrap_mode = TextServer.AUTOWRAP_WORD_SMART opening_prologue_step_label.autowrap_mode = TextServer.AUTOWRAP_WORD_SMART
_apply_opening_caption_text_style(opening_prologue_step_label, UI_OPENING_CAPTION_MUTED, 16) _apply_opening_caption_text_style(opening_prologue_step_label, UI_OPENING_CAPTION_MUTED, 16)
opening_title_column.add_child(opening_prologue_step_label) opening_title_column.add_child(opening_prologue_step_label)
var opening_body_surface := PanelContainer.new()
opening_body_surface.name = "OpeningStoryBodyTextSurface"
opening_body_surface.custom_minimum_size = Vector2(756, 134)
opening_body_surface.size_flags_horizontal = Control.SIZE_EXPAND_FILL
_apply_panel_style(opening_body_surface, "cinematic_text_plate")
opening_caption_row.add_child(opening_body_surface)
opening_prologue_body_label = Label.new() opening_prologue_body_label = Label.new()
opening_prologue_body_label.custom_minimum_size = Vector2(730, 126) opening_prologue_body_label.custom_minimum_size = Vector2(730, 110)
opening_prologue_body_label.size_flags_horizontal = Control.SIZE_EXPAND_FILL opening_prologue_body_label.size_flags_horizontal = Control.SIZE_EXPAND_FILL
opening_prologue_body_label.size_flags_vertical = Control.SIZE_EXPAND_FILL opening_prologue_body_label.size_flags_vertical = Control.SIZE_EXPAND_FILL
opening_prologue_body_label.autowrap_mode = TextServer.AUTOWRAP_WORD_SMART opening_prologue_body_label.autowrap_mode = TextServer.AUTOWRAP_WORD_SMART
opening_prologue_body_label.vertical_alignment = VERTICAL_ALIGNMENT_CENTER opening_prologue_body_label.vertical_alignment = VERTICAL_ALIGNMENT_CENTER
opening_prologue_body_label.clip_text = false opening_prologue_body_label.clip_text = false
_apply_opening_caption_text_style(opening_prologue_body_label, UI_OPENING_CAPTION_BODY, 22) _apply_opening_caption_text_style(opening_prologue_body_label, UI_OPENING_CAPTION_BODY, 22)
opening_caption_row.add_child(opening_prologue_body_label) opening_body_surface.add_child(opening_prologue_body_label)
var opening_button_column := VBoxContainer.new() var opening_button_column := VBoxContainer.new()
opening_button_column.custom_minimum_size = Vector2(184, 126) opening_button_column.custom_minimum_size = Vector2(178, 134)
opening_button_column.add_theme_constant_override("separation", 9) opening_button_column.add_theme_constant_override("separation", 9)
opening_caption_row.add_child(opening_button_column) opening_caption_row.add_child(opening_button_column)
@@ -4253,13 +4281,13 @@ func _create_hud() -> void:
briefing_panel = PanelContainer.new() briefing_panel = PanelContainer.new()
briefing_panel.visible = false briefing_panel.visible = false
briefing_panel.position = Vector2(212, 16) briefing_panel.position = Vector2(212, 8)
briefing_panel.size = Vector2(856, 688) briefing_panel.size = Vector2(856, 704)
_apply_panel_style(briefing_panel, "briefing_sheet") _apply_panel_style(briefing_panel, "briefing_sheet")
root.add_child(briefing_panel) root.add_child(briefing_panel)
var briefing_shell := HBoxContainer.new() var briefing_shell := HBoxContainer.new()
briefing_shell.custom_minimum_size = Vector2(800, 632) briefing_shell.custom_minimum_size = Vector2(800, 660)
briefing_shell.add_theme_constant_override("separation", 0) briefing_shell.add_theme_constant_override("separation", 0)
briefing_panel.add_child(briefing_shell) briefing_panel.add_child(briefing_shell)
@@ -4336,7 +4364,7 @@ func _create_hud() -> void:
briefing_column.add_child(_make_section_caption("전장도와 군막 보고", 680)) briefing_column.add_child(_make_section_caption("전장도와 군막 보고", 680))
briefing_camp_overview_panel = PanelContainer.new() briefing_camp_overview_panel = PanelContainer.new()
briefing_camp_overview_panel.custom_minimum_size = Vector2(680, 108) briefing_camp_overview_panel.custom_minimum_size = Vector2(680, 120)
_apply_panel_style(briefing_camp_overview_panel, "briefing_card") _apply_panel_style(briefing_camp_overview_panel, "briefing_card")
briefing_column.add_child(briefing_camp_overview_panel) briefing_column.add_child(briefing_camp_overview_panel)
@@ -4345,7 +4373,7 @@ func _create_hud() -> void:
briefing_camp_overview_panel.add_child(briefing_camp_overview_shell) briefing_camp_overview_panel.add_child(briefing_camp_overview_shell)
briefing_camp_overview_row = HBoxContainer.new() briefing_camp_overview_row = HBoxContainer.new()
briefing_camp_overview_row.custom_minimum_size = Vector2(648, 92) briefing_camp_overview_row.custom_minimum_size = Vector2(648, 104)
briefing_camp_overview_row.add_theme_constant_override("separation", 10) briefing_camp_overview_row.add_theme_constant_override("separation", 10)
briefing_camp_overview_row.size_flags_horizontal = Control.SIZE_EXPAND_FILL briefing_camp_overview_row.size_flags_horizontal = Control.SIZE_EXPAND_FILL
briefing_camp_overview_shell.add_child(briefing_camp_overview_row) briefing_camp_overview_shell.add_child(briefing_camp_overview_row)
@@ -4384,29 +4412,36 @@ func _create_hud() -> void:
briefing_camp_overview_label = Label.new() briefing_camp_overview_label = Label.new()
briefing_camp_overview_label.autowrap_mode = TextServer.AUTOWRAP_WORD_SMART briefing_camp_overview_label.autowrap_mode = TextServer.AUTOWRAP_WORD_SMART
briefing_camp_overview_label.custom_minimum_size = Vector2(286, 86) briefing_camp_overview_label.custom_minimum_size = Vector2(286, 104)
briefing_camp_overview_label.size_flags_horizontal = Control.SIZE_EXPAND_FILL briefing_camp_overview_label.size_flags_horizontal = Control.SIZE_EXPAND_FILL
_apply_label_style(briefing_camp_overview_label, UI_AGED_INK, BRIEFING_OVERVIEW_FONT_SIZE) _apply_label_style(briefing_camp_overview_label, UI_AGED_INK, BRIEFING_OVERVIEW_FONT_SIZE)
briefing_camp_overview_row.add_child(briefing_camp_overview_label) briefing_camp_overview_row.add_child(briefing_camp_overview_label)
briefing_tactical_marker_list = VBoxContainer.new() briefing_tactical_marker_list = VBoxContainer.new()
briefing_tactical_marker_list.name = "BriefingTacticalMarkerList" briefing_tactical_marker_list.name = "BriefingTacticalMarkerList"
briefing_tactical_marker_list.custom_minimum_size = Vector2(BRIEFING_TACTICAL_MARKER_CHIP_SIZE.x, 86) briefing_tactical_marker_list.custom_minimum_size = Vector2(BRIEFING_TACTICAL_MARKER_CHIP_SIZE.x, 104)
briefing_tactical_marker_list.size_flags_vertical = Control.SIZE_SHRINK_CENTER briefing_tactical_marker_list.size_flags_vertical = Control.SIZE_SHRINK_CENTER
briefing_tactical_marker_list.add_theme_constant_override("separation", 4) briefing_tactical_marker_list.add_theme_constant_override("separation", 4)
briefing_camp_overview_row.add_child(briefing_tactical_marker_list) briefing_camp_overview_row.add_child(briefing_tactical_marker_list)
var briefing_scroll := ScrollContainer.new() var briefing_scroll := ScrollContainer.new()
briefing_scroll.custom_minimum_size = Vector2(680, 96) briefing_scroll.custom_minimum_size = Vector2(680, 112)
briefing_column.add_child(briefing_scroll) briefing_column.add_child(briefing_scroll)
var briefing_body_surface := PanelContainer.new()
briefing_body_surface.name = "BriefingBodyTextSurface"
briefing_body_surface.custom_minimum_size = Vector2(680, 112)
briefing_body_surface.size_flags_horizontal = Control.SIZE_EXPAND_FILL
_apply_panel_style(briefing_body_surface, "briefing_text_plate")
briefing_scroll.add_child(briefing_body_surface)
briefing_label = Label.new() briefing_label = Label.new()
briefing_label.autowrap_mode = TextServer.AUTOWRAP_WORD_SMART briefing_label.autowrap_mode = TextServer.AUTOWRAP_WORD_SMART
briefing_label.custom_minimum_size = Vector2(656, 92) briefing_label.custom_minimum_size = Vector2(648, 88)
briefing_label.size_flags_horizontal = Control.SIZE_EXPAND_FILL briefing_label.size_flags_horizontal = Control.SIZE_EXPAND_FILL
briefing_label.vertical_alignment = VERTICAL_ALIGNMENT_TOP briefing_label.vertical_alignment = VERTICAL_ALIGNMENT_TOP
_apply_label_style(briefing_label, UI_AGED_INK, BRIEFING_BODY_FONT_SIZE) _apply_label_style(briefing_label, UI_AGED_INK, BRIEFING_BODY_FONT_SIZE)
briefing_scroll.add_child(briefing_label) briefing_body_surface.add_child(briefing_label)
var prep_button_row := HBoxContainer.new() var prep_button_row := HBoxContainer.new()
prep_button_row.add_theme_constant_override("separation", 8) prep_button_row.add_theme_constant_override("separation", 8)
@@ -4695,7 +4730,7 @@ func _create_hud() -> void:
dialogue_progress_label.custom_minimum_size = Vector2(520, 32) dialogue_progress_label.custom_minimum_size = Vector2(520, 32)
dialogue_progress_label.size_flags_horizontal = Control.SIZE_EXPAND_FILL dialogue_progress_label.size_flags_horizontal = Control.SIZE_EXPAND_FILL
dialogue_progress_label.horizontal_alignment = HORIZONTAL_ALIGNMENT_RIGHT dialogue_progress_label.horizontal_alignment = HORIZONTAL_ALIGNMENT_RIGHT
_apply_label_style(dialogue_progress_label, UI_OLD_BRONZE) _apply_label_style(dialogue_progress_label, UI_PARCHMENT_TEXT, 15)
dialogue_control_row.add_child(dialogue_progress_label) dialogue_control_row.add_child(dialogue_progress_label)
dialogue_previous_button = Button.new() dialogue_previous_button = Button.new()

View File

@@ -725,7 +725,9 @@ func _check_text_fit_contract(scene, failures: Array[String]) -> void:
if fitted_dialogue_height > dialogue_area.y: if fitted_dialogue_height > dialogue_area.y:
failures.append("fitted long dialogue should stay within the dialogue text area") failures.append("fitted long dialogue should stay within the dialogue text area")
var objective_area := Vector2(500.0, 104.0) var objective_area: Vector2 = scene.briefing_objective_label.custom_minimum_size
if objective_area.x <= 0.0 or objective_area.y <= 0.0:
objective_area = Vector2(648.0, 120.0)
var long_objective := "승리: 서영의 후군을 꺾었다. 동쪽 길목을 장악하고 뒤따르는 봉쇄병까지 정리하라.\n패배: 조조가 퇴각하거나 제17턴이 시작되면 패한다.\n보상: 군자금 700냥, 콩, 술, 철검" var long_objective := "승리: 서영의 후군을 꺾었다. 동쪽 길목을 장악하고 뒤따르는 봉쇄병까지 정리하라.\n패배: 조조가 퇴각하거나 제17턴이 시작되면 패한다.\n보상: 군자금 700냥, 콩, 술, 철검"
var fitted_objective_size := int(scene._fit_font_size_for_text(long_objective, scene.BRIEFING_OBJECTIVE_FONT_SIZE, scene.BRIEFING_OBJECTIVE_MIN_FONT_SIZE, objective_area)) var fitted_objective_size := int(scene._fit_font_size_for_text(long_objective, scene.BRIEFING_OBJECTIVE_FONT_SIZE, scene.BRIEFING_OBJECTIVE_MIN_FONT_SIZE, objective_area))
if fitted_objective_size < scene.BRIEFING_OBJECTIVE_MIN_FONT_SIZE or fitted_objective_size > scene.BRIEFING_OBJECTIVE_FONT_SIZE: if fitted_objective_size < scene.BRIEFING_OBJECTIVE_MIN_FONT_SIZE or fitted_objective_size > scene.BRIEFING_OBJECTIVE_FONT_SIZE:

View File

@@ -3705,18 +3705,19 @@ func _check_ancient_ui_theme(failures: Array[String]) -> void:
for clutter in ["목표|", "주의|", "현황|", "경고|"]: for clutter in ["목표|", "주의|", "현황|", "경고|"]:
if mission_text.contains(clutter): if mission_text.contains(clutter):
failures.append("mission panel should avoid old verbose marker `%s`: %s" % [clutter, mission_text]) failures.append("mission panel should avoid old verbose marker `%s`: %s" % [clutter, mission_text])
_check_panel_style_fill(failures, scene.briefing_panel, "briefing panel", Color(0.66, 0.63, 0.53, 0.998)) _check_panel_style_fill(failures, scene.briefing_panel, "briefing panel", Color(0.64, 0.65, 0.60, 0.999))
_check_panel_style_frame(failures, scene.briefing_panel, "briefing panel", Color(0.14, 0.11, 0.075, 1.0), 5) _check_panel_style_frame(failures, scene.briefing_panel, "briefing panel", Color(0.14, 0.11, 0.075, 1.0), 5)
_check_panel_style_fill(failures, scene.briefing_objective_panel, "briefing objective readable panel", Color(0.58, 0.55, 0.47, 0.998)) _check_panel_style_fill(failures, scene.briefing_objective_panel, "briefing objective readable panel", Color(0.74, 0.74, 0.68, 0.999))
_check_panel_style_frame(failures, scene.briefing_objective_panel, "briefing objective readable panel", Color(0.16, 0.13, 0.090, 1.0), 3) _check_panel_style_frame(failures, scene.briefing_objective_panel, "briefing objective readable panel", Color(0.16, 0.13, 0.090, 1.0), 3)
_check_panel_style_fill(failures, scene.briefing_camp_overview_panel, "briefing readable map panel", Color(0.58, 0.55, 0.47, 0.998)) _check_panel_style_fill(failures, scene.briefing_camp_overview_panel, "briefing readable map panel", Color(0.74, 0.74, 0.68, 0.999))
_check_panel_style_frame(failures, scene.briefing_camp_overview_panel, "briefing readable map panel", Color(0.16, 0.13, 0.090, 1.0), 3) _check_panel_style_frame(failures, scene.briefing_camp_overview_panel, "briefing readable map panel", Color(0.16, 0.13, 0.090, 1.0), 3)
_check_panel_uses_flat_text_surface(failures, _find_descendant_by_name(scene.briefing_panel, "BriefingBodyTextSurface") as PanelContainer, "briefing body text plate")
_check_panel_style_fill(failures, scene.dialogue_panel, "dialogue panel", Color(0.030, 0.028, 0.024, 0.996)) _check_panel_style_fill(failures, scene.dialogue_panel, "dialogue panel", Color(0.030, 0.028, 0.024, 0.996))
_check_panel_style_frame(failures, scene.dialogue_panel, "dialogue panel", Color(0.28, 0.23, 0.16, 1.0), 8) _check_panel_style_frame(failures, scene.dialogue_panel, "dialogue panel", Color(0.28, 0.23, 0.16, 1.0), 8)
_check_panel_style_fill(failures, scene.auto_end_turn_prompt_panel, "auto end turn prompt panel", Color(0.030, 0.028, 0.024, 0.996)) _check_panel_style_fill(failures, scene.auto_end_turn_prompt_panel, "auto end turn prompt panel", Color(0.030, 0.028, 0.024, 0.996))
_check_panel_style_fill(failures, scene.dialogue_portrait_panel, "dialogue portrait panel", Color(0.025, 0.023, 0.020, 1.0)) _check_panel_style_fill(failures, scene.dialogue_portrait_panel, "dialogue portrait panel", Color(0.025, 0.023, 0.020, 1.0))
_check_panel_style_fill(failures, scene.dialogue_speaker_panel, "dialogue speaker seal panel", Color(0.26, 0.035, 0.030, 0.995)) _check_panel_style_fill(failures, scene.dialogue_speaker_panel, "dialogue speaker seal panel", Color(0.26, 0.035, 0.030, 0.995))
_check_panel_style_fill(failures, scene.dialogue_text_panel, "dialogue text scroll panel", Color(0.72, 0.69, 0.58, 0.998)) _check_panel_style_fill(failures, scene.dialogue_text_panel, "dialogue text scroll panel", Color(0.78, 0.77, 0.69, 0.999))
_check_panel_uses_flat_text_surface(failures, scene.dialogue_panel, "dialogue flat text frame") _check_panel_uses_flat_text_surface(failures, scene.dialogue_panel, "dialogue flat text frame")
_check_panel_uses_flat_text_surface(failures, scene.dialogue_text_panel, "dialogue flat text scroll") _check_panel_uses_flat_text_surface(failures, scene.dialogue_text_panel, "dialogue flat text scroll")
_check_panel_uses_flat_text_surface(failures, scene.auto_end_turn_prompt_panel, "auto end turn flat text frame") _check_panel_uses_flat_text_surface(failures, scene.auto_end_turn_prompt_panel, "auto end turn flat text frame")
@@ -4048,6 +4049,8 @@ func _check_opening_prologue_presentation(failures: Array[String]) -> void:
failures.append("opening body should be wide enough for Korean opening text: %s" % str(scene.opening_prologue_body_label.custom_minimum_size)) failures.append("opening body should be wide enough for Korean opening text: %s" % str(scene.opening_prologue_body_label.custom_minimum_size))
if scene.opening_prologue_body_label.get_theme_constant("outline_size") < 3: if scene.opening_prologue_body_label.get_theme_constant("outline_size") < 3:
failures.append("opening body should have a strong outline over generated art") failures.append("opening body should have a strong outline over generated art")
var opening_body_surface := _find_descendant_by_name(scene.opening_prologue_root, "OpeningStoryBodyTextSurface") as PanelContainer
_check_panel_uses_flat_text_surface(failures, opening_body_surface, "opening story body text plate")
if scene.opening_prologue_next_button == null: if scene.opening_prologue_next_button == null:
failures.append("opening prologue should expose a next button") failures.append("opening prologue should expose a next button")
else: else: