I have a payment system for my game set up here's my code :
void Start()
{
T55.interactable = false;
Tiger2.interactable = false;
Cobra.interactable = false;
}
public void ProcessPurchase (ShopItem item)
{
if(item .SKU =="tank")
{
StoreHandler .Instance .Consume (item );
}
}
public void OnConsumeFinished (ShopItem item)
{
if(item .SKU =="tank")
{
T55.interactable = true;
Tiger2.interactable = true;
Cobra.interactable = true;
}
}
Now each time the player buy something in the game the intractability of my 3 buttons goes to true; but the problem is each time he closes the game the intractability goes back to false how.
Should I save the process so the player doesn't have to buy again to set them back to true?