Added main menu and basic functionality

This commit is contained in:
=
2026-04-26 16:55:35 +02:00
parent 21199f8026
commit d2c788c826
6 changed files with 119 additions and 1 deletions
+91
View File
@@ -0,0 +1,91 @@
[gd_scene format=3 uid="uid://dlommaelbbw2b"]
[ext_resource type="Script" uid="uid://dda0bhhqspbr0" path="res://Scripts/MainMenu.cs" id="1_tt5f1"]
[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_bnhvo"]
bg_color = Color(0.24115604, 0.24115607, 0.24115595, 1)
border_width_top = 1
border_width_bottom = 1
border_color = Color(0.025273602, 0.38374466, 0.4973219, 1)
corner_radius_top_left = 10
corner_radius_top_right = 10
corner_radius_bottom_right = 10
corner_radius_bottom_left = 10
[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_tt5f1"]
bg_color = Color(0.46618086, 0.4661808, 0.4661808, 1)
border_width_top = 1
border_width_bottom = 1
border_color = Color(0.025273602, 0.38374466, 0.4973219, 1)
corner_radius_top_left = 10
corner_radius_top_right = 10
corner_radius_bottom_right = 10
corner_radius_bottom_left = 10
[node name="MainMenu" type="Control" unique_id=622011874]
layout_mode = 3
anchors_preset = 15
anchor_right = 1.0
anchor_bottom = 1.0
grow_horizontal = 2
grow_vertical = 2
script = ExtResource("1_tt5f1")
[node name="Panel" type="Panel" parent="." unique_id=167014122]
layout_mode = 1
anchors_preset = 15
anchor_right = 1.0
anchor_bottom = 1.0
grow_horizontal = 2
grow_vertical = 2
[node name="CenterContainer" type="CenterContainer" parent="." unique_id=546163427]
layout_mode = 1
anchors_preset = 8
anchor_left = 0.5
anchor_top = 0.5
anchor_right = 0.5
anchor_bottom = 0.5
offset_left = -4.0
offset_top = -126.5
offset_right = 4.0
offset_bottom = 126.5
grow_horizontal = 2
grow_vertical = 2
[node name="VBoxContainer" type="VBoxContainer" parent="CenterContainer" unique_id=1309259619]
layout_mode = 2
theme_override_constants/separation = 40
[node name="RichTextLabel" type="RichTextLabel" parent="CenterContainer/VBoxContainer" unique_id=195514567]
layout_mode = 2
bbcode_enabled = true
text = "[font_size=50]RuinAdventurer[/font_size]"
fit_content = true
scroll_active = false
autowrap_mode = 0
horizontal_alignment = 1
[node name="Spacer" type="Panel" parent="CenterContainer/VBoxContainer" unique_id=1075556994]
layout_mode = 2
[node name="btnPlay" type="Button" parent="CenterContainer/VBoxContainer" unique_id=452402808]
layout_mode = 2
theme_override_styles/normal = SubResource("StyleBoxFlat_bnhvo")
theme_override_styles/hover = SubResource("StyleBoxFlat_tt5f1")
text = "Start Game"
[node name="btnOptions" type="Button" parent="CenterContainer/VBoxContainer" unique_id=891656915]
layout_mode = 2
theme_override_styles/normal = SubResource("StyleBoxFlat_bnhvo")
theme_override_styles/hover = SubResource("StyleBoxFlat_tt5f1")
text = "Options"
[node name="btnExit" type="Button" parent="CenterContainer/VBoxContainer" unique_id=2025231658]
layout_mode = 2
theme_override_styles/normal = SubResource("StyleBoxFlat_bnhvo")
theme_override_styles/hover = SubResource("StyleBoxFlat_tt5f1")
text = "Exit Game"
[connection signal="button_up" from="CenterContainer/VBoxContainer/btnPlay" to="." method="OnPlayPressed"]
[connection signal="button_up" from="CenterContainer/VBoxContainer/btnExit" to="." method="OnQuitPressed"]