Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    1. COYou're describing a slightly different and much simpler problem. Simply identifying the object under any particular point is easy. It's also easy to forward a mouse up/down/click event to any object stacked under a particular point. With a "passthrough" problem however, dealing with even a single point (such as a mouse cursor) is more complex, because mouse-movement-related events must be manually detecting and generated. The over/out/rollover/rollout events involve detecting transitions between hit regions in an unlimited number of sub-layers (at least 1).
      singulars
    2. COAlso, there is more logic necessary to locate the actual target from the list of objects returned by getObjectsUnderPoint than one is led to believe. Often, that method returns DisplayObjects rather than InteractiveObjects, such that you must choose its parent. In fact, you may need to choose an ancestor of the node, because you must traverse the parent chain up the tree, all the way to the stage, to identify the highest parent, if any, that has mouseChildren set to false, because the highest parent object to have mouseChildren set to false will become the actual target of any mouse events.
      singulars
    3. COFinally, whatever that final target turns out to be, whether it's a parent, ancestor, or the original object... it must have its mouseEnabled property set to true... otherwise it is fully transparent to the mouse, and the next object in the array returned by getObjectsUnderPoint must be considered. Also with this kind of hierarchy, a static exclusion list must be maintained, because once a layer is processed, it must be excluded from further processing, interference, or interception of events.
      singulars
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload