Deepen ancient Nanpi briefing flow

This commit is contained in:
2026-06-19 02:22:01 +09:00
parent 1911038d70
commit bda8d02c3c
5 changed files with 388 additions and 33 deletions

View File

@@ -53,10 +53,10 @@ const UNIT_ARROW_ATTACK_DURATION := 0.36
const UNIT_COMMAND_ATTACK_DURATION := 0.38
const UNIT_HEAVY_ATTACK_DURATION := 0.34
const UNIT_TACTIC_CAST_DURATION := 0.42
const DIALOGUE_PANEL_POSITION := Vector2(96, 448)
const DIALOGUE_PANEL_SIZE := Vector2(1040, 210)
const DIALOGUE_PORTRAIT_SIZE := Vector2(164, 186)
const DIALOGUE_COLUMN_SIZE := Vector2(820, 186)
const DIALOGUE_PANEL_POSITION := Vector2(96, 424)
const DIALOGUE_PANEL_SIZE := Vector2(1040, 236)
const DIALOGUE_PORTRAIT_SIZE := Vector2(164, 208)
const DIALOGUE_COLUMN_SIZE := Vector2(820, 208)
const DIALOGUE_TEXT_SIZE := Vector2(800, 104)
const BRIEFING_CAMP_THUMBNAIL_SIZE := Vector2(138, 72)
const CAMP_TALK_PORTRAIT_SIZE := Vector2(58, 58)
@@ -78,6 +78,8 @@ const UI_LACQUER_EDGE := Color(0.055, 0.025, 0.016, 1.0)
const UI_CINNABAR := Color(0.52, 0.045, 0.025, 1.0)
const UI_CINNABAR_DARK := Color(0.32, 0.025, 0.016, 1.0)
const UI_OLD_BRONZE := Color(0.78, 0.58, 0.27, 1.0)
const UI_BAMBOO := Color(0.43, 0.27, 0.10, 1.0)
const UI_BAMBOO_DARK := Color(0.20, 0.11, 0.045, 1.0)
const UI_MUTED_JADE := Color(0.16, 0.30, 0.23, 1.0)
const UI_PARCHMENT_TEXT := Color(0.95, 0.82, 0.55, 1.0)
const UI_DISABLED_TEXT := Color(0.48, 0.40, 0.29, 1.0)
@@ -316,17 +318,17 @@ func _apply_panel_style(panel: PanelContainer, variant: String) -> void:
var shadow_size := 6
match variant:
"paper":
fill = UI_RICE_PAPER
border = UI_RICE_PAPER_DARK
border_width = 3
margin = 14
shadow_size = 8
"edict":
fill = UI_RICE_PAPER_LIGHT
fill = Color(0.58, 0.47, 0.29, 0.985)
border = UI_AGED_INK
border_width = 4
margin = 16
shadow_size = 10
"edict":
fill = Color(0.73, 0.60, 0.38, 0.99)
border = UI_CINNABAR_DARK
border_width = 3
margin = 10
shadow_size = 4
margin = 12
shadow_size = 5
"seal":
fill = UI_CINNABAR
border = UI_OLD_BRONZE
@@ -343,15 +345,15 @@ func _apply_panel_style(panel: PanelContainer, variant: String) -> void:
border_width = 3
margin = 3
"dialogue":
fill = UI_DARK_LACQUER
fill = Color(0.075, 0.028, 0.017, 0.99)
border = UI_OLD_BRONZE
border_width = 3
margin = 12
shadow_size = 10
border_width = 4
margin = 14
shadow_size = 12
"speech_scroll":
fill = UI_RICE_PAPER_LIGHT
border = UI_RICE_PAPER_DARK
border_width = 2
fill = Color(0.70, 0.58, 0.36, 0.99)
border = UI_AGED_INK
border_width = 3
margin = 12
shadow_size = 2
"notice":
@@ -360,8 +362,8 @@ func _apply_panel_style(panel: PanelContainer, variant: String) -> void:
border_width = 2
margin = 8
"map":
fill = Color(0.20, 0.12, 0.065, 1.0)
border = UI_OLD_BRONZE
fill = Color(0.12, 0.16, 0.11, 1.0)
border = UI_BAMBOO
border_width = 3
margin = 3
"compact":
@@ -414,6 +416,31 @@ func _make_separator(width: float = 0.0, height: float = 2.0) -> ColorRect:
return separator
func _make_bamboo_divider(width: float = 0.0, height: float = 4.0) -> HBoxContainer:
var row := HBoxContainer.new()
row.custom_minimum_size = Vector2(width, height)
row.size_flags_horizontal = Control.SIZE_EXPAND_FILL
row.add_theme_constant_override("separation", 2)
for index in range(3):
var strip := ColorRect.new()
strip.mouse_filter = Control.MOUSE_FILTER_IGNORE
strip.custom_minimum_size = Vector2(8 if index != 1 else width, height)
strip.size_flags_horizontal = Control.SIZE_EXPAND_FILL if index == 1 else Control.SIZE_SHRINK_CENTER
strip.color = UI_BAMBOO if index == 1 else UI_BAMBOO_DARK
row.add_child(strip)
return row
func _make_section_caption(text: String, width: float = 0.0) -> Label:
var label := Label.new()
label.text = text
label.custom_minimum_size = Vector2(width, 20)
label.horizontal_alignment = HORIZONTAL_ALIGNMENT_CENTER
label.vertical_alignment = VERTICAL_ALIGNMENT_CENTER
_apply_label_style(label, UI_AGED_INK, 13)
return label
func _make_ornament_bar(width: float = 4.0, height: float = 0.0) -> ColorRect:
var bar := ColorRect.new()
bar.color = UI_CINNABAR
@@ -819,7 +846,8 @@ func _create_hud() -> void:
_apply_label_style(briefing_location_label, UI_MUTED_JADE, 14)
briefing_column.add_child(briefing_location_label)
briefing_column.add_child(_make_separator(680, 2))
briefing_column.add_child(_make_bamboo_divider(680, 4))
briefing_column.add_child(_make_section_caption("Bronze War Edict", 680))
briefing_objective_panel = PanelContainer.new()
briefing_objective_panel.custom_minimum_size = Vector2(680, 92)
@@ -839,6 +867,8 @@ func _create_hud() -> void:
_apply_label_style(briefing_objective_label, UI_AGED_INK, 15)
briefing_objective_row.add_child(briefing_objective_label)
briefing_column.add_child(_make_section_caption("Bamboo Map and Camp Ledger", 680))
briefing_camp_overview_row = HBoxContainer.new()
briefing_camp_overview_row.custom_minimum_size = Vector2(680, 84)
briefing_camp_overview_row.add_theme_constant_override("separation", 10)
@@ -857,6 +887,7 @@ func _create_hud() -> void:
briefing_camp_overview_texture.set_anchors_preset(Control.PRESET_FULL_RECT)
briefing_camp_overview_texture.expand_mode = TextureRect.EXPAND_IGNORE_SIZE
briefing_camp_overview_texture.stretch_mode = TextureRect.STRETCH_KEEP_ASPECT_CENTERED
briefing_camp_overview_texture.modulate = Color(0.92, 0.78, 0.54, 0.94)
camp_thumbnail_stack.add_child(briefing_camp_overview_texture)
briefing_camp_overview_fallback_label = Label.new()
@@ -874,7 +905,7 @@ func _create_hud() -> void:
_apply_label_style(briefing_camp_overview_label, UI_AGED_INK, 14)
briefing_camp_overview_row.add_child(briefing_camp_overview_label)
briefing_column.add_child(_make_separator(680, 1))
briefing_column.add_child(_make_bamboo_divider(680, 3))
var briefing_scroll := ScrollContainer.new()
briefing_scroll.custom_minimum_size = Vector2(680, 66)
@@ -1130,6 +1161,8 @@ func _create_hud() -> void:
dialogue_column.add_theme_constant_override("separation", 8)
dialogue_row.add_child(dialogue_column)
dialogue_column.add_child(_make_bamboo_divider(DIALOGUE_TEXT_SIZE.x, 3))
dialogue_speaker_panel = PanelContainer.new()
dialogue_speaker_panel.custom_minimum_size = Vector2(DIALOGUE_TEXT_SIZE.x, 32)
_apply_panel_style(dialogue_speaker_panel, "speaker_seal")
@@ -1160,6 +1193,8 @@ func _create_hud() -> void:
_apply_label_style(dialogue_text_label, UI_AGED_INK, 17)
dialogue_text_row.add_child(dialogue_text_label)
dialogue_column.add_child(_make_bamboo_divider(DIALOGUE_TEXT_SIZE.x, 3))
var dialogue_control_row := HBoxContainer.new()
dialogue_control_row.add_theme_constant_override("separation", 8)
dialogue_column.add_child(dialogue_control_row)