New player add method

This commit is contained in:
Marco 2025-01-22 11:35:37 +01:00
commit a235183c61
8 changed files with 116 additions and 58 deletions

View file

@ -1,11 +1,38 @@
[gd_scene load_steps=2 format=3 uid="uid://c567m475j0axf"]
[gd_scene load_steps=3 format=3 uid="uid://dkwi1hu1bixoe"]
[ext_resource type="FontFile" uid="uid://ccm3u37q1hvux" path="res://fonts/Xolonium-Regular.ttf" id="1_ye2ho"]
[ext_resource type="Script" path="res://Scripts/Hud.cs" id="1_m0hb0"]
[ext_resource type="FontFile" uid="uid://ccm3u37q1hvux" path="res://fonts/Xolonium-Regular.ttf" id="2_0xmx2"]
[node name="Hud" type="CanvasLayer"]
[node name="HUD" type="CanvasLayer"]
script = ExtResource("1_m0hb0")
[node name="HealthLabel" type="Label" parent="."]
offset_right = 40.0
offset_bottom = 23.0
theme_override_fonts/font = ExtResource("1_ye2ho")
text = "100"
[node name="Health" type="Label" parent="."]
anchors_preset = 2
anchor_top = 1.0
anchor_bottom = 1.0
offset_top = -78.0
offset_right = 305.0
grow_vertical = 0
theme_override_fonts/font = ExtResource("2_0xmx2")
theme_override_font_sizes/font_size = 64
text = "100/100"
[node name="Message" type="Label" parent="."]
anchors_preset = 8
anchor_left = 0.5
anchor_top = 0.5
anchor_right = 0.5
anchor_bottom = 0.5
offset_left = -217.0
offset_top = -39.0
offset_right = 217.0
offset_bottom = 39.0
grow_horizontal = 2
grow_vertical = 2
theme_override_fonts/font = ExtResource("2_0xmx2")
theme_override_font_sizes/font_size = 64
text = "GAME OVER"
[node name="MessageTimer" type="Timer" parent="."]
wait_time = 2.0
one_shot = true

View file

@ -1,38 +0,0 @@
[gd_scene load_steps=3 format=3 uid="uid://dkwi1hu1bixoe"]
[ext_resource type="Script" path="res://Scripts/Hud.cs" id="1_m0hb0"]
[ext_resource type="FontFile" uid="uid://ccm3u37q1hvux" path="res://fonts/Xolonium-Regular.ttf" id="2_0xmx2"]
[node name="HUD" type="CanvasLayer"]
script = ExtResource("1_m0hb0")
[node name="Health" type="Label" parent="."]
anchors_preset = 2
anchor_top = 1.0
anchor_bottom = 1.0
offset_top = -78.0
offset_right = 305.0
grow_vertical = 0
theme_override_fonts/font = ExtResource("2_0xmx2")
theme_override_font_sizes/font_size = 64
text = "100/100"
[node name="Message" type="Label" parent="."]
anchors_preset = 8
anchor_left = 0.5
anchor_top = 0.5
anchor_right = 0.5
anchor_bottom = 0.5
offset_left = -217.0
offset_top = -39.0
offset_right = 217.0
offset_bottom = 39.0
grow_horizontal = 2
grow_vertical = 2
theme_override_fonts/font = ExtResource("2_0xmx2")
theme_override_font_sizes/font_size = 64
text = "GAME OVER"
[node name="MessageTimer" type="Timer" parent="."]
wait_time = 2.0
one_shot = true