[gd_scene load_steps=8 format=2]

[ext_resource path="res://sprites/minecart.png" type="Texture" id=1]
[ext_resource path="res://sprites/minecart_wheel.png" type="Texture" id=2]
[ext_resource path="res://scripts/minecart.gd" type="Script" id=3]

[sub_resource type="Animation" id=1]
resource_name = "fall"

[sub_resource type="Animation" id=2]
length = 0.8
loop = true
tracks/0/type = "value"
tracks/0/path = NodePath("body/wheel:rotation_degrees")
tracks/0/interp = 1
tracks/0/loop_wrap = true
tracks/0/imported = false
tracks/0/enabled = true
tracks/0/keys = {
"times": PoolRealArray( 0, 0.8 ),
"transitions": PoolRealArray( 1, 1 ),
"update": 0,
"values": [ 0.0, 360.0 ]
}
tracks/1/type = "value"
tracks/1/path = NodePath("body/wheel: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.5, 0.6 ),
"transitions": PoolRealArray( 1, 1, 1 ),
"update": 1,
"values": [ Vector2( 0, 68 ), Vector2( 0, 64 ), Vector2( 0, 68 ) ]
}

[sub_resource type="RectangleShape2D" id=3]
extents = Vector2( 104, 24 )

[sub_resource type="RectangleShape2D" id=4]
extents = Vector2( 104, 24 )

[node name="minecart" type="KinematicBody2D"]
script = ExtResource( 3 )

[node name="body" type="Sprite" parent="."]
position = Vector2( 0, -68 )
texture = ExtResource( 1 )

[node name="wheel" type="Sprite" parent="body"]
position = Vector2( 0, 68 )
texture = ExtResource( 2 )

[node name="AnimationPlayer" type="AnimationPlayer" parent="."]
anims/fall = SubResource( 1 )
anims/move = SubResource( 2 )

[node name="CollisionShape2D" type="CollisionShape2D" parent="."]
position = Vector2( 0, -93 )
shape = SubResource( 3 )

[node name="Tween" type="Tween" parent="."]

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

[node name="CollisionShape2D" type="CollisionShape2D" parent="activate"]
position = Vector2( 0, -144 )
shape = SubResource( 4 )
