[gd_scene load_steps=2 format=3 uid="uid://57obmcwyos2g"]

[ext_resource type="Script" uid="uid://c8mlvlerv4y03" path="res://scenes/ui/SettingsMenu.gd" id="1_oqkcn"]

[node name="SettingsMenu" type="Control" groups=["localizable"]]
layout_mode = 3
anchors_preset = 15
anchor_right = 1.0
anchor_bottom = 1.0
grow_horizontal = 2
grow_vertical = 2
script = ExtResource("1_oqkcn")

[node name="SettingsContainer" type="VBoxContainer" parent="."]
layout_mode = 1
anchors_preset = 8
anchor_left = 0.5
anchor_top = 0.5
anchor_right = 0.5
anchor_bottom = 0.5
offset_left = -34.5
offset_top = -20.0
offset_right = 34.5
offset_bottom = 20.0
grow_horizontal = 2
grow_vertical = 2

[node name="SettingsTitle" type="Label" parent="SettingsContainer"]
custom_minimum_size = Vector2(300, 0)
layout_mode = 2
text = "Settings"

[node name="MasterVolumeContainer" type="HBoxContainer" parent="SettingsContainer"]
layout_mode = 2

[node name="MasterVolume" type="Label" parent="SettingsContainer/MasterVolumeContainer"]
custom_minimum_size = Vector2(150, 0)
layout_mode = 2
text = "Master Volume"

[node name="MasterVolumeSlider" type="HSlider" parent="SettingsContainer/MasterVolumeContainer"]
layout_mode = 2
size_flags_horizontal = 3
max_value = 1.0
step = 0.1
value = 0.5

[node name="MusicVolumeContainer" type="HBoxContainer" parent="SettingsContainer"]
layout_mode = 2

[node name="MusicVolume" type="Label" parent="SettingsContainer/MusicVolumeContainer"]
custom_minimum_size = Vector2(150, 0)
layout_mode = 2
text = "Music Volume"

[node name="MusicVolumeSlider" type="HSlider" parent="SettingsContainer/MusicVolumeContainer"]
layout_mode = 2
size_flags_horizontal = 3
max_value = 1.0
step = 0.1
value = 0.5

[node name="SFXVolumeContainer" type="HBoxContainer" parent="SettingsContainer"]
layout_mode = 2

[node name="SFXVolume" type="Label" parent="SettingsContainer/SFXVolumeContainer"]
custom_minimum_size = Vector2(150, 0)
layout_mode = 2
text = "SFX Volume"

[node name="SFXVolumeSlider" type="HSlider" parent="SettingsContainer/SFXVolumeContainer"]
layout_mode = 2
size_flags_horizontal = 3
max_value = 1.0
step = 0.1
value = 0.5

[node name="LanguageContainer" type="HBoxContainer" parent="SettingsContainer"]
layout_mode = 2
size_flags_vertical = 4

[node name="LanguageLabel" type="Label" parent="SettingsContainer/LanguageContainer"]
custom_minimum_size = Vector2(150, 0)
layout_mode = 2
text = "Language"

[node name="LanguageSelector" type="OptionButton" parent="SettingsContainer/LanguageContainer"]
layout_mode = 2
size_flags_horizontal = 4
selected = 0
item_count = 5
popup/item_0/text = "English"
popup/item_0/id = 0
popup/item_1/text = "Español"
popup/item_1/id = 1
popup/item_2/text = "Français"
popup/item_2/id = 2
popup/item_3/text = "Deutsch"
popup/item_3/id = 3
popup/item_4/text = "Русский"
popup/item_4/id = 2

[node name="BackButtonContainer" type="Control" parent="."]
layout_mode = 1
anchors_preset = 0
offset_right = 40.0
offset_bottom = 40.0

[node name="BackButton" type="Button" parent="BackButtonContainer"]
layout_mode = 0
offset_right = 8.0
offset_bottom = 8.0
text = "back"

[node name="ResetSettingsContainer" type="Control" parent="."]
layout_mode = 1
anchors_preset = 7
anchor_left = 0.5
anchor_top = 1.0
anchor_right = 0.5
anchor_bottom = 1.0
offset_left = -20.0
offset_top = -40.0
offset_right = 20.0
grow_horizontal = 2
grow_vertical = 0

[node name="ResetSettingButton" type="Button" parent="ResetSettingsContainer"]
layout_mode = 1
anchors_preset = 5
anchor_left = 0.5
anchor_right = 0.5
offset_left = -98.0
offset_right = 98.0
offset_bottom = 31.0
grow_horizontal = 2
text = "Reset settings to default"

[connection signal="value_changed" from="SettingsContainer/MasterVolumeContainer/MasterVolumeSlider" to="." method="_on_master_volume_changed"]
[connection signal="value_changed" from="SettingsContainer/MusicVolumeContainer/MusicVolumeSlider" to="." method="_on_music_volume_changed"]
[connection signal="value_changed" from="SettingsContainer/SFXVolumeContainer/SFXVolumeSlider" to="." method="_on_sfx_volume_changed"]
[connection signal="item_selected" from="SettingsContainer/LanguageContainer/LanguageSelector" to="." method="_on_language_selector_item_selected"]
[connection signal="pressed" from="BackButtonContainer/BackButton" to="." method="_on_back_button_pressed"]
[connection signal="pressed" from="ResetSettingsContainer/ResetSettingButton" to="." method="_on_reset_setting_button_pressed"]
