options screen functionality :):):):):)

This commit is contained in:
Haze Weathers 2023-03-08 16:46:23 -05:00
parent 89b4bc045e
commit 1fc44271f1
10 changed files with 271 additions and 36 deletions

View file

@ -1,8 +1,7 @@
[gd_scene load_steps=11 format=2]
[gd_scene load_steps=10 format=2]
[ext_resource path="res://objects/hud/options_screen.gd" type="Script" id=1]
[ext_resource path="res://ui/theme.tres" type="Theme" id=2]
[ext_resource path="res://ui/border.png" type="Texture" id=3]
[ext_resource path="res://objects/hud/selection_group.gd" type="Script" id=4]
[sub_resource type="StyleBoxFlat" id=6]
@ -31,24 +30,11 @@ theme = ExtResource( 2 )
script = ExtResource( 1 )
tab_selected_style = SubResource( 6 )
[node name="Border" type="NinePatchRect" parent="."]
show_behind_parent = true
[node name="Panel" type="Panel" parent="."]
margin_left = 8.0
margin_top = 17.0
margin_top = 16.0
margin_right = 248.0
margin_bottom = 175.0
texture = ExtResource( 3 )
patch_margin_left = 3
patch_margin_top = 3
patch_margin_right = 3
patch_margin_bottom = 3
[node name="ColorRect" type="ColorRect" parent="."]
margin_left = 11.0
margin_top = 20.0
margin_right = 245.0
margin_bottom = 172.0
color = Color( 0.239216, 0.239216, 0.443137, 1 )
margin_bottom = 176.0
[node name="OptionsTitle" type="Label" parent="."]
margin_left = 16.0
@ -67,6 +53,7 @@ margin_bottom = 152.0
theme = ExtResource( 2 )
[node name="Game" type="VBoxContainer" parent="Tabs"]
visible = false
anchor_right = 1.0
anchor_bottom = 1.0
margin_top = 7.0
@ -79,6 +66,7 @@ margin_bottom = 8.0
rect_min_size = Vector2( 0, 8 )
[node name="Rumble" type="HBoxContainer" parent="Tabs/Game"]
unique_name_in_owner = true
margin_top = 8.0
margin_right = 224.0
margin_bottom = 28.0
@ -134,7 +122,6 @@ text = "BPM"
align = 0
[node name="Video" type="VBoxContainer" parent="Tabs"]
visible = false
anchor_right = 1.0
anchor_bottom = 1.0
margin_top = 7.0
@ -147,6 +134,7 @@ margin_bottom = 8.0
rect_min_size = Vector2( 0, 8 )
[node name="Fullscreen" type="HBoxContainer" parent="Tabs/Video"]
unique_name_in_owner = true
margin_top = 8.0
margin_right = 224.0
margin_bottom = 28.0
@ -172,6 +160,7 @@ focus_neighbour_right = NodePath("../On")
size_flags_horizontal = 6
size_flags_vertical = 0
toggle_mode = true
pressed = true
action_mode = 0
group = SubResource( 7 )
text = "Off"
@ -185,12 +174,12 @@ focus_neighbour_right = NodePath(".")
size_flags_horizontal = 6
size_flags_vertical = 0
toggle_mode = true
pressed = true
action_mode = 0
group = SubResource( 7 )
text = "on"
[node name="WindowSize" type="HBoxContainer" parent="Tabs/Video"]
unique_name_in_owner = true
margin_top = 28.0
margin_right = 224.0
margin_bottom = 48.0
@ -267,6 +256,7 @@ group = SubResource( 3 )
text = "5x"
[node name="ScalingMode" type="HBoxContainer" parent="Tabs/Video"]
unique_name_in_owner = true
margin_top = 48.0
margin_right = 224.0
margin_bottom = 68.0
@ -321,6 +311,7 @@ text = "stretch"
align = 0
[node name="TransitionSpeed" type="HBoxContainer" parent="Tabs/Video"]
unique_name_in_owner = true
margin_top = 68.0
margin_right = 224.0
margin_bottom = 88.0
@ -410,6 +401,7 @@ size_flags_vertical = 1
text = "Master vol.:"
[node name="MasterSlider" type="HSlider" parent="Tabs/Audio/MasterVolume"]
unique_name_in_owner = true
margin_left = 99.0
margin_right = 199.0
margin_bottom = 10.0
@ -417,7 +409,10 @@ rect_min_size = Vector2( 100, 0 )
focus_neighbour_top = NodePath("../../../..")
focus_neighbour_bottom = NodePath("../../MusicVolume/MusicSlider")
size_flags_horizontal = 3
value = 100.0
max_value = 1.0
step = 0.05
value = 1.0
scrollable = false
__meta__ = {
"_edit_group_": true
}
@ -444,6 +439,7 @@ size_flags_vertical = 1
text = "music vol.:"
[node name="MusicSlider" type="HSlider" parent="Tabs/Audio/MusicVolume"]
unique_name_in_owner = true
margin_left = 99.0
margin_right = 199.0
margin_bottom = 10.0
@ -451,7 +447,10 @@ rect_min_size = Vector2( 100, 0 )
focus_neighbour_top = NodePath("../../MasterVolume/MasterSlider")
focus_neighbour_bottom = NodePath("../../SoundVolume/SoundSlider")
size_flags_horizontal = 3
value = 100.0
max_value = 1.0
step = 0.05
value = 1.0
scrollable = false
__meta__ = {
"_edit_group_": true
}
@ -478,13 +477,17 @@ size_flags_vertical = 1
text = "SOund vol.:"
[node name="SoundSlider" type="HSlider" parent="Tabs/Audio/SoundVolume"]
unique_name_in_owner = true
margin_left = 99.0
margin_right = 199.0
margin_bottom = 10.0
rect_min_size = Vector2( 100, 0 )
focus_neighbour_top = NodePath("../../MusicVolume/MusicSlider")
size_flags_horizontal = 3
value = 100.0
max_value = 1.0
step = 0.05
value = 1.0
scrollable = false
__meta__ = {
"_edit_group_": true
}
@ -509,6 +512,40 @@ margin_right = 224.0
margin_bottom = 7.0
text = "Z: back, X: apply, C: defaults"
[node name="ConfirmDialog" type="PanelContainer" parent="."]
visible = false
margin_left = 48.0
margin_top = 40.0
margin_right = 208.0
margin_bottom = 88.0
focus_mode = 2
[node name="Label" type="Label" parent="ConfirmDialog"]
margin_left = 3.0
margin_top = 3.0
margin_right = 157.0
margin_bottom = 45.0
size_flags_vertical = 5
text = "Apply Changes?"
align = 1
[node name="Label2" type="Label" parent="ConfirmDialog"]
margin_left = 3.0
margin_top = 20.0
margin_right = 157.0
margin_bottom = 27.0
text = "X: apply, Z: discard"
align = 1
[connection signal="focus_entered" from="." to="." method="_on_tabs_focus_entered"]
[connection signal="focus_exited" from="." to="." method="_on_tabs_focus_exited"]
[connection signal="gui_input" from="OptionsTitle" to="." method="_on_Tabs_gui_input"]
[connection signal="selection_changed" from="Tabs/Game/Rumble" to="." method="_mark_dirty"]
[connection signal="selection_changed" from="Tabs/Video/Fullscreen" to="." method="_mark_dirty"]
[connection signal="selection_changed" from="Tabs/Video/WindowSize" to="." method="_mark_dirty"]
[connection signal="selection_changed" from="Tabs/Video/ScalingMode" to="." method="_mark_dirty"]
[connection signal="selection_changed" from="Tabs/Video/TransitionSpeed" to="." method="_mark_dirty"]
[connection signal="value_changed" from="Tabs/Audio/MasterVolume/MasterSlider" to="." method="_mark_dirty"]
[connection signal="value_changed" from="Tabs/Audio/MusicVolume/MusicSlider" to="." method="_mark_dirty"]
[connection signal="value_changed" from="Tabs/Audio/SoundVolume/SoundSlider" to="." method="_mark_dirty"]
[connection signal="gui_input" from="ConfirmDialog" to="." method="_on_ConfirmDialog_gui_input"]