ChronoSpace/scenes/spaceShip/enemy/enemy.tscn
2025-08-02 12:27:49 +02:00

46 lines
1.7 KiB
Text

[gd_scene load_steps=8 format=3 uid="uid://bodpgjdjhfn4w"]
[ext_resource type="PackedScene" uid="uid://csacin2gx2tum" path="res://scenes/spaceShip/spaceShip.tscn" id="1_5w6ng"]
[ext_resource type="Script" uid="uid://djlqf2g8ho05r" path="res://scenes/spaceShip/enemy/enemy.gd" id="2_2erf0"]
[ext_resource type="Texture2D" uid="uid://cfwyw1sr6x2np" path="res://icon.svg" id="2_u13ds"]
[ext_resource type="PackedScene" uid="uid://k5fr6bfn6kkd" path="res://scenes/spaceShip/enemy/visionArea/visionArea.tscn" id="4_hybmu"]
[sub_resource type="RectangleShape2D" id="RectangleShape2D_2erf0"]
size = Vector2(112, 112)
[sub_resource type="RectangleShape2D" id="RectangleShape2D_u13ds"]
size = Vector2(112, 112)
[sub_resource type="CircleShape2D" id="CircleShape2D_hybmu"]
radius = 448.071
[node name="Enemy" groups=["enemy"] instance=ExtResource("1_5w6ng")]
modulate = Color(1, 0, 1, 1)
collision_layer = 36
collision_mask = 35
script = ExtResource("2_2erf0")
speed = 700
[node name="CollisionShape2D" parent="." index="0"]
shape = SubResource("RectangleShape2D_2erf0")
[node name="CollisionShape2D" parent="hurtArea" index="0"]
shape = SubResource("RectangleShape2D_u13ds")
[node name="Sprite2D" parent="." index="2"]
texture = ExtResource("2_u13ds")
[node name="VisionAreas" type="Node2D" parent="." index="5"]
[node name="VisionAreaStop" parent="VisionAreas" index="0" instance=ExtResource("4_hybmu")]
[node name="CollisionShape2D" parent="VisionAreas/VisionAreaStop" index="0"]
shape = SubResource("CircleShape2D_hybmu")
[node name="RayCast2D" type="RayCast2D" parent="." index="6"]
target_position = Vector2(0, -448)
[connection signal="hurt" from="hurtArea" to="." method="_on_hurt_area_hurt"]
[editable path="hurtArea"]
[editable path="VisionAreas/VisionAreaStop"]