test_game/scenes/slime.tscn

81 lines
2.3 KiB
Text
Raw Normal View History

2025-02-27 23:50:12 +01:00
[gd_scene load_steps=10 format=3 uid="uid://couldn2p7ji40"]
[ext_resource type="Texture2D" uid="uid://bl53gpvg5mh1y" path="res://assets/sprites/slime_green.png" id="1_0d7ny"]
[ext_resource type="Script" path="res://scripts/slime.gd" id="1_yja1u"]
[ext_resource type="PackedScene" uid="uid://c1mg68v18w4v" path="res://scenes/kill_zone.tscn" id="2_4sy8s"]
[sub_resource type="AtlasTexture" id="AtlasTexture_fkx3u"]
atlas = ExtResource("1_0d7ny")
region = Rect2(0, 24, 24, 24)
[sub_resource type="AtlasTexture" id="AtlasTexture_81u4a"]
atlas = ExtResource("1_0d7ny")
region = Rect2(24, 24, 24, 24)
[sub_resource type="AtlasTexture" id="AtlasTexture_vnwch"]
atlas = ExtResource("1_0d7ny")
region = Rect2(48, 24, 24, 24)
[sub_resource type="AtlasTexture" id="AtlasTexture_tnh43"]
atlas = ExtResource("1_0d7ny")
region = Rect2(72, 24, 24, 24)
[sub_resource type="SpriteFrames" id="SpriteFrames_ck5td"]
animations = [{
"frames": [{
"duration": 1.0,
"texture": SubResource("AtlasTexture_fkx3u")
}, {
"duration": 1.0,
"texture": SubResource("AtlasTexture_81u4a")
}, {
"duration": 1.0,
"texture": SubResource("AtlasTexture_vnwch")
}, {
"duration": 1.0,
"texture": SubResource("AtlasTexture_tnh43")
}],
"loop": true,
"name": &"idle",
"speed": 10.0
}]
[sub_resource type="RectangleShape2D" id="RectangleShape2D_e6ink"]
size = Vector2(10, 12)
[node name="Slime" type="Node2D"]
script = ExtResource("1_yja1u")
[node name="AnimatedSprite2D" type="AnimatedSprite2D" parent="."]
2025-03-03 22:57:23 +01:00
position = Vector2(-1, 0)
2025-02-27 23:50:12 +01:00
sprite_frames = SubResource("SpriteFrames_ck5td")
animation = &"idle"
autoplay = "idle"
frame_progress = 0.99564
[node name="KillZone" parent="." instance=ExtResource("2_4sy8s")]
2025-03-03 22:57:23 +01:00
position = Vector2(-1, 0)
2025-02-27 23:50:12 +01:00
[node name="CollisionShape2D" type="CollisionShape2D" parent="KillZone"]
position = Vector2(0, 6)
shape = SubResource("RectangleShape2D_e6ink")
[node name="RayCastRight" type="RayCast2D" parent="."]
position = Vector2(0, 6)
target_position = Vector2(12, 0)
[node name="RayCastLeft" type="RayCast2D" parent="."]
position = Vector2(0, 6)
rotation = -0.00269656
target_position = Vector2(-12, 0)
2025-03-03 22:57:23 +01:00
[node name="RayCastTopLeft" type="RayCast2D" parent="."]
position = Vector2(-5, 0)
target_position = Vector2(0, -7)
collision_mask = 2
[node name="RayCastTopRight" type="RayCast2D" parent="."]
position = Vector2(3, 0)
target_position = Vector2(0, -7)
collision_mask = 2