Issues implementing achievements and leader boards Unity, Android - Google-Play-Games

user3358578 picture user3358578 · Feb 27, 2014 · Viewed 7.2k times · Source

I've finally made a game that I am happy to push on the android store and I have everything down packed except for a few minor details like implementing the leader board and achievements.

Now, I've followed the tutorial on the video produced by Bruno and Dan and have been able to sign in with multiple devices and multiple accounts, but nothing else seems to work.

I'm using unity and the plugin / sdk that was provided and told to download.

The things I am having trouble with is even getting the achievements and leader boards. I am using this code which was in the video:

// post score 12345 to leaderboard ID "Cfji293fjsie_QA")
        Social.ReportScore(12345, "(I have my leader board code here but am masking it for safety)", (bool success) => {
            // handle success or failure
        });

In that code I have it basically setup for the moment with testing that if a GUI.Button is pushed, the player will send the score 12345 to the leader board. Then once that is done, there is another button that can open the ShowLeaderBoardUI function that was also given in the video.

Once in the game on my phone, the scores wont show up, or the leader board itself once pressing the button either.

Am I doing something wrong? I'm not sure if I need to include anything else and I'm not even inputting my variables of score into the leader board yet for testing purposes.

If you need anymore information let me know.

I have the game in Beta on the Google Play Store with the application saying "Published", the Game Services say "Published". I have linked the app to the Game Services with the correct OUATH 2.0, with the correct App ID. All achievements and leader boards say "Published". Both of my email accounts are linked to the Game Services.

I'm just not sure where I have gone wrong and why I can't even ShowLeaderboardUI or even post a score.

Also is there a way to view the leader boards and achievements on a computer as apposed to a phone? or do I need to be on the phone to check them?

Thanks,

Chris

EDIT: Forgot to include that I can sign in and have all of the regular Google Play sign in graphics and it's signs in fine.

EDIT2: Forgot to mention that the game is in Beta in the Google Play Store.

Answer

Peter Andrews picture Peter Andrews · Mar 9, 2014

For what it's worth. I wasn't able to get Google's plugin to work, so I deleted everything google related in my project and installed this.

https://github.com/faizann/UnityGPGPlugin

Authentication works now, as well as reporting scores to the leaderboard. So it would appear that the issue actually lies with something in Google's plugin and not my setup on the developer console.