|
#11
|
||||
|
||||
|
Yes, Restore for non-consumable is now mandatory. If people are wondering how it works...
You call: [[SKPaymentQueue defaultQueue] restoreCompletedTransactions]; to initiate a full restore. Everytime an item is restored, you 'll get a call to "restoreTransaction", so, you need to add this function (it is similar to completeTransaction when you do a normal purchase) - (void) restoreTransaction: (SKPaymentTransaction *)transaction { CStore::NumRestored++; [[SKPaymentQueue defaultQueue] finishTransaction: transaction]; } NumRestored is part of my own CStore class. I set it to zero before calling a restore. So, I know how many items have been restored. When all the items have been restored, you get a call to paymentQueueRestoreCompletedTransactionsFinished - (void)paymentQueueRestoreCompletedTransactionsFini shed: (SKPaymentQueue *)queue { if (CStore::NumRestored==0) { ... } } I'm testing if any items have been restored. If there are none, you can display a message like: "It doesn’t look like you've purchased this product with this account." Also, you might want to create this function too for completeness: - (void)paymentQueue: (SKPaymentQueue *)queue restoreCompletedTransactionsFailedWithError: (NSError *)error __OSX_AVAILABLE_STARTING(__MAC_NA,__IPHONE_3_0) { } Hope it helps ![]() JC |
|
#12
|
||||
|
||||
|
thanks to the starter of the thread! (and to all the other participants, too, of course)
|
|
#13
|
|||
|
|||
|
So if unlocking a level of some sort costs $.99, then you need to have a 'restore purchases'?
|
|
#14
|
|||
|
|||
|
Cool, it was way too confusing before. I'm glad apple is making this change. I know it will make customers more at ease and they won't have to go to customer support web pages just to ask if their inapps are still there.
|
|
#15
|
||||
|
||||
|
Yes.
|
|
#16
|
|||
|
|||
|
We (Cannibal Cookout) just got rejected for NO restore button for CONSUMABLE items. I have appealed to Apple as this can't actually be implemented
|
|
#17
|
||||
|
||||
|
That could be incorrect labeling of the IAP in iTunes connect. Be sure it's truly consumable.
|
|
#18
|
|||
|
|||
|
They are all consumable and have been for the last 4 updates!
|
|
#19
|
|||
|
|||
|
Just an update ... Apple finally went back and approved the update without requiring me to make any changes, so I'm guessing a reviewer got confused.
|
|
#20
|
|||
|
|||
|
Quote:
![]() Seriously tho, glad to help. Our lead programer for tka is on vacation for a month so we're beat on this update until he comes back; if we can save some frustration for other indies, well, at least something came out of it. |
![]() |
| Thread Tools | |
| Display Modes | |
|
|