A reader sent me this question. Thanks in advance to Michael:
i’m dispatching an event from a sprite after it fades in completely
dispatchEvent(new Event(Main.ENTER_SCREEN_COMPLETE));i’m trying to listen for to this event but for some reason it doesn’t get picked up when the capturing parameter is set to false.. that is for bubbling and the target phase.
This works
container.addEventListener(Main.ENTER_SCREEN_COMPLETE, screenTweenComplete, true, 0, true);This does NOT work
container.addEventListener(Main.ENTER_SCREEN_COMPLETE, screenTweenComplete, false, 0, true);Where container, is an ancestor to everything on the screen. Essentially its the the stage.
Any clues why this is happening?
Answer after the jump.
Continue reading