Podoboo.tscn 3.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586
  1. [gd_scene load_steps=13 format=3 uid="uid://cxdj1ea1rt1r4"]
  2. [ext_resource type="Texture2D" uid="uid://c67dr3ubb25yq" path="res://Assets/Sprites/Enemies/Podoboo.png" id="1_arivf"]
  3. [ext_resource type="Script" uid="uid://bha5utvbhxppl" path="res://Scripts/Classes/Entities/Enemies/Podoboo.gd" id="1_i2k1r"]
  4. [ext_resource type="Script" uid="uid://caq1qiwmy0mox" path="res://Scripts/Parts/BetterAnimatedSprite.gd" id="3_ct78r"]
  5. [ext_resource type="Script" uid="uid://cbal8ms2oe1ik" path="res://Scripts/Classes/Components/ResourceSetterNew.gd" id="4_31csk"]
  6. [ext_resource type="JSON" path="res://Assets/Sprites/Enemies/Podoboo.json" id="5_q2nhk"]
  7. [ext_resource type="Script" uid="uid://ctfbuoxtnnl0q" path="res://Scripts/Classes/Components/EditorPropertyExposer.gd" id="6_31csk"]
  8. [ext_resource type="Script" uid="uid://chj8hu207lrh" path="res://Scripts/Classes/Components/EnemyPlayerDetection.gd" id="7_jhnsj"]
  9. [ext_resource type="Script" uid="uid://c3gg32ivrlq8n" path="res://Scripts/Classes/Components/GibSpawner.gd" id="8_g8i2d"]
  10. [ext_resource type="Script" uid="uid://5octqlf4ohel" path="res://Scripts/Classes/Components/ScoreNoteSpawner.gd" id="9_g8i2d"]
  11. [sub_resource type="AtlasTexture" id="AtlasTexture_jhnsj"]
  12. atlas = ExtResource("1_arivf")
  13. region = Rect2(0, 0, 16, 16)
  14. [sub_resource type="SpriteFrames" id="SpriteFrames_g8i2d"]
  15. animations = [{
  16. "frames": [{
  17. "duration": 1.0,
  18. "texture": SubResource("AtlasTexture_jhnsj")
  19. }],
  20. "loop": true,
  21. "name": &"default",
  22. "speed": 5.0
  23. }]
  24. [sub_resource type="RectangleShape2D" id="RectangleShape2D_i2k1r"]
  25. size = Vector2(8, 8)
  26. [node name="Podoboo" type="Node2D" groups=["Enemies"]]
  27. script = ExtResource("1_i2k1r")
  28. [node name="Sprite" type="AnimatedSprite2D" parent="."]
  29. sprite_frames = SubResource("SpriteFrames_g8i2d")
  30. autoplay = "default"
  31. script = ExtResource("3_ct78r")
  32. do_offset = false
  33. metadata/_custom_type_script = "uid://caq1qiwmy0mox"
  34. [node name="ResourceSetterNew" type="Node" parent="Sprite" node_paths=PackedStringArray("node_to_affect", "property_node")]
  35. script = ExtResource("4_31csk")
  36. node_to_affect = NodePath("..")
  37. property_node = NodePath("../..")
  38. property_name = "sprite_frames"
  39. resource_json = ExtResource("5_q2nhk")
  40. metadata/_custom_type_script = "uid://cbal8ms2oe1ik"
  41. [node name="Hitbox" type="Area2D" parent="."]
  42. [node name="Shape" type="CollisionShape2D" parent="Hitbox"]
  43. visible = false
  44. shape = SubResource("RectangleShape2D_i2k1r")
  45. [node name="VisibleOnScreenEnabler2D" type="VisibleOnScreenEnabler2D" parent="."]
  46. rect = Rect2(-10, -9999, 20, 100000000)
  47. show_rect = false
  48. [node name="EditorPropertyExposer" type="Node" parent="."]
  49. script = ExtResource("6_31csk")
  50. properties = Array[String](["jump_delay"])
  51. [node name="Timer" type="Timer" parent="."]
  52. one_shot = true
  53. [node name="EnemyPlayerDetection" type="Node" parent="." node_paths=PackedStringArray("hitbox")]
  54. script = ExtResource("7_jhnsj")
  55. hitbox = NodePath("../Hitbox")
  56. metadata/_custom_type_script = "uid://chj8hu207lrh"
  57. [node name="GibSpawner" type="Node" parent="." node_paths=PackedStringArray("visuals")]
  58. script = ExtResource("8_g8i2d")
  59. visuals = NodePath("../Sprite")
  60. gib_type = 2
  61. metadata/_custom_type_script = "uid://c3gg32ivrlq8n"
  62. [node name="ScoreNoteSpawner" type="Node" parent="."]
  63. script = ExtResource("9_g8i2d")
  64. add_score = true
  65. metadata/_custom_type_script = "uid://5octqlf4ohel"
  66. [connection signal="killed" from="." to="GibSpawner" method="summon_gib" binds= [0, true]]
  67. [connection signal="killed" from="." to="ScoreNoteSpawner" method="spawn_note" binds= [500]]
  68. [connection signal="invincible_player_hit" from="EnemyPlayerDetection" to="." method="die" unbinds=1]
  69. [connection signal="player_hit" from="EnemyPlayerDetection" to="." method="damage_player"]
  70. [connection signal="player_stomped_on" from="EnemyPlayerDetection" to="." method="damage_player"]