UGS Player ID is missing - ensure you are signed in through the Authentication SDK and try again

Hey guys, I have a big problem please help me.

    async void OnEnable()
    {
        try
        {
            await UnityServices.InitializeAsync();
            Debug.Log("initialized");
        }
        catch (Exception e)
        {
            Debug.LogException(e);
        }

        PlayGamesPlatform.Activate();

        if (!FB.IsInitialized) FB.Init(authManager.InitCallback, authManager.OnHideUnity);
        else FB.ActivateApp();

        if (isClearToken) AuthenticationService.Instance.ClearSessionToken();

        if (AuthenticationService.Instance.SessionTokenExists) SignInWithCached();
        else OnCachedUserNotFound.Invoke();


    }

here is my authcontroller for sign in, there are 3 scenes in the game, auth, main menu and game scene. I log in using the unity gaming service on the auth stage, if the login is successful, I switch to the main menu stage and switch to the game stage by starting a new game in the queue. Now the problem is, I can communicate with ugs in the main menu scene, I can shoot the user’s data, etc., but if I want to enter the game scene and shoot the user’s data without making any changes, I get an error like this.

1 Answer

1

Guys I Fix this problem, but ı dont know how. Probobly some files are getting high :slight_smile: