summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authortpart <tpart120@proton.me>2024-06-26 23:05:05 +0200
committertpart <tpart120@proton.me>2024-06-26 23:05:05 +0200
commit1203401b95b388b785d24e9b5bc87e4ceaac6717 (patch)
treed587562de26f744d5e9d350eaa78e090ab8866a7
parentc44b0f63627c0e0e813e3dc44c1f9dd60e3c097c (diff)
downloadhurrycurry-1203401b95b388b785d24e9b5bc87e4ceaac6717.tar
hurrycurry-1203401b95b388b785d24e9b5bc87e4ceaac6717.tar.bz2
hurrycurry-1203401b95b388b785d24e9b5bc87e4ceaac6717.tar.zst
Make menus more consistent; Use blur
-rw-r--r--client/menu/credits_menu.gd4
-rw-r--r--client/menu/credits_menu.tscn21
-rw-r--r--client/menu/main_menu.tscn16
-rw-r--r--client/menu/settings_menu.tscn8
-rw-r--r--client/menu/theme/dark_blur_material.tres9
-rw-r--r--client/menu/theme/theme.tres14
6 files changed, 43 insertions, 29 deletions
diff --git a/client/menu/credits_menu.gd b/client/menu/credits_menu.gd
index a713abc5..c7afe95a 100644
--- a/client/menu/credits_menu.gd
+++ b/client/menu/credits_menu.gd
@@ -22,12 +22,12 @@ var cc_by_3 := {
}
@onready var menu_manager: MenuManager = get_parent()
-@onready var label = $Panel/MarginContainer/VBoxContainer/RichTextLabel
+@onready var label = $MarginContainer/Panel/MarginContainer/VBoxContainer/RichTextLabel
func prepare():
contributors.shuffle()
label.text = "[center][b]"
- label.text += tr("undercooked - a game about cooking")
+ label.text += tr("undercookUSed - a game about cooking")
label.text += "[/b]\n\n"
label.text += tr("developed by")
label.text += "\n\n[b]"
diff --git a/client/menu/credits_menu.tscn b/client/menu/credits_menu.tscn
index 74d5cbc9..04797e0d 100644
--- a/client/menu/credits_menu.tscn
+++ b/client/menu/credits_menu.tscn
@@ -2,9 +2,7 @@
[ext_resource type="Theme" uid="uid://b0qmvo504e457" path="res://menu/theme/theme.tres" id="1_emk5o"]
[ext_resource type="Script" path="res://menu/credits_menu.gd" id="1_igs63"]
-
-[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_p2qmw"]
-bg_color = Color(0, 0, 0, 0.878431)
+[ext_resource type="Material" uid="uid://beea1pc5nt67r" path="res://menu/theme/dark_blur_material.tres" id="3_d30oq"]
[node name="CreditsMenu" type="Control"]
layout_mode = 3
@@ -16,16 +14,19 @@ grow_vertical = 2
theme = ExtResource("1_emk5o")
script = ExtResource("1_igs63")
-[node name="Panel" type="Panel" parent="."]
+[node name="MarginContainer" type="MarginContainer" parent="."]
layout_mode = 1
anchors_preset = 15
anchor_right = 1.0
anchor_bottom = 1.0
grow_horizontal = 2
grow_vertical = 2
-theme_override_styles/panel = SubResource("StyleBoxFlat_p2qmw")
-[node name="MarginContainer" type="MarginContainer" parent="Panel"]
+[node name="Panel" type="Panel" parent="MarginContainer"]
+material = ExtResource("3_d30oq")
+layout_mode = 2
+
+[node name="MarginContainer" type="MarginContainer" parent="MarginContainer/Panel"]
layout_mode = 1
anchors_preset = 15
anchor_right = 1.0
@@ -37,10 +38,10 @@ theme_override_constants/margin_top = 50
theme_override_constants/margin_right = 50
theme_override_constants/margin_bottom = 50
-[node name="VBoxContainer" type="VBoxContainer" parent="Panel/MarginContainer"]
+[node name="VBoxContainer" type="VBoxContainer" parent="MarginContainer/Panel/MarginContainer"]
layout_mode = 2
-[node name="RichTextLabel" type="RichTextLabel" parent="Panel/MarginContainer/VBoxContainer"]
+[node name="RichTextLabel" type="RichTextLabel" parent="MarginContainer/Panel/MarginContainer/VBoxContainer"]
layout_mode = 2
size_flags_vertical = 3
theme_override_font_sizes/normal_font_size = 22
@@ -50,8 +51,8 @@ theme_override_font_sizes/bold_italics_font_size = 22
theme_override_font_sizes/mono_font_size = 22
bbcode_enabled = true
-[node name="back" type="Button" parent="Panel/MarginContainer/VBoxContainer"]
+[node name="back" type="Button" parent="MarginContainer/Panel/MarginContainer/VBoxContainer"]
layout_mode = 2
text = "Back"
-[connection signal="pressed" from="Panel/MarginContainer/VBoxContainer/back" to="." method="_on_back_pressed"]
+[connection signal="pressed" from="MarginContainer/Panel/MarginContainer/VBoxContainer/back" to="." method="_on_back_pressed"]
diff --git a/client/menu/main_menu.tscn b/client/menu/main_menu.tscn
index 76b55a1a..361be363 100644
--- a/client/menu/main_menu.tscn
+++ b/client/menu/main_menu.tscn
@@ -1,17 +1,11 @@
-[gd_scene load_steps=8 format=3 uid="uid://dbj8508whxgwv"]
+[gd_scene load_steps=7 format=3 uid="uid://dbj8508whxgwv"]
[ext_resource type="Theme" uid="uid://b0qmvo504e457" path="res://menu/theme/theme.tres" id="1_nlcpo"]
[ext_resource type="Script" path="res://menu/main_menu.gd" id="2_qot2j"]
-[ext_resource type="Shader" path="res://menu/blur_mix.gdshader" id="4_050xu"]
+[ext_resource type="Material" uid="uid://beea1pc5nt67r" path="res://menu/theme/dark_blur_material.tres" id="3_k58q5"]
[ext_resource type="FontFile" uid="uid://bo4vh5xkpvrh1" path="res://menu/theme/font-sansita-swashed.woff2" id="4_mfs30"]
-[sub_resource type="ShaderMaterial" id="ShaderMaterial_irdo3"]
-shader = ExtResource("4_050xu")
-shader_parameter/blur_amount = 3.5
-shader_parameter/mix_amount = 0.3
-shader_parameter/color_over = null
-
-[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_cm1nk"]
+[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_ukani"]
[sub_resource type="FontVariation" id="FontVariation_htgmg"]
base_font = ExtResource("4_mfs30")
@@ -28,13 +22,13 @@ theme = ExtResource("1_nlcpo")
script = ExtResource("2_qot2j")
[node name="side" type="PanelContainer" parent="."]
-material = SubResource("ShaderMaterial_irdo3")
+material = ExtResource("3_k58q5")
layout_mode = 1
anchors_preset = 9
anchor_bottom = 1.0
offset_right = 340.0
grow_vertical = 2
-theme_override_styles/panel = SubResource("StyleBoxFlat_cm1nk")
+theme_override_styles/panel = SubResource("StyleBoxFlat_ukani")
[node name="margin" type="MarginContainer" parent="side"]
layout_mode = 2
diff --git a/client/menu/settings_menu.tscn b/client/menu/settings_menu.tscn
index 6ead9b8b..84da46f3 100644
--- a/client/menu/settings_menu.tscn
+++ b/client/menu/settings_menu.tscn
@@ -1,7 +1,8 @@
-[gd_scene load_steps=3 format=3 uid="uid://8ic77jmadadj"]
+[gd_scene load_steps=4 format=3 uid="uid://8ic77jmadadj"]
[ext_resource type="Theme" uid="uid://b0qmvo504e457" path="res://menu/theme/theme.tres" id="1_foq3a"]
[ext_resource type="Script" path="res://menu/settings_menu.gd" id="2_3hgm8"]
+[ext_resource type="Material" uid="uid://beea1pc5nt67r" path="res://menu/theme/dark_blur_material.tres" id="3_8nykw"]
[node name="SettingsMenu" type="Control"]
layout_mode = 3
@@ -20,12 +21,9 @@ anchor_right = 1.0
anchor_bottom = 1.0
grow_horizontal = 2
grow_vertical = 2
-theme_override_constants/margin_left = 40
-theme_override_constants/margin_top = 40
-theme_override_constants/margin_right = 40
-theme_override_constants/margin_bottom = 40
[node name="panel" type="Panel" parent="outer_gap"]
+material = ExtResource("3_8nykw")
layout_mode = 2
[node name="inner_gap" type="MarginContainer" parent="outer_gap/panel"]
diff --git a/client/menu/theme/dark_blur_material.tres b/client/menu/theme/dark_blur_material.tres
new file mode 100644
index 00000000..7adbd0e4
--- /dev/null
+++ b/client/menu/theme/dark_blur_material.tres
@@ -0,0 +1,9 @@
+[gd_resource type="ShaderMaterial" load_steps=2 format=3 uid="uid://beea1pc5nt67r"]
+
+[ext_resource type="Shader" path="res://menu/blur_mix.gdshader" id="1_cynu0"]
+
+[resource]
+shader = ExtResource("1_cynu0")
+shader_parameter/blur_amount = 3.5
+shader_parameter/mix_amount = 0.3
+shader_parameter/color_over = null
diff --git a/client/menu/theme/theme.tres b/client/menu/theme/theme.tres
index 96cdbb19..467aa6d9 100644
--- a/client/menu/theme/theme.tres
+++ b/client/menu/theme/theme.tres
@@ -1,4 +1,4 @@
-[gd_resource type="Theme" load_steps=9 format=3 uid="uid://b0qmvo504e457"]
+[gd_resource type="Theme" load_steps=10 format=3 uid="uid://b0qmvo504e457"]
[ext_resource type="FontFile" uid="uid://5ixo6b3bd3km" path="res://menu/theme/font-josefin-sans.woff2" id="1_f8qb0"]
[ext_resource type="StyleBox" uid="uid://b86kbd3pfkd5w" path="res://menu/theme/focus_style.tres" id="2_brg2c"]
@@ -39,6 +39,13 @@ grow_begin = 0.0
grow_end = 0.0
thickness = 3
+[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_sjrhv"]
+bg_color = Color(0, 0, 0, 0.6)
+corner_radius_top_left = 8
+corner_radius_top_right = 8
+corner_radius_bottom_right = 8
+corner_radius_bottom_left = 8
+
[sub_resource type="FontVariation" id="FontVariation_ff4nr"]
base_font = ExtResource("3_8u6ww")
variation_embolden = 0.7
@@ -57,6 +64,11 @@ Label/fonts/font = ExtResource("3_8u6ww")
LineEdit/styles/focus = ExtResource("2_brg2c")
LineEdit/styles/normal = SubResource("StyleBoxFlat_25x32")
LineEdit/styles/read_only = SubResource("StyleBoxFlat_25x32")
+MarginContainer/constants/margin_bottom = 32
+MarginContainer/constants/margin_left = 32
+MarginContainer/constants/margin_right = 32
+MarginContainer/constants/margin_top = 32
+Panel/styles/panel = SubResource("StyleBoxFlat_sjrhv")
RichTextLabel/fonts/bold_font = SubResource("FontVariation_ff4nr")
RichTextLabel/fonts/bold_italics_font = null
RichTextLabel/fonts/italics_font = null