Hi.
As far as I can see reading the source, currently Angel sends mouse events to
all listeners in unspecified order. With this behavior I find it very difficult
to implement mouse support in my game. It's controlled almost only by mouse, in
a manner similar to RTS games. So I have actors at various layers that all can
be clicked, but what I don't want is that two overlapping actors are both
clicked at the same time. Currently in Angel, two overlapping actors are both
clicked and I don't see a way around it.
So I suggest the following extension:
Angel should send mouse events by layer (from top layer to bottom layer). And
mouse event methods should return bool saying whether the event is considered
consumed. So if some actor at top layer wants to handle the event, it will
return true. At this point Angel breaks the loop and the event is not delivered
to other actors (for instance those at deeper layers).
Original issue reported on code.google.com by rhy...@rhywek.com on 3 Mar 2011 at 4:43
Original issue reported on code.google.com by
rhy...@rhywek.com
on 3 Mar 2011 at 4:43