#InAppPurchasing count don't working
1 messages · Page 1 of 1 (latest)
How much quantity the user buys - on Android is not controllable programatically.
Let me see in V2, if the quantity is matched on the transaction or not.
Also, "Coins reset to 5000" - This acutally plugin doesn't handle. This is something you do on your end is it?
I guess it happens when shop event invokes
{
var transactions = result.Transactions;
for (int iter = 0; iter < transactions.Length; iter++)
{
var transaction = transactions[iter];
switch (transaction.TransactionState)
{
case BillingTransactionState.Purchased:
loadScreen.SetActive(false);
Debug.Log($"Buy product with id:{transaction.Payment.ProductId} finished successfully.");
PerformPurchaseComplete(transaction.Payment.ProductId);
break;
case BillingTransactionState.Failed:
loadScreen.SetActive(false);
Debug.Log($"Buy product with id:{transaction.Payment.ProductId} failed with error. Error: {transaction.Error}");
break;
case BillingTransactionState.Refunded:
loadScreen.SetActive(false);
break;
case BillingTransactionState.Restored:
loadScreen.SetActive(false);
break;
}
}
}```
Maybe there
Aren't you considering the quantity property?
In the IBillingPayment returned in IBillingTransaction there is a quanity property
Will works?
Should be fine if you use latest version
Yes. So what I can to do with reseting purchase after restart?
Yes. So what I can to do with reseting purchase after restart?
Is this the coins amount getting reset in your game?
I'm buy coins. Get purchase complete and turn off internet. Get my coins from IAP and spend them in shop. After restart I get coins from transaction again and one more time can spend them in shop
Do you understand me?
I think that I got this method again when i'm enter game?
Maybe transaction wouldn't save because of internet off
And try to give it in next launch
2 usages and it's from IAP events
I'll send video and show my problem
We only fire a transaction if the transaction don't fire an event post purchase.
What happens is - When a purchase is made, we fire the event and consume the purchase (via an api to the store).
If this particular api fails to process, you may get another event with the same details.
I have idea how i can fix it. If i save receipt ID and compare it when restart