-
Notifications
You must be signed in to change notification settings - Fork 0
/
Box.tscn
64 lines (52 loc) · 2.23 KB
/
Box.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
[gd_scene load_steps=11 format=2]
[ext_resource path="res://images/box.png" type="Texture" id=1]
[ext_resource path="res://images/shell.png" type="Texture" id=2]
[ext_resource path="res://images/small-shells.png" type="Texture" id=3]
[ext_resource path="res://images/spring.png" type="Texture" id=4]
[ext_resource path="res://images/big-shell.png" type="Texture" id=5]
[ext_resource path="res://Box.gd" type="Script" id=6]
[ext_resource path="res://Shell.tscn" type="PackedScene" id=7]
[ext_resource path="res://images/health.png" type="Texture" id=8]
[sub_resource type="SpriteFrames" id=1]
animations = [ {
"frames": [ ExtResource( 2 ), ExtResource( 3 ), ExtResource( 5 ), ExtResource( 4 ), ExtResource( 8 ) ],
"loop": true,
"name": "default",
"speed": 5.0
} ]
[sub_resource type="CapsuleShape2D" id=2]
radius = 10.7314
height = 44.8859
[node name="Box" type="RigidBody2D" groups=[
"heavy",
"target",
]]
z_index = 1
z_as_relative = false
script = ExtResource( 6 )
Shell = ExtResource( 7 )
[node name="CollisionPolygon2D" type="CollisionPolygon2D" parent="."]
position = Vector2( 0, -2 )
scale = Vector2( 0.063, 0.063 )
polygon = PoolVector2Array( -203.652, -271.332, -96.4444, -272.383, -96.4261, -311.874, 95.2381, -312.128, 95.2381, -273.189, 203.106, -273.434, 203.398, 270.991, 95.1389, 272.042, 94.5607, 310.2, -94.2023, 309.61, -95.0871, 271.858, -203.036, 271.858 )
[node name="Sprite" type="Sprite" parent="."]
scale = Vector2( 0.063, 0.063 )
texture = ExtResource( 1 )
[node name="Content" type="AnimatedSprite" parent="Sprite"]
modulate = Color( 0.776471, 0.776471, 0.776471, 1 )
position = Vector2( 0, -7 )
rotation = 0.207694
frames = SubResource( 1 )
[node name="PickArea" type="Area2D" parent="."]
[node name="CollisionShape2D" type="CollisionShape2D" parent="PickArea"]
scale = Vector2( 2.06014, -0.801646 )
shape = SubResource( 2 )
[node name="FallTimer" type="Timer" parent="."]
wait_time = 0.6
one_shot = true
autostart = true
[node name="PickTimer" type="Timer" parent="."]
wait_time = 0.06
[connection signal="body_entered" from="PickArea" to="." method="_on_PickArea_body_entered"]
[connection signal="timeout" from="FallTimer" to="." method="_on_FallTimer_timeout"]
[connection signal="timeout" from="PickTimer" to="." method="_on_PickTimer_timeout"]