-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathCoin.tscn
52 lines (44 loc) · 1.55 KB
/
Coin.tscn
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
[gd_scene load_steps=8 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_2.png" type="Texture" id=3]
[ext_resource path="res://assets/coin/gold_1.png" type="Texture" id=4]
[sub_resource type="CircleShape2D" id=1]
radius = 44.0995
[sub_resource type="SpriteFrames" id=2]
animations = [ {
"frames": [ ExtResource( 4 ), ExtResource( 3 ), 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("anime coin: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.25, 0.5 ),
"transitions": PoolRealArray( 1, 1, 1 ),
"update": 0,
"values": [ Vector2( 0, 0 ), Vector2( -1.51984, -190.31 ), Vector2( -1.51984, -70.3096 ) ]
}
[node name="Coin Area" type="Area2D"]
collision_layer = 0
script = ExtResource( 1 )
[node name="CollisionShape2D" type="CollisionShape2D" parent="."]
shape = SubResource( 1 )
[node name="anime coin" type="AnimatedSprite" parent="."]
frames = SubResource( 2 )
animation = "spin"
frame = 2
playing = true
[node name="AnimationPlayer" type="AnimationPlayer" parent="."]
anims/bounce = SubResource( 3 )
[connection signal="body_entered" from="." to="." method="_on_coin_body_entered"]
[connection signal="animation_finished" from="AnimationPlayer" to="." method="_on_bounce_animation_finished"]