capri/objects/spring/spring.tscn
2025-03-02 18:02:05 -05:00

75 lines
2.2 KiB
Text

[gd_scene load_steps=8 format=3 uid="uid://68lav5rke5ag"]
[ext_resource type="Script" path="res://objects/spring/spring.gd" id="1_05bif"]
[ext_resource type="Texture2D" uid="uid://bobpl8pwm216q" path="res://assets/textures/spring/spring.png" id="1_s1olr"]
[ext_resource type="AudioStream" uid="uid://b8q3dww80nicd" path="res://assets/audio/sfx/jump.wav" id="3_wq8v8"]
[sub_resource type="Animation" id="Animation_pa4d8"]
length = 0.001
tracks/0/type = "value"
tracks/0/imported = false
tracks/0/enabled = true
tracks/0/path = NodePath("Sprite2D:frame")
tracks/0/interp = 1
tracks/0/loop_wrap = true
tracks/0/keys = {
"times": PackedFloat32Array(0),
"transitions": PackedFloat32Array(1),
"update": 1,
"values": [0]
}
[sub_resource type="Animation" id="Animation_8kq4q"]
resource_name = "bounce"
length = 0.3
tracks/0/type = "value"
tracks/0/imported = false
tracks/0/enabled = true
tracks/0/path = NodePath("Sprite2D:frame")
tracks/0/interp = 0
tracks/0/loop_wrap = true
tracks/0/keys = {
"times": PackedFloat32Array(0, 0.0666667, 0.1, 0.133333, 0.166667),
"transitions": PackedFloat32Array(1, 1, 1, 1, 1),
"update": 1,
"values": [1, 2, 3, 2, 0]
}
[sub_resource type="AnimationLibrary" id="AnimationLibrary_2p5yk"]
_data = {
"RESET": SubResource("Animation_pa4d8"),
"bounce": SubResource("Animation_8kq4q")
}
[sub_resource type="RectangleShape2D" id="RectangleShape2D_c7407"]
size = Vector2(16, 11)
[node name="Spring" type="Node2D"]
script = ExtResource("1_05bif")
[node name="Sprite2D" type="Sprite2D" parent="."]
position = Vector2(0, -8)
texture = ExtResource("1_s1olr")
hframes = 4
[node name="AnimationPlayer" type="AnimationPlayer" parent="."]
unique_name_in_owner = true
libraries = {
"": SubResource("AnimationLibrary_2p5yk")
}
[node name="Area2D" type="Area2D" parent="."]
collision_mask = 16
[node name="CollisionShape2D" type="CollisionShape2D" parent="Area2D"]
position = Vector2(0, -5.5)
shape = SubResource("RectangleShape2D_c7407")
[node name="AudioStreamPlayer" type="AudioStreamPlayer" parent="."]
unique_name_in_owner = true
stream = ExtResource("3_wq8v8")
volume_db = -14.0
bus = &"Capri"
[connection signal="area_entered" from="Area2D" to="." method="_on_area_2d_area_entered"]
[connection signal="body_entered" from="Area2D" to="." method="_on_area_2d_body_entered"]