-
Notifications
You must be signed in to change notification settings - Fork 0
/
Player.tscn
153 lines (142 loc) · 4.31 KB
/
Player.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
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
[gd_scene load_steps=25 format=2]
[ext_resource path="res://images/blow0.png" type="Texture" id=1]
[ext_resource path="res://images/recoil0.png" type="Texture" id=2]
[ext_resource path="res://images/recoil1.png" type="Texture" id=3]
[ext_resource path="res://images/stand1.png" type="Texture" id=4]
[ext_resource path="res://images/run12.png" type="Texture" id=5]
[ext_resource path="res://images/stand0.png" type="Texture" id=6]
[ext_resource path="res://images/fall0.png" type="Texture" id=7]
[ext_resource path="res://images/fall1.png" type="Texture" id=8]
[ext_resource path="res://images/jump0.png" type="Texture" id=9]
[ext_resource path="res://images/still.png" type="Texture" id=10]
[ext_resource path="res://Player.gd" type="Script" id=11]
[ext_resource path="res://images/run02.png" type="Texture" id=12]
[ext_resource path="res://images/run00.png" type="Texture" id=13]
[ext_resource path="res://images/run03.png" type="Texture" id=14]
[ext_resource path="res://images/run10.png" type="Texture" id=15]
[ext_resource path="res://images/jump1.png" type="Texture" id=16]
[ext_resource path="res://images/blow1.png" type="Texture" id=17]
[ext_resource path="res://images/run13.png" type="Texture" id=18]
[ext_resource path="res://images/run01.png" type="Texture" id=19]
[ext_resource path="res://images/run11.png" type="Texture" id=20]
[sub_resource type="SpriteFrames" id=1]
animations = [ {
"frames": [ ExtResource( 15 ), ExtResource( 20 ), ExtResource( 5 ), ExtResource( 18 ) ],
"loop": true,
"name": "run_right",
"speed": 5.0
}, {
"frames": [ ExtResource( 2 ) ],
"loop": true,
"name": "recoil_right",
"speed": 5.0
}, {
"frames": [ ExtResource( 3 ) ],
"loop": true,
"name": "recoil_left",
"speed": 5.0
}, {
"frames": [ ExtResource( 6 ) ],
"loop": true,
"name": "stand_left",
"speed": 5.0
}, {
"frames": [ ExtResource( 13 ), ExtResource( 19 ), ExtResource( 12 ), ExtResource( 14 ) ],
"loop": true,
"name": "run_left",
"speed": 5.0
}, {
"frames": [ ExtResource( 17 ) ],
"loop": true,
"name": "blow_right",
"speed": 5.0
}, {
"frames": [ ExtResource( 7 ), ExtResource( 8 ) ],
"loop": true,
"name": "die",
"speed": 5.0
}, {
"frames": [ ExtResource( 16 ) ],
"loop": true,
"name": "jump_right",
"speed": 5.0
}, {
"frames": [ ExtResource( 9 ) ],
"loop": true,
"name": "jump_left",
"speed": 5.0
}, {
"frames": [ ExtResource( 4 ) ],
"loop": true,
"name": "stand_right",
"speed": 5.0
}, {
"frames": [ ExtResource( 1 ) ],
"loop": true,
"name": "blow_left",
"speed": 5.0
}, {
"frames": [ ExtResource( 10 ) ],
"loop": true,
"name": "idle",
"speed": 5.0
} ]
[sub_resource type="RectangleShape2D" id=2]
extents = Vector2( 25, 30 )
[sub_resource type="Animation" id=3]
resource_name = "hurt"
length = 0.5
loop = true
tracks/0/type = "value"
tracks/0/path = NodePath("Sprite:modulate")
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": [ Color( 1, 1, 1, 1 ), Color( 0.486275, 0, 0, 1 ), Color( 1, 1, 1, 1 ) ]
}
[sub_resource type="Animation" id=4]
resource_name = "normal"
length = 0.001
tracks/0/type = "value"
tracks/0/path = NodePath("Sprite:modulate")
tracks/0/interp = 1
tracks/0/loop_wrap = true
tracks/0/imported = false
tracks/0/enabled = true
tracks/0/keys = {
"times": PoolRealArray( 0 ),
"transitions": PoolRealArray( 1 ),
"update": 0,
"values": [ Color( 1, 1, 1, 1 ) ]
}
[node name="Player" type="KinematicBody2D"]
position = Vector2( 400, 63.5 )
collision_mask = 2147483654
script = ExtResource( 11 )
__meta__ = {
"_edit_group_": true
}
[node name="Sprite" type="AnimatedSprite" parent="."]
scale = Vector2( 0.992588, 1 )
frames = SubResource( 1 )
animation = "idle"
[node name="CollisionShape" type="CollisionShape2D" parent="."]
visible = false
position = Vector2( 0, 4.5 )
shape = SubResource( 2 )
[node name="Trigger" type="Area2D" parent="."]
collision_layer = 0
collision_mask = 80
[node name="TriggerCollisionShape" type="CollisionShape2D" parent="Trigger"]
position = Vector2( 0, 4.5 )
shape = SubResource( 2 )
[node name="AnimationPlayer" type="AnimationPlayer" parent="."]
anims/hurt = SubResource( 3 )
anims/normal = SubResource( 4 )
[connection signal="area_entered" from="Trigger" to="." method="_on_Trigger_area_entered"]
[connection signal="body_entered" from="Trigger" to="." method="_on_Trigger_body_entered"]