wave progress

This commit is contained in:
Rendo 2025-07-16 23:26:21 +05:00
commit 8287cf609a
10 changed files with 107 additions and 3 deletions

View file

@ -0,0 +1,34 @@
[gd_scene load_steps=5 format=3 uid="uid://c668qnmmpli5r"]
[ext_resource type="Texture2D" uid="uid://oxjkxtyw0xx0" path="res://assets/sprites/wave-progress/UnderTexture.tres" id="1_60lfm"]
[ext_resource type="Texture2D" uid="uid://dbt3asr2jel6" path="res://assets/sprites/wave-progress/Fill.tres" id="2_7f727"]
[ext_resource type="Script" uid="uid://bsnt4slsbathn" path="res://scripts/gui/WaveProgress.cs" id="3_u57hj"]
[ext_resource type="Texture2D" uid="uid://bjpea7iqweexm" path="res://assets/sprites/wave-progress/Head.tres" id="4_5xdew"]
[node name="WaveProgress" type="TextureProgressBar"]
anchors_preset = -1
anchor_right = 0.238
anchor_bottom = 0.05
offset_right = 0.199997
step = 0.01
fill_mode = 1
stretch_margin_left = 20
texture_under = ExtResource("1_60lfm")
texture_progress = ExtResource("2_7f727")
texture_progress_offset = Vector2(3, 5)
script = ExtResource("3_u57hj")
[node name="Head" type="TextureRect" parent="."]
layout_mode = 1
anchors_preset = -1
anchor_left = 1.0
anchor_top = 0.5
anchor_right = 1.0
anchor_bottom = 0.5
offset_left = -11.5
offset_top = -12.0
offset_right = 11.5
offset_bottom = 12.0
texture = ExtResource("4_5xdew")
expand_mode = 1
stretch_mode = 5

View file

@ -1,10 +1,11 @@
[gd_scene load_steps=12 format=3 uid="uid://bu0dh5ct387xu"]
[gd_scene load_steps=13 format=3 uid="uid://bu0dh5ct387xu"]
[ext_resource type="PackedScene" uid="uid://dd3yegl1xo44m" path="res://scenes/templates/level_template.tscn" id="1_vdv3d"]
[ext_resource type="Resource" uid="uid://br3364jty1j0i" path="res://resources/levels/test_level_for_execution.tres" id="2_bpfdr"]
[ext_resource type="Texture2D" uid="uid://b0tb2hjum40aw" path="res://assets/sprites/background_summer.png" id="3_lsqv3"]
[ext_resource type="Script" uid="uid://84gvlkflxdhk" path="res://scripts/level/zombe_spawners/RowSpawner.cs" id="4_kn7hc"]
[ext_resource type="Script" uid="uid://puqxp2xeg1r2" path="res://scripts/level/LevelRunner.cs" id="5_vbgdr"]
[ext_resource type="PackedScene" uid="uid://c668qnmmpli5r" path="res://scenes/gui/wave_progress.tscn" id="6_yw4uo"]
[sub_resource type="Animation" id="Animation_vbgdr"]
resource_name = "CYS_Sequence"
@ -224,7 +225,14 @@ anchors_preset = -1
size_flags_horizontal = 3
size_flags_vertical = 3
[node name="ReadySetPlant" type="RichTextLabel" parent="GUI" index="2"]
[node name="WaveProgress" parent="GUI" index="2" instance=ExtResource("6_yw4uo")]
visible = false
offset_left = 443.0
offset_top = 377.0
offset_right = 443.2
offset_bottom = 377.0
[node name="ReadySetPlant" type="RichTextLabel" parent="GUI" index="3"]
visible = false
anchors_preset = 15
anchor_right = 1.0
@ -262,3 +270,6 @@ fadeAnimation = NodePath("../GameOverScreen/AnimationPlayer")
[node name="CollisionShape2D" parent="Checkbox" index="0"]
shape = SubResource("WorldBoundaryShape2D_yw4uo")
[connection signal="ResourceChanged" from="LevelRunner" to="GUI/WaveProgress" method="SetLevelData"]
[connection signal="WaveChanged" from="LevelRunner" to="GUI/WaveProgress" method="OnWaveChanged"]