[gd_scene load_steps=11 format=2]

[ext_resource path="res://sprites/actors/player.png" type="Texture" id=1]
[ext_resource path="res://scripts/player.gd" type="Script" id=2]
[ext_resource path="res://sprites/items/club.png" type="Texture" id=3]

[sub_resource type="CircleShape2D" id=1]
radius = 15.2567

[sub_resource type="Animation" id=2]
length = 0.1
tracks/0/type = "value"
tracks/0/path = NodePath("body:frame")
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": 1,
"values": [ 0 ]
}
tracks/1/type = "value"
tracks/1/path = NodePath("body/weapon:position")
tracks/1/interp = 1
tracks/1/loop_wrap = true
tracks/1/imported = false
tracks/1/enabled = true
tracks/1/keys = {
"times": PoolRealArray( 0 ),
"transitions": PoolRealArray( 1 ),
"update": 0,
"values": [ Vector2( 40, -22 ) ]
}
tracks/2/type = "value"
tracks/2/path = NodePath("body/weapon:rotation_degrees")
tracks/2/interp = 1
tracks/2/loop_wrap = true
tracks/2/imported = false
tracks/2/enabled = true
tracks/2/keys = {
"times": PoolRealArray( 0 ),
"transitions": PoolRealArray( 1 ),
"update": 0,
"values": [ -43.9023 ]
}

[sub_resource type="Animation" id=3]
length = 0.4
loop = true
tracks/0/type = "value"
tracks/0/path = NodePath("body:frame")
tracks/0/interp = 1
tracks/0/loop_wrap = true
tracks/0/imported = false
tracks/0/enabled = true
tracks/0/keys = {
"times": PoolRealArray( 0, 0.1, 0.2, 0.3 ),
"transitions": PoolRealArray( 1, 1, 1, 1 ),
"update": 1,
"values": [ 6, 7, 8, 9 ]
}
tracks/1/type = "value"
tracks/1/path = NodePath("body/weapon:position")
tracks/1/interp = 1
tracks/1/loop_wrap = true
tracks/1/imported = false
tracks/1/enabled = true
tracks/1/keys = {
"times": PoolRealArray( 0, 0.1, 0.2, 0.3 ),
"transitions": PoolRealArray( 1, 1, 1, 1 ),
"update": 1,
"values": [ Vector2( 48.3173, -46.7783 ), Vector2( 48.3173, -38.7783 ), Vector2( 48.3173, -46.7783 ), Vector2( 48.3173, -38.7783 ) ]
}
tracks/2/type = "value"
tracks/2/path = NodePath("body/weapon:rotation_degrees")
tracks/2/interp = 1
tracks/2/loop_wrap = true
tracks/2/imported = false
tracks/2/enabled = true
tracks/2/keys = {
"times": PoolRealArray( 0, 0.1, 0.2, 0.3 ),
"transitions": PoolRealArray( 1, 1, 1, 1 ),
"update": 1,
"values": [ -56.6721, -56.6721, -67.184, -56.6721 ]
}

[sub_resource type="Animation" id=4]
resource_name = "atack"
length = 0.2
tracks/0/type = "value"
tracks/0/path = NodePath("body:frame")
tracks/0/interp = 1
tracks/0/loop_wrap = true
tracks/0/imported = false
tracks/0/enabled = true
tracks/0/keys = {
"times": PoolRealArray( 0, 0.1 ),
"transitions": PoolRealArray( 1, 1 ),
"update": 1,
"values": [ 2, 3 ]
}
tracks/1/type = "value"
tracks/1/path = NodePath("body/weapon:rotation_degrees")
tracks/1/interp = 1
tracks/1/loop_wrap = true
tracks/1/imported = false
tracks/1/enabled = true
tracks/1/keys = {
"times": PoolRealArray( 0, 0.1 ),
"transitions": PoolRealArray( 1, 1 ),
"update": 1,
"values": [ 169.256, -3.32788 ]
}
tracks/2/type = "value"
tracks/2/path = NodePath("body/weapon:position")
tracks/2/interp = 1
tracks/2/loop_wrap = true
tracks/2/imported = false
tracks/2/enabled = true
tracks/2/keys = {
"times": PoolRealArray( 0, 0.1 ),
"transitions": PoolRealArray( 1, 1 ),
"update": 1,
"values": [ Vector2( -7.68266, -102.778 ), Vector2( 56.3173, -38.7783 ) ]
}

[sub_resource type="Animation" id=5]
length = 0.1
tracks/0/type = "value"
tracks/0/path = NodePath("body:frame")
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": 1,
"values": [ 1 ]
}

[sub_resource type="Animation" id=6]
length = 0.4
loop = true
tracks/0/type = "value"
tracks/0/path = NodePath("body:frame")
tracks/0/interp = 1
tracks/0/loop_wrap = true
tracks/0/imported = false
tracks/0/enabled = true
tracks/0/keys = {
"times": PoolRealArray( 0, 0.1, 0.2, 0.3 ),
"transitions": PoolRealArray( 1, 1, 1, 1 ),
"update": 1,
"values": [ 12, 13, 14, 15 ]
}

[sub_resource type="CircleShape2D" id=7]
radius = 45.2209

[node name="player" type="KinematicBody2D"]
script = ExtResource( 2 )

[node name="body" type="Sprite" parent="."]
position = Vector2( -0.317337, -1.22168 )
texture = ExtResource( 1 )
offset = Vector2( 0, -62.286 )
vframes = 6
hframes = 6
frame = 9
region_rect = Rect2( 2.14102, -3.12601, 63.6552, 81.9324 )

[node name="weapon" type="Sprite" parent="body"]
visible = false
position = Vector2( 48.3173, -38.7783 )
rotation = -0.989115
texture = ExtResource( 3 )
offset = Vector2( 26, 0 )

[node name="CollisionShape2D" type="CollisionShape2D" parent="."]
position = Vector2( 9.51044, -7.79934 )
shape = SubResource( 1 )

[node name="AnimationPlayer" type="AnimationPlayer" parent="."]
autoplay = "armed_walk"
anims/armed_idle = SubResource( 2 )
anims/armed_walk = SubResource( 3 )
anims/atack = SubResource( 4 )
anims/unarmed_idle = SubResource( 5 )
anims/unarmed_walk = SubResource( 6 )

[node name="Camera2D" type="Camera2D" parent="."]
current = true
limit_left = 0
limit_top = 0
limit_right = 4096
limit_bottom = 2560

[node name="interract" type="Area2D" parent="."]
monitorable = false

[node name="CollisionShape2D" type="CollisionShape2D" parent="interract"]
position = Vector2( 14.7466, -50.7826 )
shape = SubResource( 7 )

[node name="weapon_time" type="Timer" parent="."]
wait_time = 0.2
one_shot = true
[connection signal="area_entered" from="interract" to="." method="_on_interract_area_entered"]
[connection signal="area_exited" from="interract" to="." method="_on_interract_area_exited"]
[connection signal="timeout" from="weapon_time" to="." method="_on_weapon_time_timeout"]
