explosion.tscn 3.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131
  1. [gd_scene load_steps=13 format=3 uid="uid://dg4lfkqrtedxg"]
  2. [ext_resource type="Texture2D" uid="uid://bgtpy7rkgpt5v" path="res://assets/textures/explosion/explosion_animation_1.png" id="1_co4ui"]
  3. [ext_resource type="Script" path="res://assets/scenes/explosion.gd" id="1_q2lxq"]
  4. [ext_resource type="Texture2D" uid="uid://21sqipoqnfox" path="res://assets/textures/explosion/explosion_animation_2.png" id="2_sifmb"]
  5. [ext_resource type="Texture2D" uid="uid://cfb5vxdx6ndt1" path="res://assets/textures/explosion/explosion_animation_3.png" id="3_42uc1"]
  6. [ext_resource type="Texture2D" uid="uid://cb5p6rrecjihx" path="res://assets/textures/explosion/explosion_animation_4.png" id="4_mq835"]
  7. [ext_resource type="Texture2D" uid="uid://cuxeht00edohj" path="res://assets/textures/explosion/explosion_animation_5.png" id="5_phsaf"]
  8. [ext_resource type="Texture2D" uid="uid://dftc3x7vfop46" path="res://assets/textures/explosion/explosion_animation_6.png" id="6_llvbn"]
  9. [ext_resource type="AudioStream" uid="uid://8lflu2km62jc" path="res://assets/audio/explosion_1.wav" id="8_x0t21"]
  10. [sub_resource type="SpriteFrames" id="SpriteFrames_yqenh"]
  11. animations = [{
  12. "frames": [{
  13. "duration": 1.0,
  14. "texture": ExtResource("1_co4ui")
  15. }, {
  16. "duration": 1.0,
  17. "texture": ExtResource("2_sifmb")
  18. }, {
  19. "duration": 1.0,
  20. "texture": ExtResource("3_42uc1")
  21. }, {
  22. "duration": 1.0,
  23. "texture": ExtResource("4_mq835")
  24. }, {
  25. "duration": 1.0,
  26. "texture": ExtResource("5_phsaf")
  27. }, {
  28. "duration": 1.0,
  29. "texture": ExtResource("6_llvbn")
  30. }],
  31. "loop": false,
  32. "name": &"default",
  33. "speed": 20.0
  34. }]
  35. [sub_resource type="Animation" id="Animation_3m7yr"]
  36. length = 0.001
  37. tracks/0/type = "value"
  38. tracks/0/imported = false
  39. tracks/0/enabled = true
  40. tracks/0/path = NodePath("AnimatedSprite2D:frame")
  41. tracks/0/interp = 1
  42. tracks/0/loop_wrap = true
  43. tracks/0/keys = {
  44. "times": PackedFloat32Array(0),
  45. "transitions": PackedFloat32Array(1),
  46. "update": 1,
  47. "values": [1]
  48. }
  49. tracks/1/type = "value"
  50. tracks/1/imported = false
  51. tracks/1/enabled = true
  52. tracks/1/path = NodePath("AudioStreamPlayer:volume_db")
  53. tracks/1/interp = 1
  54. tracks/1/loop_wrap = true
  55. tracks/1/keys = {
  56. "times": PackedFloat32Array(0),
  57. "transitions": PackedFloat32Array(1),
  58. "update": 0,
  59. "values": [-80.0]
  60. }
  61. [sub_resource type="Animation" id="Animation_03hgi"]
  62. resource_name = "explosion"
  63. length = 0.6
  64. tracks/0/type = "audio"
  65. tracks/0/imported = false
  66. tracks/0/enabled = true
  67. tracks/0/path = NodePath("AudioStreamPlayer")
  68. tracks/0/interp = 1
  69. tracks/0/loop_wrap = true
  70. tracks/0/keys = {
  71. "clips": [{
  72. "end_offset": 0.9,
  73. "start_offset": 0.19,
  74. "stream": ExtResource("8_x0t21")
  75. }],
  76. "times": PackedFloat32Array(0)
  77. }
  78. tracks/0/use_blend = false
  79. tracks/1/type = "value"
  80. tracks/1/imported = false
  81. tracks/1/enabled = true
  82. tracks/1/path = NodePath("AnimatedSprite2D:frame")
  83. tracks/1/interp = 1
  84. tracks/1/loop_wrap = true
  85. tracks/1/keys = {
  86. "times": PackedFloat32Array(0, 0.1, 0.2, 0.3, 0.4, 0.5),
  87. "transitions": PackedFloat32Array(1, 1, 1, 1, 1, 1),
  88. "update": 1,
  89. "values": [0, 1, 2, 3, 4, 5]
  90. }
  91. tracks/2/type = "value"
  92. tracks/2/imported = false
  93. tracks/2/enabled = true
  94. tracks/2/path = NodePath("AudioStreamPlayer:volume_db")
  95. tracks/2/interp = 1
  96. tracks/2/loop_wrap = true
  97. tracks/2/keys = {
  98. "times": PackedFloat32Array(0, 0.6),
  99. "transitions": PackedFloat32Array(1, 1),
  100. "update": 0,
  101. "values": [0.0, -80.0]
  102. }
  103. [sub_resource type="AnimationLibrary" id="AnimationLibrary_opklp"]
  104. _data = {
  105. "RESET": SubResource("Animation_3m7yr"),
  106. "explosion": SubResource("Animation_03hgi")
  107. }
  108. [node name="Explosion" type="Node2D"]
  109. script = ExtResource("1_q2lxq")
  110. [node name="AnimatedSprite2D" type="AnimatedSprite2D" parent="."]
  111. scale = Vector2(0.6, 0.6)
  112. sprite_frames = SubResource("SpriteFrames_yqenh")
  113. frame = 1
  114. [node name="AudioStreamPlayer" type="AudioStreamPlayer" parent="."]
  115. volume_db = -80.0
  116. [node name="AnimationPlayer" type="AnimationPlayer" parent="."]
  117. libraries = {
  118. "": SubResource("AnimationLibrary_opklp")
  119. }
  120. autoplay = "explosion"
  121. [connection signal="animation_finished" from="AnimationPlayer" to="." method="_on_animation_finished"]