Ejemplo n.º 1
0
        public void GrantCharacterItem(string itemId)
        {
            var grantRequest = new ServerModels.GrantItemsToCharacterRequest();

            grantRequest.PlayFabId   = playFabId;
            grantRequest.CharacterId = characterId;
            grantRequest.ItemIds     = new List <string>()
            {
                itemId
            };
            PlayFabServerAPI.GrantItemsToCharacter(grantRequest, GrantCharacterItemCallback, PfSharedControllerEx.FailCallback("GrantItemsToCharacter"));
        }
Ejemplo n.º 2
0
 public Action GrantCharacterItem(string itemId)
 {
     Action output = () =>
     {
         var grantRequest = new ServerModels.GrantItemsToCharacterRequest();
         grantRequest.PlayFabId = playFabId;
         grantRequest.CharacterId = characterId;
         grantRequest.ItemIds = new List<string>() { itemId };
         PlayFabServerAPI.GrantItemsToCharacter(grantRequest, GrantCharacterItemCallback, PfSharedControllerEx.FailCallback("GrantItemsToCharacter"));
     };
     return output;
 }