- Home /
IDropHandler OnDrop() only being called on parent of dragged item.
I have two 'tray' objects which can hold any number of other objects.
When I drag a child of 'tray A' and drop it on 'tray B' (both trays are siblings), OnDrop() is only called on 'tray A', the parent object. Manually parenting the object to the other tray causes the opposite behaviour.
Why doesn't OnDrop() get called on every IDropHandler?
Thanks in advance.
EDIT, RESOLVED:
Turns out I had to attach a CanvasGroup to the item being dragged. Setting the 'Blocks Raycast' to false whilst dragging. OnDrop() now gets called correctly!
Comment
Does this qualify as a bug? After wrestling with this for 2 hours, I'd really like too see it fixed.
Your answer