You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If you have multiple sprites overlapping at different z in 2d ortho and they are Pickable with should_block_lower set to false, I used to get multiple Pointer Click for each one. With the recent change to hit ordering (#14862), I now only get the top-most Pointer Click. It seems like should_block_lower is not being respected.
The text was updated successfully, but these errors were encountered:
# Objective
- Intended to resolve#15290.
- Fix four duplicate `DragEnd` firing when drag finished.
- Fix redundant `DragStart` firing when dragging across pick-able
entities.
- Fix `Click` coming after `Drop` and obliterating finished drag
interactions.
Big thanks to B. Reinhart for testing picking in their codebase and
identifying these issues early.
## Solution
- Fix press & drag state being cleared after the first entity is read
from the hover map on pointer release, rather than after all entities
are read. This caused only the first hovered entity to receive `Up` and
`Click` events.
- Fixes `Down` being determined using the `previous_hover_map` rather
than `hover_map`, a regression compared to `bevy_mod_picking`. I think
this is what was messing up drag events.
- Fixes and issue where `PointerEnd` would fire multiple times and
`PointerStart` would fire when dragging onto a new entity.
- Re-orders events to make them easier to handle. `Out` now fired before
`DragLeave` and `Click/Up` now fire before `DragDrop`.
- Generally refactors the picking event code to be more clean and sane.
## Testing
These changes are currently sporadically tested.
Bevy version
bevy-0.15-dev as of around 9/18/24
What you did
What went wrong
If you have multiple sprites overlapping at different z in 2d ortho and they are Pickable with should_block_lower set to false, I used to get multiple Pointer Click for each one. With the recent change to hit ordering (#14862), I now only get the top-most Pointer Click. It seems like should_block_lower is not being respected.
The text was updated successfully, but these errors were encountered: