-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathCoin.tscn
More file actions
57 lines (48 loc) · 1.73 KB
/
Coin.tscn
File metadata and controls
57 lines (48 loc) · 1.73 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
[gd_scene load_steps=9 format=2]
[ext_resource path="res://Coin.gd" type="Script" id=1]
[ext_resource path="res://Assets/coin/gold_3.png" type="Texture" id=2]
[ext_resource path="res://Assets/coin/gold_1.png" type="Texture" id=3]
[ext_resource path="res://Assets/coin/gold_2.png" type="Texture" id=4]
[ext_resource path="res://Assets/sounds/powerUp2.ogg" type="AudioStream" id=5]
[sub_resource type="CircleShape2D" id=1]
radius = 50.04
[sub_resource type="SpriteFrames" id=2]
animations = [ {
"frames": [ ExtResource( 3 ), ExtResource( 4 ), ExtResource( 2 ) ],
"loop": true,
"name": "spin",
"speed": 5.0
} ]
[sub_resource type="Animation" id=3]
resource_name = "bounce"
length = 0.5
step = 0.05
tracks/0/type = "value"
tracks/0/path = NodePath("AnimatedSprite:position")
tracks/0/interp = 1
tracks/0/loop_wrap = true
tracks/0/imported = false
tracks/0/enabled = true
tracks/0/keys = {
"times": PoolRealArray( 0, 0.3, 0.5 ),
"transitions": PoolRealArray( 1, 1, 1 ),
"update": 0,
"values": [ Vector2( 0, 0 ), Vector2( 0, -213 ), Vector2( -1, -127 ) ]
}
[node name="Coin" type="Area2D"]
collision_layer = 0
script = ExtResource( 1 )
[node name="CollisionShape2D" type="CollisionShape2D" parent="."]
shape = SubResource( 1 )
[node name="AnimatedSprite" type="AnimatedSprite" parent="."]
frames = SubResource( 2 )
animation = "spin"
frame = 2
playing = true
[node name="AnimationPlayer" type="AnimationPlayer" parent="."]
anims/bounce = SubResource( 3 )
[node name="SoundCoinCollect" type="AudioStreamPlayer" parent="."]
stream = ExtResource( 5 )
volume_db = -5.0
[connection signal="body_entered" from="." to="." method="_on_Coin_body_entered"]
[connection signal="animation_finished" from="AnimationPlayer" to="." method="_on_AnimationPlayer_animation_finished"]