[gd_scene load_steps=12 format=3 uid="uid://b6piduuvusiix"] [ext_resource type="Texture2D" uid="uid://chrld8oybp4me" path="res://assets/bg-1-1.png" id="1_4h0ce"] [ext_resource type="Script" path="res://scripts/destroyblock.gd" id="1_a8383"] [ext_resource type="AudioStream" uid="uid://dkb0efnhs6mrj" path="res://assets/sounds/NES - Super Mario Bros - Sound Effects/Super Mario Bros 1 and 2(JP)/Break.wav" id="3_bsm87"] [sub_resource type="AtlasTexture" id="AtlasTexture_nbg0j"] atlas = ExtResource("1_4h0ce") region = Rect2(320, 144, 16, 16) [sub_resource type="SpriteFrames" id="SpriteFrames_r70hc"] animations = [{ "frames": [{ "duration": 1.0, "texture": SubResource("AtlasTexture_nbg0j") }], "loop": true, "name": &"default", "speed": 5.0 }] [sub_resource type="RectangleShape2D" id="RectangleShape2D_i07jg"] size = Vector2(16, 16) [sub_resource type="RectangleShape2D" id="RectangleShape2D_r8vfl"] size = Vector2(10, 1) [sub_resource type="Animation" id="Animation_la8ht"] length = 0.001 tracks/0/type = "value" tracks/0/imported = false tracks/0/enabled = true tracks/0/path = NodePath("CollisionShape2D:disabled") tracks/0/interp = 1 tracks/0/loop_wrap = true tracks/0/keys = { "times": PackedFloat32Array(0), "transitions": PackedFloat32Array(1), "update": 1, "values": [true] } tracks/1/type = "value" tracks/1/imported = false tracks/1/enabled = true tracks/1/path = NodePath("destroySound:playing") 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("AnimatedSprite2D: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_hu2np"] resource_name = "destroy" tracks/0/type = "value" tracks/0/imported = false tracks/0/enabled = true tracks/0/path = NodePath("CollisionShape2D:disabled") tracks/0/interp = 1 tracks/0/loop_wrap = true tracks/0/keys = { "times": PackedFloat32Array(0), "transitions": PackedFloat32Array(1), "update": 1, "values": [true] } tracks/1/type = "value" tracks/1/imported = false tracks/1/enabled = true tracks/1/path = NodePath("destroySound:playing") 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 = "method" tracks/2/imported = false tracks/2/enabled = true tracks/2/path = NodePath(".") tracks/2/interp = 1 tracks/2/loop_wrap = true tracks/2/keys = { "times": PackedFloat32Array(1), "transitions": PackedFloat32Array(1), "values": [{ "args": [], "method": &"queue_free" }] } tracks/3/type = "value" tracks/3/imported = false tracks/3/enabled = true tracks/3/path = NodePath("AnimatedSprite2D:visible") tracks/3/interp = 1 tracks/3/loop_wrap = true tracks/3/keys = { "times": PackedFloat32Array(0), "transitions": PackedFloat32Array(1), "update": 1, "values": [false] } [sub_resource type="Animation" id="Animation_4lptd"] resource_name = "idle" tracks/0/type = "value" tracks/0/imported = false tracks/0/enabled = true tracks/0/path = NodePath("CollisionShape2D:disabled") tracks/0/interp = 1 tracks/0/loop_wrap = true tracks/0/keys = { "times": PackedFloat32Array(0), "transitions": PackedFloat32Array(1), "update": 1, "values": [false] } tracks/1/type = "value" tracks/1/imported = false tracks/1/enabled = true tracks/1/path = NodePath("AnimatedSprite2D:visible") tracks/1/interp = 1 tracks/1/loop_wrap = true tracks/1/keys = { "times": PackedFloat32Array(0), "transitions": PackedFloat32Array(1), "update": 1, "values": [true] } [sub_resource type="AnimationLibrary" id="AnimationLibrary_55ebx"] _data = { "RESET": SubResource("Animation_la8ht"), "destroy": SubResource("Animation_hu2np"), "idle": SubResource("Animation_4lptd") } [node name="destroyblock" type="RigidBody2D"] gravity_scale = 0.0 script = ExtResource("1_a8383") [node name="AnimatedSprite2D" type="AnimatedSprite2D" parent="."] visible = false position = Vector2(8, -8) sprite_frames = SubResource("SpriteFrames_r70hc") [node name="CollisionShape2D" type="CollisionShape2D" parent="."] position = Vector2(8, -8) shape = SubResource("RectangleShape2D_i07jg") disabled = true [node name="activate" type="Area2D" parent="."] collision_mask = 2 [node name="CollisionShape2D" type="CollisionShape2D" parent="activate"] position = Vector2(8, 0.5) shape = SubResource("RectangleShape2D_r8vfl") [node name="destroySound" type="AudioStreamPlayer2D" parent="."] stream = ExtResource("3_bsm87") volume_db = 5.0 [node name="AnimationPlayer" type="AnimationPlayer" parent="."] libraries = { "": SubResource("AnimationLibrary_55ebx") } autoplay = "idle" [connection signal="body_entered" from="activate" to="." method="_on_activate_body_entered"]