feat(ui): add shared cosmic clash theme

This commit is contained in:
Josh Creek
2026-09-01 22:28:02 +01:00
parent 889e30a434
commit 07fd0fde44
6 changed files with 80 additions and 4 deletions
+3 -1
View File
@@ -1,6 +1,7 @@
[gd_scene load_steps=2 format=3]
[gd_scene load_steps=3 format=3]
[ext_resource type="Script" path="res://scripts/lobby.gd" id="1_lobby"]
[ext_resource type="Theme" path="res://themes/cosmic_clash_theme.tres" id="2_theme"]
[node name="Lobby" type="Control"]
layout_mode = 3
@@ -10,6 +11,7 @@ anchor_bottom = 1.0
grow_horizontal = 2
grow_vertical = 2
script = ExtResource("1_lobby")
theme = ExtResource("2_theme")
[node name="CenterContainer" type="CenterContainer" parent="."]
layout_mode = 1
+3 -1
View File
@@ -1,6 +1,7 @@
[gd_scene load_steps=2 format=3 uid="uid://bcq14356s3e2i"]
[gd_scene load_steps=3 format=3 uid="uid://bcq14356s3e2i"]
[ext_resource type="Script" path="res://scripts/main_menu.gd" id="1_menu"]
[ext_resource type="Theme" path="res://themes/cosmic_clash_theme.tres" id="2_theme"]
[node name="MainMenu" type="Control"]
layout_mode = 3
@@ -10,6 +11,7 @@ anchor_bottom = 1.0
grow_horizontal = 2
grow_vertical = 2
script = ExtResource("1_menu")
theme = ExtResource("2_theme")
[node name="CenterContainer" type="CenterContainer" parent="."]
layout_mode = 1
+3 -1
View File
@@ -1,6 +1,7 @@
[gd_scene load_steps=2 format=3]
[gd_scene load_steps=3 format=3]
[ext_resource type="Script" path="res://scripts/matchmaking.gd" id="1_matchmaking"]
[ext_resource type="Theme" path="res://themes/cosmic_clash_theme.tres" id="2_theme"]
[node name="Matchmaking" type="Control"]
layout_mode = 3
@@ -10,6 +11,7 @@ anchor_bottom = 1.0
grow_horizontal = 2
grow_vertical = 2
script = ExtResource("1_matchmaking")
theme = ExtResource("2_theme")
[node name="CenterContainer" type="CenterContainer" parent="."]
layout_mode = 1
+3 -1
View File
@@ -1,6 +1,7 @@
[gd_scene load_steps=2 format=3]
[gd_scene load_steps=3 format=3]
[ext_resource type="Script" path="res://scripts/settings_menu.gd" id="1_settings"]
[ext_resource type="Theme" path="res://themes/cosmic_clash_theme.tres" id="2_theme"]
[node name="SettingsMenu" type="Control"]
layout_mode = 3
@@ -10,6 +11,7 @@ anchor_bottom = 1.0
grow_horizontal = 2
grow_vertical = 2
script = ExtResource("1_settings")
theme = ExtResource("2_theme")
[node name="CenterContainer" type="CenterContainer" parent="."]
layout_mode = 1
+66
View File
@@ -0,0 +1,66 @@
[gd_resource type="Theme" load_steps=5 format=3]
[sub_resource type="StyleBoxFlat" id="StyleBox_button_normal"]
bg_color = Color(0.08, 0.12, 0.2, 0.94)
border_width_left = 1
border_width_top = 1
border_width_right = 1
border_width_bottom = 1
border_color = Color(0.18, 0.42, 0.68, 0.9)
corner_radius_top_left = 6
corner_radius_top_right = 6
corner_radius_bottom_right = 6
corner_radius_bottom_left = 6
content_margin_left = 16.0
content_margin_top = 9.0
content_margin_right = 16.0
content_margin_bottom = 9.0
[sub_resource type="StyleBoxFlat" id="StyleBox_button_hover"]
bg_color = Color(0.12, 0.3, 0.48, 0.98)
border_width_left = 1
border_width_top = 1
border_width_right = 1
border_width_bottom = 1
border_color = Color(0.3, 0.72, 1, 1)
corner_radius_top_left = 6
corner_radius_top_right = 6
corner_radius_bottom_right = 6
corner_radius_bottom_left = 6
content_margin_left = 16.0
content_margin_top = 9.0
content_margin_right = 16.0
content_margin_bottom = 9.0
[sub_resource type="StyleBoxFlat" id="StyleBox_line_edit"]
bg_color = Color(0.035, 0.055, 0.1, 0.96)
border_width_left = 1
border_width_top = 1
border_width_right = 1
border_width_bottom = 1
border_color = Color(0.14, 0.3, 0.48, 1)
corner_radius_top_left = 5
corner_radius_top_right = 5
corner_radius_bottom_right = 5
corner_radius_bottom_left = 5
content_margin_left = 10.0
content_margin_top = 7.0
content_margin_right = 10.0
content_margin_bottom = 7.0
[resource]
default_font_size = 16
Button/colors/font_color = Color(0.86, 0.94, 1, 1)
Button/colors/font_hover_color = Color(1, 1, 1, 1)
Button/colors/font_pressed_color = Color(1, 1, 1, 1)
Button/colors/font_disabled_color = Color(0.45, 0.52, 0.62, 1)
Button/styles/normal = SubResource("StyleBox_button_normal")
Button/styles/hover = SubResource("StyleBox_button_hover")
Button/styles/pressed = SubResource("StyleBox_button_hover")
Button/styles/focus = SubResource("StyleBox_button_hover")
LineEdit/colors/font_color = Color(0.9, 0.96, 1, 1)
LineEdit/colors/caret_color = Color(0.3, 0.72, 1, 1)
LineEdit/styles/normal = SubResource("StyleBox_line_edit")
OptionButton/colors/font_color = Color(0.86, 0.94, 1, 1)
Label/colors/font_color = Color(0.82, 0.9, 0.98, 1)
+2
View File
@@ -1572,3 +1572,5 @@ The matchmaking UI now displays the authoritative proposal countdown from the se
The UI now provides explicit detail copy for every non-terminal allocation and connection phase (`ACCEPTED` through `LIVE`), so server progress remains understandable throughout assignment and transport startup.
Reconfiguring the client with new credentials now clears the prior session expiry, preventing an expired sessions timestamp from invalidating a fresh authentication. A re-authentication regression test covers the boundary.
Presentation progress: a shared `Game/themes/cosmic_clash_theme.tres` now gives the menu, lobby, matchmaking, and settings surfaces consistent button, input, option, and label styling. The custom-font portion of `TODO.md` remains open until a distributable font asset is selected.