question

bluesky4900 avatar image
bluesky4900 asked

PurchaseItem Price, CatalogItem VirtualCurrencyPrices Data Type

PurchaseItemRequest Price Type is int

CatalogItem VirtualCurrencyPrice Type is uint

I tried to use it directly for Price using the Virtual Current Price value, but I found out that the type was different. I think the type should be the same, but why is Price is int?

Simple curiosity.

2 comments
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Sarah Zhang avatar image Sarah Zhang commented ·

It looks like you are descripting the behavior of PlayFab SDK of some platform. Could you please clarify which one platform's SDK you are discussing?

0 Likes 0 ·
bluesky4900 avatar image bluesky4900 Sarah Zhang commented ·

unity client api.

aslo,

PlayFabClientAPI.ValidateIOSReceipt(new ValidateIOSReceiptRequest { PurchasePrice = (int)e.purchasedProduct.metadata.localizedPrice } PlayFabClientAPI.ValidateGooglePlayPurchase(new ValidateGooglePlayPurchaseRequest() { PurchasePrice = (uint)(e.purchasedProduct.metadata.localizedPrice }

IOS Price is int.

but GooglePlay Price is uint

0 Likes 0 ·

1 Answer

·
Sarah Zhang avatar image
Sarah Zhang answered

Thanks for your report, it should be a minor issue of our Unity SDK. The price of iOS purchase should also be an unsigned integer. Currently, as a workaround, you can convert the int type to uint manually like what you current do.

10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.