Add in-game settings panel

This commit is contained in:
2026-06-19 23:43:44 +09:00
parent 46f8b10d53
commit 0e52fdd68f
4 changed files with 271 additions and 3 deletions

View File

@@ -130,6 +130,25 @@ func _check_title_menu_start_load_and_settings(failures: Array[String]) -> void:
failures.append("loading a saved game should skip the new-campaign opening prologue")
if scene.briefing_panel == null or not scene.briefing_panel.visible:
failures.append("loading a saved game should enter the current campaign briefing")
if scene.top_settings_button == null:
failures.append("top toolbar should expose an in-game Settings icon")
scene._on_settings_pressed()
if scene.settings_panel == null or not scene.settings_panel.visible:
failures.append("top Settings icon should open the in-game settings panel")
if scene.settings_bgm_toggle == null or scene.settings_sfx_toggle == null or scene.settings_edge_scroll_toggle == null:
failures.append("in-game settings panel should expose BGM, SFX, and edge-scroll toggles")
if scene.settings_bgm_volume_slider == null or scene.settings_sfx_volume_slider == null:
failures.append("in-game settings panel should expose BGM and SFX volume sliders")
scene._on_settings_bgm_toggled(true)
scene._on_settings_sfx_toggled(true)
scene._on_settings_edge_scroll_toggled(true)
scene._on_settings_bgm_volume_changed(70.0)
scene._on_settings_sfx_volume_changed(60.0)
if not scene.title_bgm_enabled or not scene.title_sfx_enabled or not scene.title_edge_scroll_enabled:
failures.append("in-game settings toggles should update the shared settings state")
if scene.title_bgm_volume_percent != 70 or scene.title_sfx_volume_percent != 60:
failures.append("in-game settings sliders should update the shared volume state")
scene._hide_settings_panel()
scene._on_new_campaign_pressed()
if not scene._is_opening_prologue_visible():
failures.append("top New Campaign should also show the opening prologue")