summaryrefslogtreecommitdiff
path: root/Units/Miner.tscn
diff options
context:
space:
mode:
Diffstat (limited to 'Units/Miner.tscn')
-rw-r--r--Units/Miner.tscn222
1 files changed, 222 insertions, 0 deletions
diff --git a/Units/Miner.tscn b/Units/Miner.tscn
new file mode 100644
index 0000000..28ebac7
--- /dev/null
+++ b/Units/Miner.tscn
@@ -0,0 +1,222 @@
+[gd_scene load_steps=9 format=3 uid="uid://i5s3jsgofbg4"]
+
+[ext_resource type="Script" path="res://Units/miner.gd" id="1_x7v12"]
+[ext_resource type="PackedScene" uid="uid://bj8j72hwnt6mo" path="res://animated_sprite.tscn" id="2_47g82"]
+[ext_resource type="SpriteFrames" uid="uid://diwyagjvsgq0i" path="res://Units/units_sprite_frames.tres" id="3_fgjfm"]
+[ext_resource type="PackedScene" uid="uid://bi2ndv451jpww" path="res://animation_player.tscn" id="4_1ydpk"]
+
+[sub_resource type="RectangleShape2D" id="RectangleShape2D_j6kqi"]
+size = Vector2(4, 10)
+
+[sub_resource type="Animation" id="Animation_glqtg"]
+resource_name = "mine"
+length = 1.8
+loop_mode = 1
+step = 0.1
+tracks/0/type = "value"
+tracks/0/imported = false
+tracks/0/enabled = true
+tracks/0/path = NodePath("AnimatedSprite:animation")
+tracks/0/interp = 1
+tracks/0/loop_wrap = true
+tracks/0/keys = {
+"times": PackedFloat32Array(0),
+"transitions": PackedFloat32Array(1),
+"update": 1,
+"values": [&"mine"]
+}
+tracks/1/type = "value"
+tracks/1/imported = false
+tracks/1/enabled = true
+tracks/1/path = NodePath("AnimatedSprite:frame")
+tracks/1/interp = 1
+tracks/1/loop_wrap = true
+tracks/1/keys = {
+"times": PackedFloat32Array(0, 0.1, 0.2, 0.3, 0.4, 0.5, 0.6, 0.7, 0.8, 0.9, 1, 1.1, 1.2, 1.3, 1.4, 1.5, 1.6, 1.7),
+"transitions": PackedFloat32Array(1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1),
+"update": 1,
+"values": [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17]
+}
+tracks/2/type = "value"
+tracks/2/imported = false
+tracks/2/enabled = true
+tracks/2/path = NodePath("PickaxePolygon:position")
+tracks/2/interp = 1
+tracks/2/loop_wrap = true
+tracks/2/keys = {
+"times": PackedFloat32Array(0, 0.1, 0.2, 1.6, 1.7),
+"transitions": PackedFloat32Array(1, 1, 1, 1, 1),
+"update": 1,
+"values": [Vector2(3, -1), Vector2(0, 0), Vector2(-1, 0), Vector2(-3, -1), Vector2(-2, -2)]
+}
+tracks/3/type = "value"
+tracks/3/imported = false
+tracks/3/enabled = true
+tracks/3/path = NodePath("PickaxePolygon:rotation")
+tracks/3/interp = 1
+tracks/3/loop_wrap = true
+tracks/3/keys = {
+"times": PackedFloat32Array(0, 0.1, 0.2, 1.6, 1.7),
+"transitions": PackedFloat32Array(1, 1, 1, 1, 1),
+"update": 1,
+"values": [-1.5708, 0.0, 1.5708, 0.785398, 0.0]
+}
+tracks/4/type = "method"
+tracks/4/imported = false
+tracks/4/enabled = true
+tracks/4/path = NodePath(".")
+tracks/4/interp = 1
+tracks/4/loop_wrap = true
+tracks/4/keys = {
+"times": PackedFloat32Array(0, 0.1, 0.2, 0.3, 0.4, 0.5, 0.6, 0.7, 0.8, 0.9, 1, 1.1, 1.2, 1.3, 1.4, 1.5, 1.6, 1.7, 1.8),
+"transitions": PackedFloat32Array(1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1),
+"values": [{
+"args": [],
+"method": &"mine"
+}, {
+"args": [],
+"method": &"mine"
+}, {
+"args": [],
+"method": &"mine"
+}, {
+"args": [],
+"method": &"mine"
+}, {
+"args": [],
+"method": &"mine"
+}, {
+"args": [],
+"method": &"mine"
+}, {
+"args": [],
+"method": &"mine"
+}, {
+"args": [],
+"method": &"mine"
+}, {
+"args": [],
+"method": &"mine"
+}, {
+"args": [],
+"method": &"mine"
+}, {
+"args": [],
+"method": &"mine"
+}, {
+"args": [],
+"method": &"mine"
+}, {
+"args": [],
+"method": &"mine"
+}, {
+"args": [],
+"method": &"mine"
+}, {
+"args": [],
+"method": &"mine"
+}, {
+"args": [],
+"method": &"mine"
+}, {
+"args": [],
+"method": &"mine"
+}, {
+"args": [],
+"method": &"mine"
+}, {
+"args": [],
+"method": &"mine"
+}]
+}
+
+[sub_resource type="Animation" id="Animation_2xcaf"]
+length = 0.001
+tracks/0/type = "value"
+tracks/0/imported = false
+tracks/0/enabled = true
+tracks/0/path = NodePath("AnimatedSprite:animation")
+tracks/0/interp = 1
+tracks/0/loop_wrap = true
+tracks/0/keys = {
+"times": PackedFloat32Array(0),
+"transitions": PackedFloat32Array(1),
+"update": 1,
+"values": [&"mine"]
+}
+tracks/1/type = "value"
+tracks/1/imported = false
+tracks/1/enabled = true
+tracks/1/path = NodePath("AnimatedSprite:frame")
+tracks/1/interp = 1
+tracks/1/loop_wrap = true
+tracks/1/keys = {
+"times": PackedFloat32Array(0),
+"transitions": PackedFloat32Array(1),
+"update": 1,
+"values": [1]
+}
+tracks/2/type = "value"
+tracks/2/imported = false
+tracks/2/enabled = true
+tracks/2/path = NodePath("PickaxePolygon:position")
+tracks/2/interp = 1
+tracks/2/loop_wrap = true
+tracks/2/keys = {
+"times": PackedFloat32Array(0),
+"transitions": PackedFloat32Array(1),
+"update": 0,
+"values": [Vector2(0, 0)]
+}
+tracks/3/type = "value"
+tracks/3/imported = false
+tracks/3/enabled = true
+tracks/3/path = NodePath("PickaxePolygon:rotation")
+tracks/3/interp = 1
+tracks/3/loop_wrap = true
+tracks/3/keys = {
+"times": PackedFloat32Array(0),
+"transitions": PackedFloat32Array(1),
+"update": 0,
+"values": [0.0]
+}
+
+[sub_resource type="AnimationLibrary" id="AnimationLibrary_1jt7m"]
+_data = {
+"RESET": SubResource("Animation_2xcaf"),
+"mine": SubResource("Animation_glqtg")
+}
+
+[node name="Miner" type="CharacterBody2D"]
+collision_mask = 256
+script = ExtResource("1_x7v12")
+
+[node name="AnimatedSprite" parent="." instance=ExtResource("2_47g82")]
+texture_filter = 1
+sprite_frames = ExtResource("3_fgjfm")
+animation = &"mine"
+frame = 1
+centered = false
+offset = Vector2(-7, -8)
+
+[node name="NavigationShape" type="CollisionShape2D" parent="."]
+position = Vector2(-1, 0)
+shape = SubResource("RectangleShape2D_j6kqi")
+
+[node name="RayGround" type="RayCast2D" parent="."]
+target_position = Vector2(7, 7)
+collision_mask = 256
+
+[node name="RayForward" type="RayCast2D" parent="."]
+target_position = Vector2(8, 0)
+collision_mask = 256
+
+[node name="AnimationPlayer" parent="." instance=ExtResource("4_1ydpk")]
+deterministic = true
+libraries = {
+"": SubResource("AnimationLibrary_1jt7m")
+}
+
+[node name="PickaxePolygon" type="Polygon2D" parent="."]
+color = Color(1, 1, 1, 0)
+polygon = PackedVector2Array(-1, -8, -1, -4, 2, -4, 2, -3, 3, -3, 3, -1, 7, -1, 7, -6, 7, -8, 5, -8)