Skip to content

Commit

Permalink
Merge branch 'master' of https://github.com/JU-2094/Blaze02
Browse files Browse the repository at this point in the history
  • Loading branch information
MrN3m0 committed Mar 23, 2019
2 parents 398db1b + ee844a4 commit babce99
Show file tree
Hide file tree
Showing 2 changed files with 180 additions and 0 deletions.
11 changes: 11 additions & 0 deletions Menus/OptionMenu.gd
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
extends MarginContainer

func _on_OKButton_pressed():
worlddata.music_vol = $VBoxContainer/VolSlider.value
worlddata.goto_scene("res://levels/MainMenu.tscn")
pass # replace with function body


func _on_ResetButton_pressed():
worlddata.music_vol = 100
pass # replace with function body
169 changes: 169 additions & 0 deletions Menus/OptionMenu.tscn
Original file line number Diff line number Diff line change
@@ -0,0 +1,169 @@
[gd_scene load_steps=4 format=2]

[ext_resource path="res://Menus/OptionMenu.gd" type="Script" id=1]
[ext_resource path="res://assets/HUD/font/Comfortaa-Bold.ttf" type="DynamicFontData" id=2]

[sub_resource type="DynamicFont" id=1]

size = 32
use_mipmaps = false
use_filter = false
font_data = ExtResource( 2 )
_sections_unfolded = [ "Font", "Settings" ]

[node name="MarginContainer" type="MarginContainer" index="0"]

anchor_left = 0.0
anchor_top = 0.0
anchor_right = 1.0
anchor_bottom = 1.0
rect_pivot_offset = Vector2( 0, 0 )
rect_clip_content = false
mouse_filter = 0
mouse_default_cursor_shape = 0
size_flags_horizontal = 1
size_flags_vertical = 1
script = ExtResource( 1 )

[node name="VBoxContainer" type="VBoxContainer" parent="." index="0"]

anchor_left = 0.0
anchor_top = 0.0
anchor_right = 0.0
anchor_bottom = 0.0
margin_left = 8.0
margin_right = 1024.0
margin_bottom = 600.0
rect_pivot_offset = Vector2( 0, 0 )
rect_clip_content = false
mouse_filter = 1
mouse_default_cursor_shape = 0
size_flags_horizontal = 1
size_flags_vertical = 1
alignment = 1

[node name="Label" type="Label" parent="VBoxContainer" index="0"]

anchor_left = 0.0
anchor_top = 0.0
anchor_right = 0.0
anchor_bottom = 0.0
margin_top = 247.0
margin_right = 1016.0
margin_bottom = 284.0
rect_pivot_offset = Vector2( 0, 0 )
rect_clip_content = false
mouse_filter = 2
mouse_default_cursor_shape = 0
size_flags_horizontal = 1
size_flags_vertical = 4
custom_fonts/font = SubResource( 1 )
text = "AUDIO VOLUME"
align = 1
valign = 1
percent_visible = 1.0
lines_skipped = 0
max_lines_visible = -1
_sections_unfolded = [ "custom_fonts" ]

[node name="VolSlider" type="HSlider" parent="VBoxContainer" index="1"]

anchor_left = 0.0
anchor_top = 0.0
anchor_right = 0.0
anchor_bottom = 0.0
margin_top = 288.0
margin_right = 1016.0
margin_bottom = 304.0
rect_pivot_offset = Vector2( 0, 0 )
rect_clip_content = false
focus_mode = 2
mouse_filter = 0
mouse_default_cursor_shape = 0
size_flags_horizontal = 1
size_flags_vertical = 0
min_value = -12.0
max_value = 12.0
step = 1.0
page = 0.0
value = 12.0
exp_edit = false
rounded = false
editable = true
tick_count = 0
ticks_on_borders = true
focus_mode = 2
_sections_unfolded = [ "Margin" ]

[node name="VBoxContainer" type="VBoxContainer" parent="VBoxContainer" index="2"]

anchor_left = 0.0
anchor_top = 0.0
anchor_right = 0.0
anchor_bottom = 0.0
margin_top = 308.0
margin_right = 1016.0
margin_bottom = 352.0
rect_pivot_offset = Vector2( 0, 0 )
rect_clip_content = false
mouse_filter = 1
mouse_default_cursor_shape = 0
size_flags_horizontal = 1
size_flags_vertical = 1
alignment = 1
_sections_unfolded = [ "Margin" ]

[node name="OKButton" type="Button" parent="VBoxContainer/VBoxContainer" index="0"]

anchor_left = 0.0
anchor_top = 0.0
anchor_right = 0.0
anchor_bottom = 0.0
margin_right = 1016.0
margin_bottom = 20.0
rect_pivot_offset = Vector2( 0, 0 )
rect_clip_content = false
focus_mode = 2
mouse_filter = 0
mouse_default_cursor_shape = 0
size_flags_horizontal = 1
size_flags_vertical = 1
toggle_mode = false
enabled_focus_mode = 2
shortcut = null
group = null
text = "OK"
flat = false
align = 1
_sections_unfolded = [ "Rect" ]

[node name="ResetButton" type="Button" parent="VBoxContainer/VBoxContainer" index="1"]

anchor_left = 0.0
anchor_top = 0.0
anchor_right = 0.0
anchor_bottom = 0.0
margin_top = 24.0
margin_right = 1016.0
margin_bottom = 44.0
rect_pivot_offset = Vector2( 0, 0 )
rect_clip_content = false
focus_mode = 2
mouse_filter = 0
mouse_default_cursor_shape = 0
size_flags_horizontal = 1
size_flags_vertical = 1
toggle_mode = false
enabled_focus_mode = 2
shortcut = null
group = null
text = "RESET VALUES"
flat = false
align = 1
_sections_unfolded = [ "Rect", "custom_fonts" ]

[connection signal="pressed" from="VBoxContainer/VBoxContainer/OKButton" to="." method="_on_OKButton_pressed"]

[connection signal="pressed" from="VBoxContainer/VBoxContainer/ResetButton" to="." method="_on_ResetButton_pressed"]


0 comments on commit babce99

Please sign in to comment.