Hibernate and pause menu problem

Primo.TMPrimo.TM PRO Posts: 35
edited October 2012 in Working with GS (Mac)
Hi,
I'm using hibernate in one of my actors to pause the game when Home button is pressed, call received, etc. It looks like:
When actor receives hibernate -> pause game and go to scene "Paused game".

All is working fine, but the problem is when hibernation occurs while in Pause scene. When you return to the game, it goes into some kind of a loop and nothing on the screen is working. I've read that this is very common, but some people managed to find a solution.

Any ideas?

Comments

  • gurechangurechan Member, PRO Posts: 211
    What platform are you developing for? I believe that hibernate is only for the kindle nook and is not for use on iOS.
  • lycettebroslycettebros Member, PRO Posts: 1,598
    Hibernate will work on iOS but it is not made for it. It was really only developed for Android based devices (nook specifically I think).
    It works as the 'Home' button on iOS but it does odd unexpected things I have found and is not reliable (unless tested thoroughly).
  • Primo.TMPrimo.TM PRO Posts: 35
    edited October 2012
    So how can I pause a game and show the pause menu when the user hits the Home button or receives a call?
  • Primo.TMPrimo.TM PRO Posts: 35
    Anyone?
  • NeoStarNeoStar Member Posts: 25
    Hi,
    I'm using hibernate in one of my actors to pause the game when Home button is pressed, call received, etc. It looks like:
    When actor receives hibernate -> pause game and go to scene "Paused game".

    All is working fine, but the problem is when hibernation occurs while in Pause scene. When you return to the game, it goes into some kind of a loop and nothing on the screen is working. I've read that this is very common, but some people managed to find a solution.

    Any ideas?
    I think I have a possible resolution although this thread is a few months old. I'm also having a slightly different issue.

    To answer yours I would set up a hibernate rule in the actual pause screen to unpause the game and set an attribute "hibernate = true" Then in your scene where you would normally just hibernate set a rule that says if hibernate = true then pause the game. This would only trigger if the game is hibernated when the pause screen is already present. I havent tested this so I dont actually know if it works. Just a thought.

    My issue is that on Android when the home button is hit and I open the app then the game restarts. The hibernate function works if the phone is put to sleep or a call comes in but if the home button is hit and then the app is selected from the home screen the app doesnt pick up from my pause screen. Not sure if this is known or if there is another way to do this. Any help is appreciated.

    Thanks,
    Jon
Sign In or Register to comment.