- Home /
 
Google Play load problem
Hi, I have a problem. I get autenticate a local user, create a leaderboard.....all is ok. Furthermore when I start my app a Google Play welcomes me. But the issue is when I try to show that leaderboard through a button. It doesn´t work. A popup appears . it says leaderboard and it loads something but never showing anything and my achievements doesn't show up.
EDIT: My friend can see leaderboards but he said he waited like 1 minute. I guess problem is loading time. how can i fix it?
at start
 PlayGamesPlatform.Activate();
         if (!Social.localUser.authenticated) {
             Social.localUser.Authenticate ((bool success) => {
 
                 if(success){
                     Debug.Log("Logged in");
                 } else {
                     Debug.Log("Not Logged in");
                 }
                 
             });
         }
 
               leaderboard button
 public void LeaderBoard(){
     if (Social.localUser.authenticated) {
         ((PlayGamesPlatform) Social.Active).ShowLeaderboardUI ();
     } else {
             Debug.Log("Not Logged in");
     }
 }
 
               and an example
 Social.ReportScore ((long) highScoreCount, rot.leaderboard_normal_mode, (bool success) => {
 
         });
 
               achievement button
 public void Achievement(){
         if (Social.localUser.authenticated) {
             Social.ShowAchievementsUI();
         } else {
             Debug.Log("Not Logged in");
         }
     }
 
               and an example
 if (PlayerPrefs.GetFloat ("hs1") == 50 || PlayerPrefs.GetFloat ("hs1") > 50) {
 
                 Social.ReportProgress (rot.achievement_amazing, 100.0f, (bool success) => {
 
                 });
             }
 
              I'm not sure if it makes a difference, but when I call to google leaderboards, I call to the PlayGamesPlatform, and not the standard Social platform. Have you tried using a PlayGamesPlatform call and not box converting it through the standard social?
I think you are missing ids of achievements and leaderboard in the method calls.
 ((PlayGamesPlatform) Social.Active).Show$$anonymous$$erboardUI (//here will be leaderboard id);
 
                  make sure you have set PlayGames setting in the unity
I have already set playgames setting but i tried what you said it gives me this errorAssets/Scripts/$$anonymous$$ain$$anonymous$$enu.cs(154,40): error CS1502: The best overloaded method match for `GooglePlayGames.PlayGamesPlatform.Show$$anonymous$$erboardUI(string, GooglePlayGames.BasicApi.$$anonymous$$erboardTimeSpan, System.Action)' has some invalid arguments
when you set playgames in the editor then unity creates static class GPGIDs, but you can change the name when making setup.
 PlayGamesPlatform.Instance.Show$$anonymous$$erboardUI (GPGIDs.leaderboard_ID);
 
                   just pass the leaderboard id from your static class which made during setup.
Note: don't forget to paste resources which you copied from the console.
just 5 $$anonymous$$utes ago $$anonymous$$erboard opened everything is fine. But the problem is load time. I wait for 10 $$anonymous$$utes. Is it still the same problem? And achievement problem still continues
Your answer
 
             Follow this Question
Related Questions
Google Play Services Working, but not Working? 2 Answers
Social.ShowAchievementsUI() not showing achievements 1 Answer
Unity Game not correctly configured to use google play game services 0 Answers
How can I include the resources folder to my project and build it to play on android devices? 1 Answer
Achievements Google Play. 1 Answer