Android Unable to use Google Play Leaderboard due to failed sign in

Discussion in 'GameMaker Studio 2 Community Tech Support' started by TheSly, May 18, 2017.

  1. TheSly

    TheSly Member

    Joined:
    Jan 16, 2017
    Posts:
    990
    Hi guys,

    Looking for some help with the leaderboard/achievement system for Android. I have an app that has been setup in Google Play Console as a linked app to the project. I've created a leaderboard and 5 achievements and am trying to show those when the app runs. I've run it on a phone and an emulator and both produce the same error.

    The code I use to show the leaderboard on a button is simply:
    Code:
    if active {
        achievement_login();
        achievement_show_leaderboards();
        active = false;
    }
    
    When pressed the Google Play Games logo shows and it attempts to log in. Then an error is shown on the device - "Failed to sign in. Please check your network connection and try again."

    The error shown in the output window is:
    Code:
    05-18 17:51:21.697 11116 11148 I yoyo    : AchievementLogin()
    
    05-18 17:51:21.698 11116 11116 I yoyo    : Calling connect on googleapiclient
    
    05-18 17:51:22.239 11116 11116 I yoyo    : onConnectionFailed called with result:ConnectionResult{statusCode=SIGN_IN_REQUIRED, resolution=PendingIntent{fca1fea: android.os.BinderProxy@7c512db}, message=null}
    
    
    I've tried creating a new keystore file, and relinking the hash file, redoing the whole SDK and NDK install, linking the API in Google API Manager, I have the 2 Google Play Extensions installed plus have done many other things through Google searches. At the moment I'm at a loss, so am wondering if anyone has come across this before?

    Also I can sign into Google Play in other games and it works fine.
    I've followed information in this, among others - http://www.fm-studio.net/blog/gmstudio-add-google-play-games-2-new/

    Any help would be appreciated.
    Thanks.
     
    Last edited: May 18, 2017
  2. TheSly

    TheSly Member

    Joined:
    Jan 16, 2017
    Posts:
    990
    SOLVED.

    For anyone with this problem in the future I had to go to Google Dev console and under game services rename my game, and create it again. Must of been a problem with the SHA1 key and the Oath 2.0 credentials, as relinking it solved the problem. I ensured I linked it inside the "Linked apps" tab on the left.
     
  3. Thanks for this information
     
  4. Jaime Lpz

    Jaime Lpz Member

    Joined:
    Aug 3, 2016
    Posts:
    15
    Hi! I am having a similar issue. I am trying to follow the steps, but could you be a bit more specific on what do you mean by "and create it again"? Do you mean creating the project? I have a leaderboard that stopped working on my game, wouldn't want to lose it as users have worked hard to get their ranks.

    I hope you can help me out :)
     
  5. TheSly

    TheSly Member

    Joined:
    Jan 16, 2017
    Posts:
    990
    Well this was 2 years ago, so I'm a bit hazy on details, but as I said, I renamed the current game in the google play console, and created it again. Mine was a project with no users, so doing this was not an issue.
     
  6. Jaime Lpz

    Jaime Lpz Member

    Joined:
    Aug 3, 2016
    Posts:
    15
    Thanks for your reply. I've tried it for a couple of projects, still no success. Not sure if this is related to the depreciation of Google+.
    Will keep testing, thanks!
     

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice