summaryrefslogtreecommitdiff
path: root/Units/Default.tscn
blob: 1e33862c81caa57ca087e8cdb53f0e6e4c48dd7f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
[gd_scene load_steps=5 format=3 uid="uid://con1448x4e6fj"]

[ext_resource type="Script" path="res://Units/default.gd" id="1_kguyl"]
[ext_resource type="PackedScene" uid="uid://bj8j72hwnt6mo" path="res://animated_sprite.tscn" id="2_5hewh"]
[ext_resource type="SpriteFrames" uid="uid://diwyagjvsgq0i" path="res://Units/units_sprite_frames.tres" id="2_y5w2o"]

[sub_resource type="RectangleShape2D" id="RectangleShape2D_j6kqi"]
size = Vector2(4, 9)

[node name="Default" type="CharacterBody2D"]
collision_mask = 256
input_pickable = true
script = ExtResource("1_kguyl")

[node name="AnimatedSprite" parent="." instance=ExtResource("2_5hewh")]
texture_filter = 1
sprite_frames = ExtResource("2_y5w2o")
animation = &"walk"
centered = false
offset = Vector2(-3, -5)

[node name="NavigationShape" type="CollisionShape2D" parent="."]
position = Vector2(0, 0.5)
shape = SubResource("RectangleShape2D_j6kqi")

[node name="RayLeft" type="RayCast2D" parent="."]
position = Vector2(0, 4)
target_position = Vector2(-3, 0)
collision_mask = 258

[node name="RayRight" type="RayCast2D" parent="."]
position = Vector2(0, 4)
target_position = Vector2(4, 0)
collision_mask = 258

[connection signal="input_event" from="." to="." method="_on_input_event"]