Android - in app purchase save variables

Hi friends

how ot save the variables in app purchase like unreal match 3.

Hey aamir, you can use Restore In-App Purchases macro for this.

https://docs.unrealengine.com/en-us/Platforms/Mobile/InAppPurchases

Also, if you want to save from local then you should use Unreal Save System after purchases successfully.

If i save the variables in save file then anyone can copy the save file and paste it in another device and then all items will unlocked for him too.

Technically yes, but if you use Restore In-App Purchases macro and check, there is no problem.

Hmm. Can you tell me about Restore in app pruchase macro. Whats the basic functionality for this node. And why this necessary?

To restore purchases, use the Restore In-App Purchases Blueprint node (or associated C++ function call). It only takes in the Player Controller, and returns an array of all the purchase information associated with that Player Controller. You can then process that array to compare against the particular Identifier (or Identifiers) that your gameplay logic needs.

Actually you said, anyone can copy the save file and paste it. So, for this you should use this macro.

Thanks now i got it. Yes this is work fine. But my another friend said this also not too useful node.
Is there another way to save the file in android root folder or save in game data ?

Ahh i think you are need a database for this. You can save data db instead of android root folder.

Hmm. Yes . Can you tell me how to do this ?

You can use Firebase. There is a plugin about this in marketplace.

https://www.unrealengine.com/marketplace/realtime-database-firebase

Thanks. its too much expensive

Please click the checkbox next to my answer so others with this problem can find it more easily.

Okz. Thanks .

Welcome glad to hear