From 420104f439c54a65b209f7e33c7dc8b7790d472a Mon Sep 17 00:00:00 2001 From: Logan Date: Sat, 24 Sep 2022 19:13:02 -0600 Subject: Defined inner and outer shapes and connected signals. --- scenes/basketball.tscn | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) (limited to 'scenes/basketball.tscn') diff --git a/scenes/basketball.tscn b/scenes/basketball.tscn index 75a5e60..9f06c73 100644 --- a/scenes/basketball.tscn +++ b/scenes/basketball.tscn @@ -26,10 +26,17 @@ shape = SubResource( 1 ) scale = Vector2( 5, 5 ) texture = ExtResource( 1 ) -[node name="Area2D" type="Area2D" parent="."] +[node name="OuterShape" type="Area2D" parent="."] -[node name="CollisionShape2D" type="CollisionShape2D" parent="Area2D"] +[node name="CollisionShape2D" type="CollisionShape2D" parent="OuterShape"] shape = SubResource( 3 ) -[connection signal="mouse_entered" from="Area2D" to="." method="_on_Area2D_mouse_entered"] -[connection signal="mouse_exited" from="Area2D" to="." method="_on_Area2D_mouse_exited"] +[node name="InnerShape" type="Area2D" parent="."] + +[node name="CollisionShape2D2" type="CollisionShape2D" parent="InnerShape"] +shape = SubResource( 1 ) + +[connection signal="mouse_entered" from="OuterShape" to="." method="on_OuterShape_mouse_entered"] +[connection signal="mouse_exited" from="OuterShape" to="." method="_on_OuterShape_mouse_exited"] +[connection signal="mouse_entered" from="InnerShape" to="." method="_on_InnerShape_mouse_entered"] +[connection signal="mouse_exited" from="InnerShape" to="." method="_on_InnerShape_mouse_exited"] -- cgit v1.2.3