Search Unity

GameCenter login prompt sometimes not showing up or very delayed

Discussion in 'iOS and tvOS' started by CaptainKiyaku, Dec 12, 2016.

  1. CaptainKiyaku

    CaptainKiyaku

    Joined:
    Feb 8, 2009
    Posts:
    324
    Hi,

    we are having a bit of a problem with gamecenter in our game. Once the game launches, we call the game center login screen (Social.localUser.Authenticate(callbackMethod)). It works in most cases but once in a while it either shows up super delayed (20+ seconds after being called), or not at all.

    I am aware that cancelling the prompt 3 times in a row disables it until the user manually decides to login and launches the game. I'm successful at resetting this usually by doing exactly that.

    But in the case where it doesn't show up (not due to the 3x cancel situation), the callbackMethod never gets called either. Our game relied on this callback before proceeding (so we know if we can go ahead with GC or fall back to device id), which unfortunately means some people end up in an endless loader waiting for GC to do anything.

    We changed it up now to where we just load the game, try GC, and start our own timeout timer in the background that we cancel as soon as the callbackMethod is triggered.
    Problem with that is that the timeout could trigger, we fall back to device authentication, and 20-30 seconds later GC decides it's actually alive and brings up the login prompt. I don't think there is a way to detect if the prompt is open or pause the game while it is open.

    Using Unity 5.4.2 and we tested and reproduced this on iOS 9.3.3 and several iOS 10 versions.

    Does anyone have similar experience with this and knows a fix for this? Somehow to make GC more reliable?

    Thanks,
    Sven
     
  2. lexi89puzzle

    lexi89puzzle

    Joined:
    Feb 22, 2017
    Posts:
    10
    +1 having the same issue. Unity 5.6
     
  3. Rurikins

    Rurikins

    Joined:
    Jan 17, 2014
    Posts:
    1
    +1 same problem. Any solution or workaround?
     
  4. vgamer

    vgamer

    Joined:
    Sep 3, 2012
    Posts:
    2
    +1 here :(. Unity 2017.1.1
     
  5. idsamuel

    idsamuel

    Joined:
    Feb 7, 2019
    Posts:
    4
    Any update on this? 2018.3.5 here
     
  6. nlabsoftdev04

    nlabsoftdev04

    Joined:
    Mar 27, 2017
    Posts:
    4
    +1 same issue. Unity 2019.2.6f1

    How to insert timeout code?