Using Composer instead of Storyboard: how do i use the OverlayEnded listener?

Hi there,

I am changing my projects to use composer now instead of the deprecated storyboard but i am having problems:

I have a game scene and a ‘paused game’ overlay. When my game is paused the users decision of resuming or quitting the game is then put into action in my game scene’s “overlayEnded” listener. (i.e. if globals.quitgame == true then blahblah elseif globals.resumegame == true blahblah etc.)

But from what i can tell composer does not have this listener… what am I to do to rectify this?

Thanks a lot for your help in advance! peace n love!

There is a good example here.

To summarize, in your calling scene, create a scene:resumeGame() function.  When you are ready to leave the overlay scene, you call event.parent.resumeGame() in the overlay’s scene:hide().

–john

Great thanks a lot john that worked great. Can’t believe i missed that in the corona docs haha i even had the same page open in my browser!

Cool… glad it is working!  :slight_smile:

There is a good example here.

To summarize, in your calling scene, create a scene:resumeGame() function.  When you are ready to leave the overlay scene, you call event.parent.resumeGame() in the overlay’s scene:hide().

–john

Great thanks a lot john that worked great. Can’t believe i missed that in the corona docs haha i even had the same page open in my browser!

Cool… glad it is working!  :slight_smile: