Start the UI copy and button consistency pass
Full build / Import + headless tests (push) Successful in 39s
Full build / Full desktop build + optional release (push) Skipped

Add the screen/copy/button inventory and canonical terminology, standardize
inspection/wand admit-refuse hints, name the review action Return to menu, and
move radio action/hold/status labels into the string table. Headless 250/250,
Python 97/97, docs check OK.
This commit is contained in:
zwitschi committed 2026-11-02 11:10:39 +01:00
1 parent 64590fe797
commit 7c48183410
7 files changed
+103 -14

No files matched your search

+2 -2
View File
@@ -299,7 +299,7 @@ func _init() -> void:
inspect_meta.modulate = Color(0.8, 0.85, 1.0)
ivbox.add_child(inspect_meta)
var insp_hint := Label.new()
insp_hint.text = "A = allow entry D = deny entry"
insp_hint.text = Strings.lookup("ui.inspect_actions")
insp_hint.add_theme_font_size_override("font_size", 12)
insp_hint.horizontal_alignment = HORIZONTAL_ALIGNMENT_CENTER
ivbox.add_child(insp_hint)
@@ -343,7 +343,7 @@ func _init() -> void:
wand_meta.modulate = Color(0.8, 0.85, 1.0)
wvbox.add_child(wand_meta)
var wand_hint := Label.new()
wand_hint.text = "A = admit D = refuse entry"
wand_hint.text = Strings.lookup("ui.wand_actions")
wand_hint.add_theme_font_size_override("font_size", 12)
wvbox.add_child(wand_hint)
wand_center.add_child(wand_panel)
+6 -5
View File
@@ -8,6 +8,7 @@ signal submitted(report: Dictionary, emergency: bool)
signal cancelled()
const Rules := preload("res://src/core/rules.gd")
const Strings := preload("res://src/core/strings.gd")
const UiArt := preload("res://src/game/ui/art.gd")
var panel: PanelContainer
@@ -102,7 +103,7 @@ func _init() -> void:
var buttons := HBoxContainer.new()
vbox.add_child(buttons)
action_button = Button.new()
action_button.text = "Send request"
action_button.text = Strings.lookup("ui.radio_send_assist")
action_button.button_down.connect(func(): _start_hold())
action_button.button_up.connect(func(): _stop_hold(false))
action_button.pressed.connect(_on_action_pressed)
@@ -138,9 +139,9 @@ func open(controller: Object, emergency: bool, truth: Dictionary) -> void:
title.text = "EMERGENCY RADIO" if emergency else "RADIO DISPATCH"
weapons_check.button_pressed = truth.get("weapons_seen", false)
danger_option.select(truth.get("danger_level", 1))
hold_hint.text = "Hold the button for %.1fs" % HOLD_NEEDED if emergency else ""
hold_hint.text = Strings.fmt("ui.radio_hold_hint", [HOLD_NEEDED]) if emergency else ""
status_label.text = ""
action_button.text = "SEND EMERGENCY" if emergency else "Send request"
action_button.text = Strings.lookup("ui.radio_send_emergency") if emergency else Strings.lookup("ui.radio_send_assist")
_holding = false
_hold_time = 0.0
visible = true
@@ -161,14 +162,14 @@ func _stop_hold(cancelled_early: bool) -> void:
if not cancelled_early and _hold_time >= HOLD_NEEDED:
_submit()
else:
status_label.text = "Call cancelled - must hold the button."
status_label.text = Strings.lookup("ui.radio_cancelled")
func _process(delta: float) -> void:
if not visible:
return
if _holding:
_hold_time += delta
status_label.text = "Holding... %.0f%%" % (minf(1.0, _hold_time / HOLD_NEEDED) * 100.0)
status_label.text = Strings.fmt("ui.radio_holding", [minf(1.0, _hold_time / HOLD_NEEDED) * 100.0])
if _hold_time >= HOLD_NEEDED:
var was := _holding
_holding = false
+1 -1
View File
@@ -68,7 +68,7 @@ func _init() -> void:
center.add_child(timeline)
var restart := Button.new()
restart.text = "Run another shift"
restart.text = Strings.lookup("ui.review_return_menu")
restart.pressed.connect(func(): restart_requested.emit())
restart.size_flags_horizontal = Control.SIZE_SHRINK_CENTER
center.add_child(restart)