summaryrefslogtreecommitdiff
path: root/Towers/Tower.tscn
diff options
context:
space:
mode:
Diffstat (limited to 'Towers/Tower.tscn')
-rw-r--r--Towers/Tower.tscn15
1 files changed, 14 insertions, 1 deletions
diff --git a/Towers/Tower.tscn b/Towers/Tower.tscn
index dfb2364..4177a3a 100644
--- a/Towers/Tower.tscn
+++ b/Towers/Tower.tscn
@@ -1,13 +1,17 @@
-[gd_scene load_steps=5 format=3 uid="uid://by1x56w21o165"]
+[gd_scene load_steps=7 format=3 uid="uid://by1x56w21o165"]
[ext_resource type="Script" path="res://Towers/Tower.gd" id="1_axo1d"]
[ext_resource type="Texture2D" uid="uid://b1b18rd0tqbar" path="res://core_outdoor.png" id="1_mrep8"]
+[ext_resource type="PackedScene" uid="uid://cqktpc8c7ecn3" path="res://Game/Selection/SelectableArea.tscn" id="3_57d5u"]
[sub_resource type="RectangleShape2D" id="RectangleShape2D_atm5x"]
size = Vector2(31, 31)
[sub_resource type="CircleShape2D" id="CircleShape2D_qa8kt"]
+[sub_resource type="RectangleShape2D" id="RectangleShape2D_312i7"]
+size = Vector2(32, 32)
+
[node name="Tower" type="StaticBody2D"]
y_sort_enabled = true
collision_layer = 4
@@ -38,9 +42,18 @@ shape = SubResource("CircleShape2D_qa8kt")
[node name="ShootCooldown" type="Timer" parent="."]
one_shot = true
+[node name="SelectableArea" parent="." instance=ExtResource("3_57d5u")]
+
+[node name="CollisionShape2D" type="CollisionShape2D" parent="SelectableArea"]
+position = Vector2(16, 16)
+shape = SubResource("RectangleShape2D_312i7")
+
[connection signal="input_event" from="." to="." method="_on_input_event"]
[connection signal="mouse_entered" from="." to="." method="_on_mouse_entered"]
[connection signal="mouse_exited" from="." to="." method="_on_mouse_exited"]
[connection signal="tree_exiting" from="." to="." method="_on_tree_exiting"]
[connection signal="body_entered" from="Range" to="." method="_on_range_body_entered"]
[connection signal="body_exited" from="Range" to="." method="_on_range_body_exited"]
+[connection signal="hover_enter" from="SelectableArea" to="." method="_on_selectable_area_hover_enter"]
+[connection signal="hover_exit" from="SelectableArea" to="." method="_on_selectable_area_hover_exit"]
+[connection signal="select" from="SelectableArea" to="." method="_on_selectable_area_select"]