iOS in-app purchase free / paid persistence -


i building game free play, , include 100 free consumable 'hints'. intend offer more hints purchase through in-app purchase. current method store file locally number of hints user still has left. when game first downloaded local file doesn't exist, new file created 100 hints. when in-app purchase happens, adds number of hints. (in game, each hint removes choice multiple choice question - file stores counter.)

my problem: user delete app when have 0 hints remaining (which delete local file has count of 0), re-download app app store , start again 100 hints.

my question: how prevent this? there different method should use storing hints?

use keychain store data, because keychain items not deleted if app uninstalled or removed. api lot link, have look

or

you can refer apple's documentation on keychain data


Comments