From 0bb9d427e9474531caa1c091396a713aebac3cda Mon Sep 17 00:00:00 2001 From: Stefano Pigozzi Date: Sat, 13 Apr 2024 23:28:17 +0200 Subject: [PATCH] Connect debug print signal in `Connectable` --- behaviours/collectable.tscn | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/behaviours/collectable.tscn b/behaviours/collectable.tscn index 9b2a0ea..eb18932 100644 --- a/behaviours/collectable.tscn +++ b/behaviours/collectable.tscn @@ -8,7 +8,10 @@ radius = 16.4012 [node name="Collectable" type="Node2D"] script = ExtResource("1_p0pc3") -[node name="CollectArea" type="Area2D" parent="."] +[node name="MouseArea" type="Area2D" parent="."] -[node name="Shape" type="CollisionShape2D" parent="CollectArea"] +[node name="Shape" type="CollisionShape2D" parent="MouseArea"] shape = SubResource("CircleShape2D_su28r") + +[connection signal="collected" from="." to="." method="_on_collected"] +[connection signal="mouse_entered" from="MouseArea" to="." method="_on_mouse_area_mouse_entered"]