GPGS V2 하고 있는데요. 질문 있습니다. 2

using BackEnd;
using GooglePlayGames;
using GooglePlayGames.BasicApi;
using UnityEngine;
using TMPro;

public class NewBehaviourScript : MonoBehaviour
{
    public TextMeshProUGUI text;

    void Start()
    {
      
        PlayGamesPlatform.Instance.Authenticate(ProcessAuthentication);

    }


    void ProcessAuthentication(SignInStatus status)
    {
        text.text = "ProcessAuthentication";
        if (status == SignInStatus.Success)
        {
            GetAccessCode();
            // Continue with Play Games Services
            text.text = status.ToString();
        }
        else
        {
            
            text.text = status.ToString();
            // Disable your integration with Play Games Services or show a login button
            // to ask users to sign-in. Clicking it should call
            // PlayGamesPlatform.Instance.ManuallyAuthenticate(ProcessAuthentication).
        }
    }


    public void GetAccessCode()
    {
        PlayGamesPlatform.Instance.RequestServerSideAccess(
          /* forceRefreshToken= */ false,
          code => {
              Debug.Log("구글 인증 코드 : " + code);

              Backend.BMember.GetGPGS2AccessToken(code, googleCallback =>
              {
                  Debug.Log("GetGPGS2AccessToken 함수 호출 결과 " + googleCallback);

                  string accessToken = "";

                  if (googleCallback.IsSuccess())
                  {
                      accessToken = googleCallback.GetReturnValuetoJSON()["access_token"].ToString();
                  }

                  Backend.BMember.AuthorizeFederation(accessToken, FederationType.GPGS2, callback =>
                  {
                      Debug.Log("뒤끝 로그인 성공했습니다. " + callback);
                 });

                  text.text = "구글 인증 코드 : " + code + "\n" + "GetGPGS2AccessToken 함수 호출 결과 " + googleCallback ;

              });
          });
    }
}

이렇게 했는데
내부테스트해봤는데 text가 안바껴요.
(New Text로 시작했는데 그냥 New Text에요.)
해결 어떻게 하나요?

안녕하세요, 개발자님.
TextMeshProUGUI가 null이 아닌지, 해당 스크립트에서 Start 함수가 호출되었는지 확인해보시기 바랍니다.
감사합니다.

코드는
using BackEnd;
using GooglePlayGames;
using GooglePlayGames.BasicApi;
using UnityEngine;
using UnityEngine.UI;

public class NewBehaviourScript : MonoBehaviour
{
public Text logText;

void Start()
{
    Login();
}

public void Login()
{
PlayGamesPlatform.Instance.Authenticate(ProcessAuthentication);
}

void ProcessAuthentication(SignInStatus status)
{
    if (status == SignInStatus.Success)
    {
        GetAccessCode();
        // Continue with Play Games Services
    }
    else
    {
        // Disable your integration with Play Games Services or show a login button
        // to ask users to sign-in. Clicking it should call
        // PlayGamesPlatform.Instance.ManuallyAuthenticate(ProcessAuthentication).
       logText.text = "뒤끝 로그인 실패 ";
    }
}

public void GetAccessCode()
{
    PlayGamesPlatform.Instance.RequestServerSideAccess(
      /* forceRefreshToken= */ false,
      code => {
          Debug.Log("구글 인증 코드 : " + code);

          Backend.BMember.GetGPGS2AccessToken(code, googleCallback =>
          {
              Debug.Log("GetGPGS2AccessToken 함수 호출 결과 " + googleCallback);

              string accessToken = "";

              if (googleCallback.IsSuccess())
              {
                  accessToken = googleCallback.GetReturnValuetoJSON()["access_token"].ToString();
              
              }

             var bro= Backend.BMember.AuthorizeFederation(
              accessToken,
              FederationType.GPGS2,
              "GPGS2로 가입함"
              );
              Debug.Log(bro.GetStatusCode());
     

          });
      });
}

}
이렇게 하고

로그캣 해봤더니
2024-03-14 05:49:39.637 10369 10402 Info Unity
2024-03-14 05:49:40.285 10369 10559 Info Unity GetGPGS2AccessToken 함수 호출 결과 statusCode : 200
2024-03-14 05:49:40.285 10369 10559 Info Unity message : Success
2024-03-14 05:49:40.285 10369 10559 Info Unity returnValue : {
2024-03-14 05:49:40.285 10369 10559 Info Unity “access_token”: “ya29.a0Ad52N3965ubclubLueryfultj1tmdhgFezTBGuaVzAgwRfawNtyGoQoWB_3ZkYoJeEciIz9XZHubCip5ORCWb-Llr1ThDa36XZvFfN68VBi27g6gNSXCOUYvQPxluZ8vnPqXFRP796sdBr8sjhNM62YRRlZ8zGmWQAaCgYKAS8SARISFQHGX2Mi59YxsY5B5o6Q7NODCqfyaw0169”,
2024-03-14 05:49:40.285 10369 10559 Info Unity “expires_in”: 3599,
2024-03-14 05:49:40.285 10369 10559 Info Unity “scope”: “https://www.googleapis.com/auth/drive.appdata https://www.googleapis.com/auth/games_lite”,
2024-03-14 05:49:40.285 10369 10559 Info Unity “token_type”: “Bearer”
2024-03-14 05:49:40.285 10369 10559 Info Unity }
2024-03-14 05:49:40.285 10369 10559 Info Unity <>c:b__4_1(BackendReturnObject)
2024-03-14 05:49:40.285 10369 10559 Info Unity BackEnd.Game.d__96:MoveNext()
2024-03-14 05:49:40.285 10369 10559 Info Unity System.Threading.ExecutionContext:RunInternal(ExecutionContext, ContextCallback, Object, Boolean)
2024-03-14 05:49:40.285 10369 10559 Info Unity System.Runtime.CompilerServices.MoveNextRunner:Run()
2024-03-14 05:49:40.285 10369 10559 Info Unity System.Threading.Tasks.AwaitTaskContinuation:RunOrScheduleAction(Action, Boolean, Task&)
2024-03-14 05:49:40.285 10369 10559 Info Unity System.Threading.Tasks.Task:FinishContinuations()
2024-03-14 05:49:40.285 10369 10559 Info Unity System.Threading.Tasks.Task:Finish(Boolean)
2024-03-14 05:49:40.285 10369 10559 Info Unity System.Threading.Tasks.Task:ExecuteWithThreadLocal(Task&)
2024-03-14 05:49:40.285 10369 10559 Info Unity System.Threading.Tasks.Task:ExecuteEntry(Boolean)
2024-03-14 05:49:40.285 10369 10559 Info Unity S
2024-03-14 05:49:40.347 10369 10559 Info Unity 401
2024-03-14 05:49:40.347 10369 10559 Info Unity BackEnd.Game.d__96:MoveNext()
2024-03-14 05:49:40.347 10369 10559 Info Unity System.Threading.ExecutionContext:RunInternal(ExecutionContext, ContextCallback, Object, Boolean)
2024-03-14 05:49:40.347 10369 10559 Info Unity System.Runtime.CompilerServices.MoveNextRunner:Run()
2024-03-14 05:49:40.347 10369 10559 Info Unity System.Threading.Tasks.AwaitTaskContinuation:RunOrScheduleAction(Action, Boolean, Task&)
2024-03-14 05:49:40.347 10369 10559 Info Unity System.Threading.Tasks.Task:FinishContinuations()
2024-03-14 05:49:40.347 10369 10559 Info Unity System.Threading.Tasks.Task:Finish(Boolean)
2024-03-14 05:49:40.347 10369 10559 Info Unity System.Threading.Tasks.Task:ExecuteWithThreadLocal(Task&)
2024-03-14 05:49:40.347 10369 10559 Info Unity System.Threading.Tasks.Task:ExecuteEntry(Boolean)
2024-03-14 05:49:40.347 10369 10559 Info Unity System.Threading.ThreadPoolWorkQueue:Dispatch()
2024-03-14 05:49:40.347 10369 10559 Info Unity

이렇게 나와요.

왜 안되는거죠?

using BackEnd;
using GooglePlayGames;
using GooglePlayGames.BasicApi;
using UnityEngine;
using UnityEngine.UI;

public class NewBehaviourScript : MonoBehaviour
{
public Text logText;

void Start()
{
    Login();
}

public void Login()
{
PlayGamesPlatform.Instance.Authenticate(ProcessAuthentication);
}

void ProcessAuthentication(SignInStatus status)
{
    if (status == SignInStatus.Success)
    {
        GetAccessCode();
        // Continue with Play Games Services
    }
    else
    {
        // Disable your integration with Play Games Services or show a login button
        // to ask users to sign-in. Clicking it should call
        // PlayGamesPlatform.Instance.ManuallyAuthenticate(ProcessAuthentication).
       logText.text = "뒤끝 로그인 실패 ";
    }
}

public void GetAccessCode()
{
    PlayGamesPlatform.Instance.RequestServerSideAccess(
      /* forceRefreshToken= */ false,
      code => {
          Debug.Log("구글 인증 코드 : " + code);

          Backend.BMember.GetGPGS2AccessToken(code, googleCallback =>
          {
              Debug.Log("GetGPGS2AccessToken 함수 호출 결과 " + googleCallback);

              string accessToken = "";

              if (googleCallback.IsSuccess())
              {
                  accessToken = googleCallback.GetReturnValuetoJSON()["access_token"].ToString();
                  Debug.Log(accessToken);

                  var bro = Backend.BMember.AuthorizeFederation(
             accessToken,
             FederationType.GPGS2,
             "GPGS2로 가입함"
             );
                  Debug.Log("bro.GetStatusCode()" +bro.GetStatusCode());
                  Debug.Log("bro.GetErrorCode()" + bro.GetErrorCode());
                  Debug.Log("bro.GetMessage()" + bro.GetMessage());

              }






          });
      });
}

}
이 코드로 했을떄
2024-03-14 07:09:04.568 12521 12758 Info Unity
2024-03-14 07:09:04.588 12521 12766 Info Unity ya29.a0Ad52N3-NJhmz3fnjZ-CF_6DQBt77LEUNIhrNKLQwd8TXiF6iXEQwsG55-_6cKI41xSLypKTjEZwqurSrv4yGd6Dcw4WFPceBv7HYPoC9TpTRiMCS_XD2bZdRvZLG6vwMx9W4R2-7_lqD2rvR4RTJIt2_tprKaBDoEQaCgYKAYcSARISFQHGX2Mi5Kt6plMq12ejkFlZvUrTzA0169
2024-03-14 07:09:04.588 12521 12766 Info Unity <>c:b__4_1(BackendReturnObject)
2024-03-14 07:09:04.588 12521 12766 Info Unity BackEnd.Game.d__96:MoveNext()
2024-03-14 07:09:04.588 12521 12766 Info Unity System.Threading.ExecutionContext:RunInternal(ExecutionContext, ContextCallback, Object, Boolean)
2024-03-14 07:09:04.588 12521 12766 Info Unity System.Runtime.CompilerServices.MoveNextRunner:Run()
2024-03-14 07:09:04.588 12521 12766 Info Unity System.Threading.Tasks.AwaitTaskContinuation:RunOrScheduleAction(Action, Boolean, Task&)
2024-03-14 07:09:04.588 12521 12766 Info Unity System.Threading.Tasks.Task:FinishContinuations()
2024-03-14 07:09:04.588 12521 12766 Info Unity System.Threading.Tasks.Task:Finish(Boolean)
2024-03-14 07:09:04.588 12521 12766 Info Unity System.Threading.Tasks.Task:ExecuteWithThreadLocal(Task&)
2024-03-14 07:09:04.588 12521 12766 Info Unity System.Threading.Tasks.Task:ExecuteEntry(Boolean)
2024-03-14 07:09:04.588 12521 12766 Info Unity System.Threading.ThreadPoolWorkQueue:Dispatch()
2024-03-14 07:09:04.588 12521 12766 Info Unity
2024-03-14 07:09:16.328 12521 12758 Info Unity bro.GetStatusCode()401
2024-03-14 07:09:16.328 12521 12758 Info Unity <>c:b__4_1(BackendReturnObject)
2024-03-14 07:09:16.328 12521 12758 Info Unity BackEnd.Game.d__96:MoveNext()
2024-03-14 07:09:16.328 12521 12758 Info Unity System.Threading.ExecutionContext:RunInternal(ExecutionContext, ContextCallback, Object, Boolean)
2024-03-14 07:09:16.328 12521 12758 Info Unity System.Runtime.CompilerServices.MoveNextRunner:Run()
2024-03-14 07:09:16.328 12521 12758 Info Unity System.Threading.Tasks.AwaitTaskContinuation:RunOrScheduleAction(Action, Boolean, Task&)
2024-03-14 07:09:16.328 12521 12758 Info Unity System.Threading.Tasks.Task:FinishContinuations()
2024-03-14 07:09:16.328 12521 12758 Info Unity System.Threading.Tasks.Task:Finish(Boolean)
2024-03-14 07:09:16.328 12521 12758 Info Unity System.Threading.Tasks.Task:ExecuteWithThreadLocal(Task&)
2024-03-14 07:09:16.328 12521 12758 Info Unity System.Threading.Tasks.Task:ExecuteEntry(Boolean)
2024-03-14 07:09:16.328 12521 12758 Info Unity System.Threading.ThreadPoolWorkQueue:Dispatch()
2024-03-14 07:09:16.328 12521 12758 Info Unity
2024-03-14 07:09:16.344 12521 12766 Info Unity bro.GetStatusCode()500
2024-03-14 07:09:16.344 12521 12766 Info Unity <>c:b__4_1(BackendReturnObject)
2024-03-14 07:09:16.344 12521 12766 Info Unity BackEnd.Game.d__96:MoveNext()
2024-03-14 07:09:16.344 12521 12766 Info Unity System.Threading.ExecutionContext:RunInternal(ExecutionContext, ContextCallback, Object, Boolean)
2024-03-14 07:09:16.344 12521 12766 Info Unity System.Runtime.CompilerServices.MoveNextRunner:Run()
2024-03-14 07:09:16.344 12521 12766 Info Unity System.Threading.Tasks.AwaitTaskContinuation:RunOrScheduleAction(Action, Boolean, Task&)
2024-03-14 07:09:16.344 12521 12766 Info Unity System.Threading.Tasks.Task:FinishContinuations()
2024-03-14 07:09:16.344 12521 12766 Info Unity System.Threading.Tasks.Task:Finish(Boolean)
2024-03-14 07:09:16.344 12521 12766 Info Unity System.Threading.Tasks.Task:ExecuteWithThreadLocal(Task&)
2024-03-14 07:09:16.344 12521 12766 Info Unity System.Threading.Tasks.Task:ExecuteEntry(Boolean)
2024-03-14 07:09:16.344 12521 12766 Info Unity System.Threading.ThreadPoolWorkQueue:Dispatch()
2024-03-14 07:09:16.344 12521 12766 Info Unity
2024-03-14 07:09:16.349 12521 12766 Info Unity bro.GetErrorCode()ERR_INVALID_ARG_TYPE
2024-03-14 07:09:16.349 12521 12766 Info Unity <>c:b__4_1(BackendReturnObject)
2024-03-14 07:09:16.349 12521 12766 Info Unity BackEnd.Game.d__96:MoveNext()
2024-03-14 07:09:16.349 12521 12766 Info Unity System.Threading.ExecutionContext:RunInternal(ExecutionContext, ContextCallback, Object, Boolean)
2024-03-14 07:09:16.349 12521 12766 Info Unity System.Runtime.CompilerServices.MoveNextRunner:Run()
2024-03-14 07:09:16.349 12521 12766 Info Unity System.Threading.Tasks.AwaitTaskContinuation:RunOrScheduleAction(Action, Boolean, Task&)
2024-03-14 07:09:16.349 12521 12766 Info Unity System.Threading.Tasks.Task:FinishContinuations()
2024-03-14 07:09:16.349 12521 12766 Info Unity System.Threading.Tasks.Task:Finish(Boolean)
2024-03-14 07:09:16.349 12521 12766 Info Unity System.Threading.Tasks.Task:ExecuteWithThreadLocal(Task&)
2024-03-14 07:09:16.349 12521 12766 Info Unity System.Threading.Tasks.Task:ExecuteEntry(Boolean)
2024-03-14 07:09:16.349 12521 12766 Info Unity System.Threading.ThreadPoolWorkQueue:Dispatch()
2024-03-14 07:09:16.349 12521 12766 Info Unity
2024-03-14 07:09:16.356 12521 12758 Info Unity bro.GetErrorCode()BadUnauthorizedException
2024-03-14 07:09:16.356 12521 12758 Info Unity <>c:b__4_1(BackendReturnObject)
2024-03-14 07:09:16.356 12521 12758 Info Unity BackEnd.Game.d__96:MoveNext()
2024-03-14 07:09:16.356 12521 12758 Info Unity System.Threading.ExecutionContext:RunInternal(ExecutionContext, ContextCallback, Object, Boolean)
2024-03-14 07:09:16.356 12521 12758 Info Unity System.Runtime.CompilerServices.MoveNextRunner:Run()
2024-03-14 07:09:16.356 12521 12758 Info Unity System.Threading.Tasks.AwaitTaskContinuation:RunOrScheduleAction(Action, Boolean, Task&)
2024-03-14 07:09:16.356 12521 12758 Info Unity System.Threading.Tasks.Task:FinishContinuations()
2024-03-14 07:09:16.356 12521 12758 Info Unity System.Threading.Tasks.Task:Finish(Boolean)
2024-03-14 07:09:16.356 12521 12758 Info Unity System.Threading.Tasks.Task:ExecuteWithThreadLocal(Task&)
2024-03-14 07:09:16.356 12521 12758 Info Unity System.Threading.Tasks.Task:ExecuteEntry(Boolean)
2024-03-14 07:09:16.356 12521 12758 Info Unity System.Threading.ThreadPoolWorkQueue:Dispatch()
2024-03-14 07:09:16.356 12521 12758 Info Unity
2024-03-14 07:09:16.358 12521 12766 Info Unity bro.GetMessage()The “key” argument must be of type string or an instance of ArrayBuffer, Buffer, TypedArray, DataView, KeyObject, or CryptoKey. Received undefined
2024-03-14 07:09:16.358 12521 12766 Info Unity BackEnd.Game.d__96:MoveNext()
2024-03-14 07:09:16.358 12521 12766 Info Unity System.Threading.ExecutionContext:RunInternal(ExecutionContext, ContextCallback, Object, Boolean)
2024-03-14 07:09:16.358 12521 12766 Info Unity System.Runtime.CompilerServices.MoveNextRunner:Run()
2024-03-14 07:09:16.358 12521 12766 Info Unity System.Threading.Tasks.AwaitTaskContinuation:RunOrScheduleAction(Action, Boolean, Task&)
2024-03-14 07:09:16.358 12521 12766 Info Unity System.Threading.Tasks.Task:FinishContinuations()
2024-03-14 07:09:16.358 12521 12766 Info Unity System.Threading.Tasks.Task:Finish(Boolean)
2024-03-14 07:09:16.358 12521 12766 Info Unity System.Threading.Tasks.Task:ExecuteWithThreadLocal(Task&)
2024-03-14 07:09:16.358 12521 12766 Info Unity System.Threading.Tasks.Task:ExecuteEntry(Boolean)
2024-03-14 07:09:16.358 12521 12766 Info Unity System.Threading.ThreadPoolWorkQueue:Dispatch()
2024-03-14 07:09:16.358 12521 12766 Info Unity
2024-03-14 07:09:16.375 12521 12758 Info Unity bro.GetMessage()bad packageName, 잘못된 packageName 입니다
2024-03-14 07:09:16.375 12521 12758 Info Unity BackEnd.Game.d__96:MoveNext()
2024-03-14 07:09:16.375 12521 12758 Info Unity System.Threading.ExecutionContext:RunInternal(ExecutionContext, ContextCallback, Object, Boolean)
2024-03-14 07:09:16.375 12521 12758 Info Unity System.Runtime.CompilerServices.MoveNextRunner:Run()
2024-03-14 07:09:16.375 12521 12758 Info Unity System.Threading.Tasks.AwaitTaskContinuation:RunOrScheduleAction(Action, Boolean, Task&)
2024-03-14 07:09:16.375 12521 12758 Info Unity System.Threading.Tasks.Task:FinishContinuations()
2024-03-14 07:09:16.375 12521 12758 Info Unity System.Threading.Tasks.Task:Finish(Boolean)
2024-03-14 07:09:16.375 12521 12758 Info Unity System.Threading.Tasks.Task:ExecuteWithThreadLocal(Task&)
2024-03-14 07:09:16.375 12521 12758 Info Unity System.Threading.Tasks.Task:ExecuteEntry(Boolean)
2024-03-14 07:09:16.375 12521 12758 Info Unity System.Threading.ThreadPoolWorkQueue:Dispatch()
2024-03-14 07:09:16.375 12521 12758 Info Unity
이렇게 나와요
해결 어떻게 해야되나요?

안녕하세요 개발자님. :D
남겨주신 말씀과 유선상으로 문의해주신 내용에 대하여 확인하실 수 있는 개발자 문서 안내드립니다.

넵 해결됐습니다 감사합니다

좋아요 1