I have a highlighter Area2D that snaps to the tilemap grid (think of a flashlight pointing to a specific tile), and I would like to have it detect which area is currently highlighted using the area_entered() and area_exited() signals:
# Highlighter.gd
extends Area2D
var highlighted_area
_on_Highlighter_area_entered(area):
highlighted_area = area
_on_Highlighter_area_exited(area):
highlighted_area = null
This is working as intended, except when I move from one area to an overlapping area. In that case the exiting signal fires but the entering signal for the adjacent (overlapping) area DOES NOT fire, hence highlighted_area will be stuck with null. See figure below:
Why is the enter signal not fired for overlapping areas? Any ideas how to get the signals to work properly?
