Procházet zdrojové kódy

:sparkles: added game over screen

Felix Bytow před 10 měsíci
rodič
revize
0854da76b8
30 změnil soubory, kde provedl 752 přidání a 13 odebrání
  1. binární
      assets/audio/Failure_V2.wav
  2. 24 0
      assets/audio/Failure_V2.wav.import
  3. 0 1
      assets/scenes/demon.tscn
  4. 23 0
      assets/scenes/game_over.gd
  5. 217 0
      assets/scenes/game_over.tscn
  6. binární
      assets/textures/game_over/failure_1.png
  7. 34 0
      assets/textures/game_over/failure_1.png.import
  8. binární
      assets/textures/game_over/failure_10.png
  9. 34 0
      assets/textures/game_over/failure_10.png.import
  10. binární
      assets/textures/game_over/failure_11.png
  11. 34 0
      assets/textures/game_over/failure_11.png.import
  12. binární
      assets/textures/game_over/failure_2.png
  13. 34 0
      assets/textures/game_over/failure_2.png.import
  14. binární
      assets/textures/game_over/failure_3.png
  15. 34 0
      assets/textures/game_over/failure_3.png.import
  16. binární
      assets/textures/game_over/failure_4.png
  17. 34 0
      assets/textures/game_over/failure_4.png.import
  18. binární
      assets/textures/game_over/failure_5.png
  19. 34 0
      assets/textures/game_over/failure_5.png.import
  20. binární
      assets/textures/game_over/failure_6.png
  21. 34 0
      assets/textures/game_over/failure_6.png.import
  22. binární
      assets/textures/game_over/failure_7.png
  23. 34 0
      assets/textures/game_over/failure_7.png.import
  24. binární
      assets/textures/game_over/failure_8.png
  25. 34 0
      assets/textures/game_over/failure_8.png.import
  26. binární
      assets/textures/game_over/failure_9.png
  27. 34 0
      assets/textures/game_over/failure_9.png.import
  28. 40 0
      export_presets.cfg
  29. 40 11
      screens/game.gd
  30. 34 1
      screens/game.tscn

binární
assets/audio/Failure_V2.wav


+ 24 - 0
assets/audio/Failure_V2.wav.import

@@ -0,0 +1,24 @@
+[remap]
+
+importer="wav"
+type="AudioStreamWAV"
+uid="uid://oud2xp50pbmx"
+path="res://.godot/imported/Failure_V2.wav-cccf89b49a7206a44e5051e4ace79b7a.sample"
+
+[deps]
+
+source_file="res://assets/audio/Failure_V2.wav"
+dest_files=["res://.godot/imported/Failure_V2.wav-cccf89b49a7206a44e5051e4ace79b7a.sample"]
+
+[params]
+
+force/8_bit=false
+force/mono=false
+force/max_rate=false
+force/max_rate_hz=44100
+edit/trim=true
+edit/normalize=false
+edit/loop_mode=1
+edit/loop_begin=0
+edit/loop_end=-1
+compress/mode=0

+ 0 - 1
assets/scenes/demon.tscn

@@ -51,7 +51,6 @@ sprite_frames = SubResource("SpriteFrames_nbhay")
 animation = &"shoot"
 
 [node name="DragShape" type="CollisionShape2D" parent="."]
-scale = Vector2(1, 1)
 shape = SubResource("RectangleShape2D_d3lxi")
 
 [connection signal="input_event" from="." to="." method="_on_input_event"]

+ 23 - 0
assets/scenes/game_over.gd

@@ -0,0 +1,23 @@
+extends Control
+class_name GameOver
+
+signal closed
+
+@onready var animation: AnimationPlayer = $AnimationPlayer
+@onready var message_label: Label = $MessageLabel
+
+var message: String = "":
+	set(new_value):
+		message = new_value
+		if message_label != null:
+			message_label.text = new_value
+
+func _ready() -> void:
+	message_label.text = message
+	animation.play("open")
+
+func _on_close_button_pressed():
+	animation.play("close")
+	await animation.animation_finished
+	closed.emit()
+	queue_free()

+ 217 - 0
assets/scenes/game_over.tscn

@@ -0,0 +1,217 @@
+[gd_scene load_steps=19 format=3 uid="uid://8exnor7d4r2k"]
+
+[ext_resource type="Texture2D" uid="uid://cpefd3ejowpm1" path="res://assets/textures/game_over/failure_2.png" id="1_g6qpv"]
+[ext_resource type="Script" path="res://assets/scenes/game_over.gd" id="1_o647k"]
+[ext_resource type="Texture2D" uid="uid://dm5y2mjdav5m3" path="res://assets/textures/game_over/failure_1.png" id="2_icodc"]
+[ext_resource type="Texture2D" uid="uid://csyxhb3cip37v" path="res://assets/textures/game_over/failure_3.png" id="3_kkw3b"]
+[ext_resource type="Texture2D" uid="uid://c724uexjbodrv" path="res://assets/textures/game_over/failure_4.png" id="4_bii53"]
+[ext_resource type="Texture2D" uid="uid://48pprrrgfe7d" path="res://assets/textures/game_over/failure_5.png" id="5_cw6tv"]
+[ext_resource type="Texture2D" uid="uid://mlvqnk46xvvv" path="res://assets/textures/game_over/failure_6.png" id="6_bpy0b"]
+[ext_resource type="Texture2D" uid="uid://ckmqguoahfdxh" path="res://assets/textures/game_over/failure_7.png" id="7_mbl13"]
+[ext_resource type="Texture2D" uid="uid://ni6mhofo4bcb" path="res://assets/textures/game_over/failure_8.png" id="8_pnhfj"]
+[ext_resource type="Texture2D" uid="uid://buvi4nksxorx3" path="res://assets/textures/game_over/failure_9.png" id="9_3cacg"]
+[ext_resource type="Texture2D" uid="uid://dnwoqdwr8u5md" path="res://assets/textures/game_over/failure_10.png" id="10_0jp7g"]
+[ext_resource type="Texture2D" uid="uid://dk7spqxunogqr" path="res://assets/textures/game_over/failure_11.png" id="11_vpf65"]
+[ext_resource type="AudioStream" uid="uid://oud2xp50pbmx" path="res://assets/audio/Failure_V2.wav" id="13_upgmu"]
+
+[sub_resource type="Animation" id="Animation_bfgqb"]
+length = 0.001
+tracks/0/type = "value"
+tracks/0/imported = false
+tracks/0/enabled = true
+tracks/0/path = NodePath("Background:texture")
+tracks/0/interp = 1
+tracks/0/loop_wrap = true
+tracks/0/keys = {
+"times": PackedFloat32Array(0),
+"transitions": PackedFloat32Array(1),
+"update": 1,
+"values": [ExtResource("1_g6qpv")]
+}
+tracks/1/type = "value"
+tracks/1/imported = false
+tracks/1/enabled = true
+tracks/1/path = NodePath("CloseButton:visible")
+tracks/1/interp = 1
+tracks/1/loop_wrap = true
+tracks/1/keys = {
+"times": PackedFloat32Array(0),
+"transitions": PackedFloat32Array(1),
+"update": 1,
+"values": [true]
+}
+tracks/2/type = "value"
+tracks/2/imported = false
+tracks/2/enabled = true
+tracks/2/path = NodePath("MessageLabel:visible")
+tracks/2/interp = 1
+tracks/2/loop_wrap = true
+tracks/2/keys = {
+"times": PackedFloat32Array(0),
+"transitions": PackedFloat32Array(1),
+"update": 1,
+"values": [false]
+}
+
+[sub_resource type="Animation" id="Animation_a40w7"]
+resource_name = "open"
+length = 0.5
+tracks/0/type = "value"
+tracks/0/imported = false
+tracks/0/enabled = true
+tracks/0/path = NodePath("Background:texture")
+tracks/0/interp = 1
+tracks/0/loop_wrap = true
+tracks/0/keys = {
+"times": PackedFloat32Array(0, 0.05, 0.1, 0.15, 0.2, 0.25, 0.3, 0.35, 0.4, 0.45, 0.5),
+"transitions": PackedFloat32Array(1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1),
+"update": 1,
+"values": [ExtResource("2_icodc"), ExtResource("1_g6qpv"), ExtResource("3_kkw3b"), ExtResource("4_bii53"), ExtResource("5_cw6tv"), ExtResource("6_bpy0b"), ExtResource("7_mbl13"), ExtResource("8_pnhfj"), ExtResource("9_3cacg"), ExtResource("10_0jp7g"), ExtResource("11_vpf65")]
+}
+tracks/1/type = "value"
+tracks/1/imported = false
+tracks/1/enabled = true
+tracks/1/path = NodePath("CloseButton:visible")
+tracks/1/interp = 1
+tracks/1/loop_wrap = true
+tracks/1/keys = {
+"times": PackedFloat32Array(0, 0.5),
+"transitions": PackedFloat32Array(1, 1),
+"update": 1,
+"values": [false, true]
+}
+tracks/2/type = "value"
+tracks/2/imported = false
+tracks/2/enabled = true
+tracks/2/path = NodePath("MessageLabel:visible")
+tracks/2/interp = 1
+tracks/2/loop_wrap = true
+tracks/2/keys = {
+"times": PackedFloat32Array(0, 0.5),
+"transitions": PackedFloat32Array(1, 1),
+"update": 1,
+"values": [false, true]
+}
+
+[sub_resource type="Animation" id="Animation_yytoc"]
+resource_name = "close"
+length = 0.5
+tracks/0/type = "value"
+tracks/0/imported = false
+tracks/0/enabled = true
+tracks/0/path = NodePath("Background:texture")
+tracks/0/interp = 1
+tracks/0/loop_wrap = true
+tracks/0/keys = {
+"times": PackedFloat32Array(0, 0.05, 0.1, 0.15, 0.2, 0.25, 0.3, 0.35, 0.4, 0.45, 0.5),
+"transitions": PackedFloat32Array(1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1),
+"update": 1,
+"values": [ExtResource("11_vpf65"), ExtResource("10_0jp7g"), ExtResource("9_3cacg"), ExtResource("8_pnhfj"), ExtResource("7_mbl13"), ExtResource("6_bpy0b"), ExtResource("5_cw6tv"), ExtResource("4_bii53"), ExtResource("3_kkw3b"), ExtResource("1_g6qpv"), ExtResource("2_icodc")]
+}
+tracks/1/type = "value"
+tracks/1/imported = false
+tracks/1/enabled = true
+tracks/1/path = NodePath("CloseButton:visible")
+tracks/1/interp = 1
+tracks/1/loop_wrap = true
+tracks/1/keys = {
+"times": PackedFloat32Array(0),
+"transitions": PackedFloat32Array(1),
+"update": 1,
+"values": [false]
+}
+tracks/2/type = "value"
+tracks/2/imported = false
+tracks/2/enabled = true
+tracks/2/path = NodePath("MessageLabel:visible")
+tracks/2/interp = 1
+tracks/2/loop_wrap = true
+tracks/2/keys = {
+"times": PackedFloat32Array(0),
+"transitions": PackedFloat32Array(1),
+"update": 1,
+"values": [false]
+}
+
+[sub_resource type="AnimationLibrary" id="AnimationLibrary_fmmxf"]
+_data = {
+"RESET": SubResource("Animation_bfgqb"),
+"close": SubResource("Animation_yytoc"),
+"open": SubResource("Animation_a40w7")
+}
+
+[sub_resource type="LabelSettings" id="LabelSettings_d7ov6"]
+font_size = 22
+
+[node name="GameOver" type="Control"]
+process_mode = 3
+layout_mode = 3
+anchors_preset = 15
+anchor_right = 1.0
+anchor_bottom = 1.0
+grow_horizontal = 2
+grow_vertical = 2
+script = ExtResource("1_o647k")
+
+[node name="Background" type="TextureRect" 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 = -20.0
+offset_top = -20.0
+offset_right = 20.0
+offset_bottom = 20.0
+grow_horizontal = 2
+grow_vertical = 2
+texture = ExtResource("1_g6qpv")
+
+[node name="AnimationPlayer" type="AnimationPlayer" parent="."]
+libraries = {
+"": SubResource("AnimationLibrary_fmmxf")
+}
+
+[node name="CloseButton" type="Button" 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 = -152.0
+offset_top = 135.0
+offset_right = 153.0
+offset_bottom = 188.0
+grow_horizontal = 2
+grow_vertical = 2
+theme_override_font_sizes/font_size = 32
+text = "CLOSE"
+
+[node name="MessageLabel" type="Label" parent="."]
+visible = false
+custom_minimum_size = Vector2(340, 180)
+layout_mode = 1
+anchors_preset = 8
+anchor_left = 0.5
+anchor_top = 0.5
+anchor_right = 0.5
+anchor_bottom = 0.5
+offset_left = -20.0
+offset_top = -11.5
+offset_right = 20.0
+offset_bottom = 11.5
+grow_horizontal = 2
+grow_vertical = 2
+text = "YOU DIED AFTER
+COMPLETING 9999 WAVES!"
+label_settings = SubResource("LabelSettings_d7ov6")
+horizontal_alignment = 1
+vertical_alignment = 1
+
+[node name="VoiceOver" type="AudioStreamPlayer" parent="."]
+stream = ExtResource("13_upgmu")
+autoplay = true
+
+[connection signal="pressed" from="CloseButton" to="." method="_on_close_button_pressed"]

binární
assets/textures/game_over/failure_1.png


+ 34 - 0
assets/textures/game_over/failure_1.png.import

@@ -0,0 +1,34 @@
+[remap]
+
+importer="texture"
+type="CompressedTexture2D"
+uid="uid://dm5y2mjdav5m3"
+path="res://.godot/imported/failure_1.png-efe27ce286fa9b3a8993779118bcfbf7.ctex"
+metadata={
+"vram_texture": false
+}
+
+[deps]
+
+source_file="res://assets/textures/game_over/failure_1.png"
+dest_files=["res://.godot/imported/failure_1.png-efe27ce286fa9b3a8993779118bcfbf7.ctex"]
+
+[params]
+
+compress/mode=0
+compress/high_quality=false
+compress/lossy_quality=0.7
+compress/hdr_compression=1
+compress/normal_map=0
+compress/channel_pack=0
+mipmaps/generate=false
+mipmaps/limit=-1
+roughness/mode=0
+roughness/src_normal=""
+process/fix_alpha_border=true
+process/premult_alpha=false
+process/normal_map_invert_y=false
+process/hdr_as_srgb=false
+process/hdr_clamp_exposure=false
+process/size_limit=0
+detect_3d/compress_to=1

binární
assets/textures/game_over/failure_10.png


+ 34 - 0
assets/textures/game_over/failure_10.png.import

@@ -0,0 +1,34 @@
+[remap]
+
+importer="texture"
+type="CompressedTexture2D"
+uid="uid://dnwoqdwr8u5md"
+path="res://.godot/imported/failure_10.png-003f2c51b527d697ae1d398d1d9e8af6.ctex"
+metadata={
+"vram_texture": false
+}
+
+[deps]
+
+source_file="res://assets/textures/game_over/failure_10.png"
+dest_files=["res://.godot/imported/failure_10.png-003f2c51b527d697ae1d398d1d9e8af6.ctex"]
+
+[params]
+
+compress/mode=0
+compress/high_quality=false
+compress/lossy_quality=0.7
+compress/hdr_compression=1
+compress/normal_map=0
+compress/channel_pack=0
+mipmaps/generate=false
+mipmaps/limit=-1
+roughness/mode=0
+roughness/src_normal=""
+process/fix_alpha_border=true
+process/premult_alpha=false
+process/normal_map_invert_y=false
+process/hdr_as_srgb=false
+process/hdr_clamp_exposure=false
+process/size_limit=0
+detect_3d/compress_to=1

binární
assets/textures/game_over/failure_11.png


+ 34 - 0
assets/textures/game_over/failure_11.png.import

@@ -0,0 +1,34 @@
+[remap]
+
+importer="texture"
+type="CompressedTexture2D"
+uid="uid://dk7spqxunogqr"
+path="res://.godot/imported/failure_11.png-fd2714a0880d540ccdfe52e2c0043d75.ctex"
+metadata={
+"vram_texture": false
+}
+
+[deps]
+
+source_file="res://assets/textures/game_over/failure_11.png"
+dest_files=["res://.godot/imported/failure_11.png-fd2714a0880d540ccdfe52e2c0043d75.ctex"]
+
+[params]
+
+compress/mode=0
+compress/high_quality=false
+compress/lossy_quality=0.7
+compress/hdr_compression=1
+compress/normal_map=0
+compress/channel_pack=0
+mipmaps/generate=false
+mipmaps/limit=-1
+roughness/mode=0
+roughness/src_normal=""
+process/fix_alpha_border=true
+process/premult_alpha=false
+process/normal_map_invert_y=false
+process/hdr_as_srgb=false
+process/hdr_clamp_exposure=false
+process/size_limit=0
+detect_3d/compress_to=1

binární
assets/textures/game_over/failure_2.png


+ 34 - 0
assets/textures/game_over/failure_2.png.import

@@ -0,0 +1,34 @@
+[remap]
+
+importer="texture"
+type="CompressedTexture2D"
+uid="uid://cpefd3ejowpm1"
+path="res://.godot/imported/failure_2.png-2e08bb24fd9cb5a35c3177809d530849.ctex"
+metadata={
+"vram_texture": false
+}
+
+[deps]
+
+source_file="res://assets/textures/game_over/failure_2.png"
+dest_files=["res://.godot/imported/failure_2.png-2e08bb24fd9cb5a35c3177809d530849.ctex"]
+
+[params]
+
+compress/mode=0
+compress/high_quality=false
+compress/lossy_quality=0.7
+compress/hdr_compression=1
+compress/normal_map=0
+compress/channel_pack=0
+mipmaps/generate=false
+mipmaps/limit=-1
+roughness/mode=0
+roughness/src_normal=""
+process/fix_alpha_border=true
+process/premult_alpha=false
+process/normal_map_invert_y=false
+process/hdr_as_srgb=false
+process/hdr_clamp_exposure=false
+process/size_limit=0
+detect_3d/compress_to=1

binární
assets/textures/game_over/failure_3.png


+ 34 - 0
assets/textures/game_over/failure_3.png.import

@@ -0,0 +1,34 @@
+[remap]
+
+importer="texture"
+type="CompressedTexture2D"
+uid="uid://csyxhb3cip37v"
+path="res://.godot/imported/failure_3.png-e3671e2f9539c864ab4687a876a76b9d.ctex"
+metadata={
+"vram_texture": false
+}
+
+[deps]
+
+source_file="res://assets/textures/game_over/failure_3.png"
+dest_files=["res://.godot/imported/failure_3.png-e3671e2f9539c864ab4687a876a76b9d.ctex"]
+
+[params]
+
+compress/mode=0
+compress/high_quality=false
+compress/lossy_quality=0.7
+compress/hdr_compression=1
+compress/normal_map=0
+compress/channel_pack=0
+mipmaps/generate=false
+mipmaps/limit=-1
+roughness/mode=0
+roughness/src_normal=""
+process/fix_alpha_border=true
+process/premult_alpha=false
+process/normal_map_invert_y=false
+process/hdr_as_srgb=false
+process/hdr_clamp_exposure=false
+process/size_limit=0
+detect_3d/compress_to=1

binární
assets/textures/game_over/failure_4.png


+ 34 - 0
assets/textures/game_over/failure_4.png.import

@@ -0,0 +1,34 @@
+[remap]
+
+importer="texture"
+type="CompressedTexture2D"
+uid="uid://c724uexjbodrv"
+path="res://.godot/imported/failure_4.png-83664a826df28299fa5f9711f807f1aa.ctex"
+metadata={
+"vram_texture": false
+}
+
+[deps]
+
+source_file="res://assets/textures/game_over/failure_4.png"
+dest_files=["res://.godot/imported/failure_4.png-83664a826df28299fa5f9711f807f1aa.ctex"]
+
+[params]
+
+compress/mode=0
+compress/high_quality=false
+compress/lossy_quality=0.7
+compress/hdr_compression=1
+compress/normal_map=0
+compress/channel_pack=0
+mipmaps/generate=false
+mipmaps/limit=-1
+roughness/mode=0
+roughness/src_normal=""
+process/fix_alpha_border=true
+process/premult_alpha=false
+process/normal_map_invert_y=false
+process/hdr_as_srgb=false
+process/hdr_clamp_exposure=false
+process/size_limit=0
+detect_3d/compress_to=1

binární
assets/textures/game_over/failure_5.png


+ 34 - 0
assets/textures/game_over/failure_5.png.import

@@ -0,0 +1,34 @@
+[remap]
+
+importer="texture"
+type="CompressedTexture2D"
+uid="uid://48pprrrgfe7d"
+path="res://.godot/imported/failure_5.png-e0b27dfe66556bb6350e278f5d001fdd.ctex"
+metadata={
+"vram_texture": false
+}
+
+[deps]
+
+source_file="res://assets/textures/game_over/failure_5.png"
+dest_files=["res://.godot/imported/failure_5.png-e0b27dfe66556bb6350e278f5d001fdd.ctex"]
+
+[params]
+
+compress/mode=0
+compress/high_quality=false
+compress/lossy_quality=0.7
+compress/hdr_compression=1
+compress/normal_map=0
+compress/channel_pack=0
+mipmaps/generate=false
+mipmaps/limit=-1
+roughness/mode=0
+roughness/src_normal=""
+process/fix_alpha_border=true
+process/premult_alpha=false
+process/normal_map_invert_y=false
+process/hdr_as_srgb=false
+process/hdr_clamp_exposure=false
+process/size_limit=0
+detect_3d/compress_to=1

binární
assets/textures/game_over/failure_6.png


+ 34 - 0
assets/textures/game_over/failure_6.png.import

@@ -0,0 +1,34 @@
+[remap]
+
+importer="texture"
+type="CompressedTexture2D"
+uid="uid://mlvqnk46xvvv"
+path="res://.godot/imported/failure_6.png-f738dbe78eca387f0b260a9a2b5b1f47.ctex"
+metadata={
+"vram_texture": false
+}
+
+[deps]
+
+source_file="res://assets/textures/game_over/failure_6.png"
+dest_files=["res://.godot/imported/failure_6.png-f738dbe78eca387f0b260a9a2b5b1f47.ctex"]
+
+[params]
+
+compress/mode=0
+compress/high_quality=false
+compress/lossy_quality=0.7
+compress/hdr_compression=1
+compress/normal_map=0
+compress/channel_pack=0
+mipmaps/generate=false
+mipmaps/limit=-1
+roughness/mode=0
+roughness/src_normal=""
+process/fix_alpha_border=true
+process/premult_alpha=false
+process/normal_map_invert_y=false
+process/hdr_as_srgb=false
+process/hdr_clamp_exposure=false
+process/size_limit=0
+detect_3d/compress_to=1

binární
assets/textures/game_over/failure_7.png


+ 34 - 0
assets/textures/game_over/failure_7.png.import

@@ -0,0 +1,34 @@
+[remap]
+
+importer="texture"
+type="CompressedTexture2D"
+uid="uid://ckmqguoahfdxh"
+path="res://.godot/imported/failure_7.png-3be13852e4bf516e3d46403fbb33dca0.ctex"
+metadata={
+"vram_texture": false
+}
+
+[deps]
+
+source_file="res://assets/textures/game_over/failure_7.png"
+dest_files=["res://.godot/imported/failure_7.png-3be13852e4bf516e3d46403fbb33dca0.ctex"]
+
+[params]
+
+compress/mode=0
+compress/high_quality=false
+compress/lossy_quality=0.7
+compress/hdr_compression=1
+compress/normal_map=0
+compress/channel_pack=0
+mipmaps/generate=false
+mipmaps/limit=-1
+roughness/mode=0
+roughness/src_normal=""
+process/fix_alpha_border=true
+process/premult_alpha=false
+process/normal_map_invert_y=false
+process/hdr_as_srgb=false
+process/hdr_clamp_exposure=false
+process/size_limit=0
+detect_3d/compress_to=1

binární
assets/textures/game_over/failure_8.png


+ 34 - 0
assets/textures/game_over/failure_8.png.import

@@ -0,0 +1,34 @@
+[remap]
+
+importer="texture"
+type="CompressedTexture2D"
+uid="uid://ni6mhofo4bcb"
+path="res://.godot/imported/failure_8.png-35f2fa20463a28bf45e4a0360f6d00e9.ctex"
+metadata={
+"vram_texture": false
+}
+
+[deps]
+
+source_file="res://assets/textures/game_over/failure_8.png"
+dest_files=["res://.godot/imported/failure_8.png-35f2fa20463a28bf45e4a0360f6d00e9.ctex"]
+
+[params]
+
+compress/mode=0
+compress/high_quality=false
+compress/lossy_quality=0.7
+compress/hdr_compression=1
+compress/normal_map=0
+compress/channel_pack=0
+mipmaps/generate=false
+mipmaps/limit=-1
+roughness/mode=0
+roughness/src_normal=""
+process/fix_alpha_border=true
+process/premult_alpha=false
+process/normal_map_invert_y=false
+process/hdr_as_srgb=false
+process/hdr_clamp_exposure=false
+process/size_limit=0
+detect_3d/compress_to=1

binární
assets/textures/game_over/failure_9.png


+ 34 - 0
assets/textures/game_over/failure_9.png.import

@@ -0,0 +1,34 @@
+[remap]
+
+importer="texture"
+type="CompressedTexture2D"
+uid="uid://buvi4nksxorx3"
+path="res://.godot/imported/failure_9.png-0d7b45d7dc2e4d410bae6f9c4f207b37.ctex"
+metadata={
+"vram_texture": false
+}
+
+[deps]
+
+source_file="res://assets/textures/game_over/failure_9.png"
+dest_files=["res://.godot/imported/failure_9.png-0d7b45d7dc2e4d410bae6f9c4f207b37.ctex"]
+
+[params]
+
+compress/mode=0
+compress/high_quality=false
+compress/lossy_quality=0.7
+compress/hdr_compression=1
+compress/normal_map=0
+compress/channel_pack=0
+mipmaps/generate=false
+mipmaps/limit=-1
+roughness/mode=0
+roughness/src_normal=""
+process/fix_alpha_border=true
+process/premult_alpha=false
+process/normal_map_invert_y=false
+process/hdr_as_srgb=false
+process/hdr_clamp_exposure=false
+process/size_limit=0
+detect_3d/compress_to=1

+ 40 - 0
export_presets.cfg

@@ -98,3 +98,43 @@ progressive_web_app/icon_144x144=""
 progressive_web_app/icon_180x180=""
 progressive_web_app/icon_512x512=""
 progressive_web_app/background_color=Color(0, 0, 0, 1)
+
+[preset.2]
+
+name="Linux/X11 (arm64)"
+platform="Linux/X11"
+runnable=true
+dedicated_server=false
+custom_features=""
+export_filter="all_resources"
+include_filter=""
+exclude_filter=""
+export_path="export/LastStandOfHumanity_linux_arm64.zip"
+encryption_include_filters=""
+encryption_exclude_filters=""
+encrypt_pck=false
+encrypt_directory=false
+
+[preset.2.options]
+
+custom_template/debug=""
+custom_template/release=""
+debug/export_console_wrapper=1
+binary_format/embed_pck=false
+texture_format/bptc=true
+texture_format/s3tc=true
+texture_format/etc=false
+texture_format/etc2=false
+binary_format/architecture="arm64"
+ssh_remote_deploy/enabled=false
+ssh_remote_deploy/host="drako@192.168.0.35"
+ssh_remote_deploy/port="22"
+ssh_remote_deploy/extra_args_ssh=""
+ssh_remote_deploy/extra_args_scp=""
+ssh_remote_deploy/run_script="#!/usr/bin/env bash
+export DISPLAY=:0
+unzip -o -q \"{temp_dir}/{archive_name}\" -d \"{temp_dir}\"
+\"{temp_dir}/{exe_name}\" {cmd_args}"
+ssh_remote_deploy/cleanup_script="#!/usr/bin/env bash
+kill $(pgrep -x -f \"{temp_dir}/{exe_name} {cmd_args}\")
+rm -rf \"{temp_dir}\""

+ 40 - 11
screens/game.gd

@@ -4,9 +4,12 @@ extends Node2D
 @onready var overlay: CanvasLayer = $Overlay
 @onready var transition: Transition = $Overlay/Transition
 @onready var spawn_timer: Timer = $Timer
+@onready var ui_root: Control = $UI/Root
+@onready var wave_label: Label = $UI/Root/WaveLabel
 
 @onready var main_menu: PackedScene = load("res://screens/main_menu.tscn")
 @onready var bot_scene: PackedScene = load("res://assets/scenes/bot.tscn")
+@onready var game_over_scene: PackedScene = load("res://assets/scenes/game_over.tscn")
 
 @onready var spawn_points: Array[Marker2D] = [
 	$EnemySpawns/EnemySpawn_1,
@@ -14,7 +17,20 @@ extends Node2D
 	$EnemySpawns/EnemySpawn_3,
 ]
 
+enum Phase {
+	PHASE_SETUP,
+	PHASE_COMBAT,
+	PHASE_LOOT,
+}
+
+var phase: Phase = Phase.PHASE_SETUP
+var waves_completed: int = 0:
+	set(new_value):
+		waves_completed = new_value
+		wave_label.text = "WAVE: %d" % (new_value + 1)
+
 func _ready() -> void:
+	waves_completed = 0
 	overlay.visible = true
 	transition.slide_out()
 	await transition.game_fully_visible
@@ -22,13 +38,16 @@ func _ready() -> void:
 
 func _process(_delta: float) -> void:
 	if Input.is_action_pressed("ui_cancel"):
-		var tree = get_tree()
-		transition.text = ""
-		tree.paused = true
-		transition.slide_in()
-		await transition.game_fully_hidden
-		tree.change_scene_to_packed(main_menu)
-		tree.paused = false
+		go_to_main_menu()
+		
+func go_to_main_menu() -> void:
+	var tree = get_tree()
+	transition.text = ""
+	tree.paused = true
+	transition.slide_in()
+	await transition.game_fully_hidden
+	tree.change_scene_to_packed(main_menu)
+	tree.paused = false
 		
 func spawn_bot() -> void:
 	var spawn = spawn_points.pick_random()
@@ -42,10 +61,20 @@ func _on_timer_timeout() -> void:
 func base_hit() -> void:
 	health_bar.health -= 1
 	if health_bar.health == 0:
-		spawn_timer.stop()
-		var foes = get_tree().get_nodes_in_group("foe")
-		for foe in foes:
-			foe.queue_free()
+		game_over()
+
+func game_over() -> void:
+	spawn_timer.stop()
+	var foes = get_tree().get_nodes_in_group("foe")
+	for foe in foes:
+		foe.queue_free()
+	
+	var gos: GameOver = game_over_scene.instantiate()
+	gos.message = "YOU DIED AFTER\nCOMPLETING %d WAVES!" % waves_completed
+	ui_root.add_child(gos)
+	await gos.closed
+	
+	go_to_main_menu()
 
 func _on_base_area_entered(area: Area2D) -> void:
 	if area.is_in_group("foe") || area.is_in_group("foe_weapons"):

+ 34 - 1
screens/game.tscn

@@ -1,10 +1,11 @@
-[gd_scene load_steps=10 format=3 uid="uid://c483fkssc36s"]
+[gd_scene load_steps=12 format=3 uid="uid://c483fkssc36s"]
 
 [ext_resource type="Script" path="res://screens/game.gd" id="1_4dd0q"]
 [ext_resource type="Texture2D" uid="uid://ceelbowk0q0rl" path="res://assets/textures/room/Light_Overlay.png" id="2_px5xi"]
 [ext_resource type="PackedScene" uid="uid://odwutyui6q5g" path="res://assets/scenes/health_bar.tscn" id="2_x77og"]
 [ext_resource type="PackedScene" uid="uid://c27ceu18q8eyr" path="res://assets/scenes/room.tscn" id="3_hm7l7"]
 [ext_resource type="PackedScene" uid="uid://ce8cu4romympf" path="res://assets/scenes/transition.tscn" id="4_yc6k4"]
+[ext_resource type="FontFile" uid="uid://cqtognhaksl7j" path="res://assets/fonts/Potra.ttf" id="5_6ktvk"]
 [ext_resource type="PackedScene" uid="uid://cbmr1tbvbheda" path="res://assets/scenes/survivor_spot.tscn" id="6_c1csp"]
 [ext_resource type="PackedScene" uid="uid://bw0opjv1ewa8b" path="res://assets/scenes/player_spawn_zone.tscn" id="7_k4x0x"]
 
@@ -12,6 +13,12 @@
 blend_mode = 1
 light_mode = 1
 
+[sub_resource type="LabelSettings" id="LabelSettings_acclg"]
+font = ExtResource("5_6ktvk")
+font_size = 38
+outline_size = 3
+outline_color = Color(0, 0, 0, 1)
+
 [sub_resource type="RectangleShape2D" id="RectangleShape2D_p2163"]
 size = Vector2(472, 288)
 
@@ -34,6 +41,32 @@ position = Vector2(640, 73)
 wait_time = 3.5
 autostart = true
 
+[node name="UI" type="CanvasLayer" parent="."]
+layer = 9
+
+[node name="Root" type="Control" parent="UI"]
+layout_mode = 3
+anchors_preset = 15
+anchor_right = 1.0
+anchor_bottom = 1.0
+grow_horizontal = 2
+grow_vertical = 2
+mouse_filter = 2
+
+[node name="WaveLabel" type="Label" parent="UI/Root"]
+layout_mode = 1
+anchors_preset = 2
+anchor_top = 1.0
+anchor_bottom = 1.0
+offset_left = 10.0
+offset_top = -61.0
+offset_right = 255.0
+offset_bottom = -10.0
+grow_vertical = 0
+text = "WAVE: 9999"
+label_settings = SubResource("LabelSettings_acclg")
+vertical_alignment = 2
+
 [node name="Overlay" type="CanvasLayer" parent="."]
 layer = 10
 visible = false