1
Fork 0
mirror of https://github.com/Steffo99/hella-farm.git synced 2024-11-24 17:14:23 +00:00
hella-farm/entities/sheep.tscn

118 lines
4.1 KiB
Text
Raw Normal View History

2024-04-15 20:20:13 +00:00
[gd_scene load_steps=15 format=3 uid="uid://bc2bm8lbol18w"]
2024-04-13 14:38:05 +00:00
2024-04-14 03:13:37 +00:00
[ext_resource type="Script" path="res://entities/sheep.gd" id="1_4dmll"]
2024-04-15 03:43:15 +00:00
[ext_resource type="Texture2D" uid="uid://iljp5yn3ehfk" path="res://entities/sheep_left.png" id="2_t13f5"]
2024-04-14 03:13:37 +00:00
[ext_resource type="PackedScene" uid="uid://bvrxvrjlo5130" path="res://behaviours/move_towards_mouse.tscn" id="2_tfd2i"]
2024-04-15 03:43:15 +00:00
[ext_resource type="PackedScene" uid="uid://bxbjfev0lhwws" path="res://behaviours/sprite_left_right.tscn" id="2_xbkrm"]
2024-04-14 05:20:53 +00:00
[ext_resource type="PackedScene" uid="uid://dijcjahkddudv" path="res://behaviours/draggable.tscn" id="3_8ku7r"]
2024-04-15 03:43:15 +00:00
[ext_resource type="Texture2D" uid="uid://cxtmas4g0v6en" path="res://entities/sheep_right.png" id="4_5qoof"]
2024-04-14 20:03:59 +00:00
[ext_resource type="AudioStream" uid="uid://buxgivpkh8dyl" path="res://entities/drop.wav" id="4_nxjnl"]
[ext_resource type="AudioStream" uid="uid://bmfscpnugaejk" path="res://entities/sheep_drag.wav" id="4_oalqu"]
[ext_resource type="PackedScene" uid="uid://dfdr3e32lohq" path="res://behaviours/edible.tscn" id="6_3odsh"]
2024-04-13 14:38:05 +00:00
[sub_resource type="CircleShape2D" id="CircleShape2D_c5tcn"]
2024-04-15 03:43:15 +00:00
radius = 8.0
2024-04-13 14:38:05 +00:00
2024-04-15 20:20:13 +00:00
[sub_resource type="Animation" id="Animation_lxieb"]
resource_name = "wobble"
length = 3.0
loop_mode = 1
step = 0.5
tracks/0/type = "value"
tracks/0/imported = false
tracks/0/enabled = true
tracks/0/path = NodePath("Sprite:rotation")
tracks/0/interp = 2
tracks/0/loop_wrap = true
tracks/0/keys = {
"times": PackedFloat32Array(0, 0.5, 1.5, 2, 3),
"transitions": PackedFloat32Array(1, 1, 1, 1, 1),
"update": 0,
"values": [0.0, -0.261799, 0.0, 0.261799, 0.0]
}
[sub_resource type="Animation" id="Animation_gokbg"]
length = 0.001
tracks/0/type = "value"
tracks/0/imported = false
tracks/0/enabled = true
tracks/0/path = NodePath("Sprite:rotation")
tracks/0/interp = 1
tracks/0/loop_wrap = true
tracks/0/keys = {
"times": PackedFloat32Array(0),
"transitions": PackedFloat32Array(1),
"update": 0,
"values": [0.0]
}
[sub_resource type="Animation" id="Animation_s7ekl"]
resource_name = "shake"
length = 0.5
loop_mode = 1
step = 0.05
tracks/0/type = "value"
tracks/0/imported = false
tracks/0/enabled = true
tracks/0/path = NodePath("Sprite:position")
tracks/0/interp = 1
tracks/0/loop_wrap = true
tracks/0/keys = {
"times": PackedFloat32Array(0, 0.05, 0.1, 0.15, 0.2, 0.25, 0.3, 0.35, 0.4, 0.45, 0.5),
"transitions": PackedFloat32Array(1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1),
"update": 1,
"values": [Vector2(0, 0), Vector2(1, 1), Vector2(-1, -1), Vector2(-1, 0), Vector2(1, -1), Vector2(-1, 1), Vector2(1, 1), Vector2(1, 0), Vector2(-1, -1), Vector2(1, 0), Vector2(0, -1)]
}
[sub_resource type="AnimationLibrary" id="AnimationLibrary_6mutq"]
_data = {
"RESET": SubResource("Animation_gokbg"),
"shake": SubResource("Animation_s7ekl"),
"wobble": SubResource("Animation_lxieb")
}
2024-04-14 03:13:37 +00:00
[node name="Sheep" type="CharacterBody2D"]
2024-04-14 18:53:45 +00:00
collision_layer = 8
collision_mask = 14
2024-04-14 03:13:37 +00:00
script = ExtResource("1_4dmll")
2024-04-13 14:38:05 +00:00
2024-04-15 03:43:15 +00:00
[node name="Sprite" parent="." instance=ExtResource("2_xbkrm")]
2024-04-15 20:20:13 +00:00
position = Vector2(1, 1)
2024-04-15 03:43:15 +00:00
scale = Vector2(2, 2)
texture = ExtResource("2_t13f5")
left_texture = ExtResource("2_t13f5")
right_texture = ExtResource("4_5qoof")
[node name="Shape" type="CollisionShape2D" parent="."]
2024-04-15 03:43:15 +00:00
scale = Vector2(3, 3)
shape = SubResource("CircleShape2D_c5tcn")
2024-04-14 03:13:37 +00:00
[node name="MoveTowardsMouse" parent="." instance=ExtResource("2_tfd2i")]
scale = Vector2(30, 30)
2024-04-15 03:43:15 +00:00
speed = -30.0
2024-04-14 03:13:37 +00:00
can_detach = true
2024-04-14 05:20:53 +00:00
[node name="Draggable" parent="." instance=ExtResource("3_8ku7r")]
2024-04-15 03:43:15 +00:00
scale = Vector2(3, 3)
2024-04-14 05:20:53 +00:00
2024-04-14 20:03:59 +00:00
[node name="DragSound" type="AudioStreamPlayer2D" parent="Draggable"]
scale = Vector2(0.5, 0.5)
stream = ExtResource("4_oalqu")
[node name="DropSound" type="AudioStreamPlayer2D" parent="Draggable"]
scale = Vector2(0.5, 0.5)
stream = ExtResource("4_nxjnl")
[node name="Edible" parent="." instance=ExtResource("6_3odsh")]
tag = &"Sheep"
2024-04-15 20:20:13 +00:00
[node name="Animator" type="AnimationPlayer" parent="."]
libraries = {
"": SubResource("AnimationLibrary_6mutq")
}
2024-04-14 03:13:37 +00:00
[connection signal="move" from="MoveTowardsMouse" to="." method="_on_move"]
2024-04-14 20:03:59 +00:00
[connection signal="dragged" from="Draggable" to="." method="_on_draggable_dragged"]
[connection signal="dropped" from="Draggable" to="." method="_on_draggable_dropped"]
[connection signal="move" from="Draggable" to="." method="_on_drag_move"]