Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7698167
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T22:10:45+00:00 2026-05-31T22:10:45+00:00

Im a beginner to the Corona SDK. I have 2 scenes A & B.

  • 0

Im a beginner to the Corona SDK.
I have 2 scenes A & B.

In scene A i have a button with a OnRelease event.
This button is created and added to the group in the scene Create event.
Clicking the button takes me to scene B ( storyboard.gotoScene(“B”) ).

In scene B i have a touch event on an box (crate image).
The touch listener is added in the scene Started event, and removed in the scene Exited event.
Clicking on the crate takes me back to A ( storyboard.gotoScene(“A”) ).

So here’s the real annoying issue:
After going back to A, all events in this scene are now disabled.
i.e. I can no longer click on the button any more (no event).

Will provide code snippet if I am missing information above.
Thank you.

* Update *

After taking about a break from this, i went back today and started debugging this again. I found the issue fairly quickly. The problem had something to do with my touched event handler (which causes a transition from scene B to A).

snippet below that caused the issue:

function testTouched( event )

-- process cue-touched event...
--local t = event.target -- commenting this was the fix.
local phase = event.phase

if "began" == phase then

        print("     -> back to menu")
        --display.getCurrentStage():setFocus( t ) -- commenting this was the fix.
        --t.isFocus = true -- commenting this was the fix.
        storyboard.gotoScene( "menu", "flipFadeOutIn", 500 )

end

-- Stop further propagation of touch event
return true
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-31T22:10:46+00:00Added an answer on May 31, 2026 at 10:10 pm

    From what I see here,

    enterScene

    Dispatched when storyboard.gotoScene() is called, immediately after
    the transition has completed. So if you specified a transition effect,
    this event is dispatched as soon as the effect has ended. Adding
    listeners, or app/game-specific logic should be placed in the listener
    function for this event.

    exitScene

    When storyboard.gotoScene() is called, an “exitScene” event will be
    dispatched to the currently shown scene before the transition occurs.
    Cleanup duties, such as removing event listeners, stopping timers,
    etc. should be placed in the listener function for this event.

    Add event listeners in enterScene() event rather than createScene() and remove them at exitScene()?

    Edit: I think you would need to display.getCurrentStage():setFocus(nil) in exitScene().

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Absolute beginner question: I have a template file index.html that looks like this: ...
Beginner programmer here....hope it makes sense :) I have created a console app that
Im beginner in android development. I ve just created a button in main.xml file
Android beginner, Can anybody guide me on this ? I do have the distance,
A beginner question... I have a list like this: x <- c(aa=v12, bb=x21, cc=f35,
Beginner level question Scenario: Have simple string cocantation tool, that I might expand later
Beginner here. Why is this an endless loop ? for (p = 0; p
Beginner here: In this answer to my question of how to insert data into
Beginner here, I have a simple question. In Android what would be the best
(R beginner here...) I have a dataset like: > head(q) Date Time System User

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.