I'm currently working on a system where the player has their PlayFab ID show up on their head, and for the most part it's working, however, if they check my player, it shows their ID instead of mine. Is there any way to check the views of the players and have it so that it shows their PlayFab ID instead of mine?
Here's the script:
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using PlayFab;
using PlayFab.ClientModels;
using TMPro;
public class PlayfabIDShow : MonoBehaviour
{
public TextMeshPro playfabID;
private void Start()
{
GetAccountInfo();
}
void GetAccountInfo()
{
GetAccountInfoRequest request = new GetAccountInfoRequest();
PlayFabClientAPI.GetAccountInfo(request, Success, Fail);
}
void Success(GetAccountInfoResult result)
{
playfabID.text = result.AccountInfo.PlayFabId;
}
void Fail(PlayFabError error)
{
Debug.LogError(error.GenerateErrorReport());
}
}