From f27937e6e9b6a7146dd09fc711d2d293ecf5abbf Mon Sep 17 00:00:00 2001 From: Daniel Weipert Date: Sun, 14 Apr 2024 21:49:20 +0200 Subject: update --- Scenes/Components/Teleport.tscn | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100644 Scenes/Components/Teleport.tscn (limited to 'Scenes/Components/Teleport.tscn') diff --git a/Scenes/Components/Teleport.tscn b/Scenes/Components/Teleport.tscn new file mode 100644 index 0000000..f84591b --- /dev/null +++ b/Scenes/Components/Teleport.tscn @@ -0,0 +1,32 @@ +[gd_scene load_steps=5 format=3 uid="uid://cv64e7fpdi2a2"] + +[ext_resource type="Script" path="res://Scenes/Components/Teleport.gd" id="1_ygag4"] +[ext_resource type="Texture2D" uid="uid://bxl3lqlm22eem" path="res://Assets/Stages/core_outdoor.png" id="2_xm2l1"] + +[sub_resource type="CircleShape2D" id="CircleShape2D_62iqj"] +radius = 8.0 + +[sub_resource type="CircleShape2D" id="CircleShape2D_jkjyl"] +radius = 8.0 + +[node name="Teleport" type="Node2D"] +script = ExtResource("1_ygag4") + +[node name="Enter" type="Area2D" parent="."] +collision_mask = 2 + +[node name="CollisionShape2D" type="CollisionShape2D" parent="Enter"] +shape = SubResource("CircleShape2D_62iqj") + +[node name="Leave" type="Area2D" parent="."] +collision_mask = 2 + +[node name="CollisionShape2D" type="CollisionShape2D" parent="Leave"] +shape = SubResource("CircleShape2D_jkjyl") + +[node name="Sprite2D" type="Sprite2D" parent="."] +texture = ExtResource("2_xm2l1") +region_enabled = true +region_rect = Rect2(448.349, 464.431, 15, 16) + +[connection signal="body_entered" from="Enter" to="." method="_on_body_entered"] -- cgit v1.2.3