The problem with google play services, created the application, linked it to the service, doing a leaderboard, released everything and the application and service, but I can not log in to the application. I created an empty project in a unit and still can’t log in, here’s the code. What could be the problem

public class test : MonoBehaviour { // Use this for initialization public Text text; void Start () { PlayGamesPlatform.Activate(); } // Update is called once per frame void Update () { } private void OnGUI() { if (GUI.Button(new Rect(0,0,150,150),"Enter")) { Social.localUser.Authenticate((bool success) => { if (success) { text.text = "You've successfully logged in" + Social.localUser.userName; } else { text.text = "Login failed for some reason"; } }); } if (GUI.Button(new Rect(0,150,150,150),"Send")) { Social.ReportScore(10,"CgkI2qbas9ANEAIQAQ",(bool success) => { if (success) { ( (PlayGamesPlatform) Social.Active ).ShowLeaderboardUI("CgkI2qbas9ANEAIQAQ"); } else { //Debug.Log("Login failed for some reason"); } }); } if (GUI.Button(new Rect(0,300,150,150),"Show")) { Social.ShowLeaderboardUI(); } } } 
  • Are you trying to check inside the unity editor? On the device checked? - Xumera_hZ
  • Yes, on the device I try only, the trick is that I have a window like that, Google is loading and that's it, doesn’t write "Welcome" and Nick - Maksim sikaylo
  • If you are given an exhaustive answer, mark it as accepted ^ _ ^ - Suvitruf

1 answer 1

Something I do not see your initialization. You have only PlayGamesPlatform.Activate(); is called.

Have you implemented this item exactly?

 PlayGamesClientConfiguration config = new PlayGamesClientConfiguration.Builder().Build(); PlayGamesPlatform.InitializeInstance(config); PlayGamesPlatform.DebugLogEnabled = true; 

If it still does not work, try authenticating the library explicitly from the library:

PlayGamesPlatform.Instance.Authenticate .