I got this bit of code off of unicorn battle, and I was wondering how you access the different values within the created dictionary. So if i was looking for my "Gold" currency that is already on my player to change to a string and display on the main menu. Using Unity C#
private static Dictionary<string, int> virtualCurrency = new Dictionary<string, int>(); public static void GetUserInventory(Action callback = null) { PlayFabClientAPI.GetUserInventory(new GetUserInventoryRequest(), (GetUserInventoryResult result) => { virtualCurrency.Clear(); playerInventory.Clear(); foreach (var pair in result.VirtualCurrency) { virtualCurrency.Add(pair.Key, pair.Value); //trying to return these ^^^ } foreach (var eachItem in result.Inventory) { } if (callback != null) callback(); PF_Bridge.RaiseCallbackSuccess("", PlayFabAPIMethods.GetUserInventory, MessageDisplayStyle.none); }, PF_Bridge.PlayFabErrorCallback); }