Hi, I'm making a Multiplayer FPS Game, right now I'm trying to save bought weapons to Playfab using Player Data (title).
Issue is: It doesnt get all or sometimes doesnt even try to get the weapons.
It says i have them on Playfab, but when i'm in the game it says i dont have it.
Request Code:
for (int i = 0; i < mm.gameInformation.allWeapons.Length; i++) { PlayFabClientAPI.GetUserData(new GetUserDataRequest(), cs.weaponload, cs.ondatafail); cs.weaponid = i; }
Result Code:
public void weaponload(GetUserDataResult result) { Debug.Log(result.Data.Keys); if (result.Data.ContainsKey(gameinfo.allWeapons[weapon].weaponName)) { gameinfo.allWeapons[weapon].wasboughtornot = true; } } }
I'm using Unity 2021.1.22f1