Open
Description
Bevy version
0.16.0
What you did
Spawn a UI node directly under the user's cursor that changes its background color based on interaction state.
What went wrong
The frame that it spawns in, it has Interaction::None
despite being under the user's cursor, so it flashes that color for 1 frame and then becomes Interaction::Hover
the next frame.
Demonstration with colors changed for clarity:
2025-05-03.15-06-45.mp4
This seems to be because ui_focus_system
iterates over UiStack
to find hovered entities, but UiStack
is not updated for the frame until ui_stack_system
runs in PostUpdate
.
Metadata
Metadata
Assignees
Labels
Type
Projects
Status
Widget-ready