I’m new to working with Unity IAP. I’m building a Mac app with Unity 2017.4.27f1 using Codeless IAP. I don’t want to change IAP scripts if I can avoid it.
I have three non-consumable in-app purchases that are games. The initial scene has a ‘start’ button. When that button is clicked, another scene is launched where the in-app purchases are made or gameplay is initialized.
Mac and iOS require restore buttons where people can log into their Apple ID account from my understanding. I want to develop code for when the restore has worked and the scene changes, the second scene will display either an IAP purchase button or a Play button for each game depending on its purchase status. My goal is to avoid having two buttons for each product displayed side by side.
I changed my button on the initial scene to a restore button and wrote code in a separate script to change the scene when the restore is complete. When I click the button, I get the “OSXEditor is not a supported platform for the Codeless IAP restore button” error in the console. The scene changes as expected. My guess is that when I upload this to the Mac App Store that the restore will fail with this error.
I have Automatically initialize UnityPurchasing checked in my IAP Catalog. According to the documentation, UnityPurchasing is initialized at the first instance of a Codeless IAP button. It also says when Automatically initialize UnityPurchasing is checked, UnityPurchasing is initialized when my application starts. I expected that UnityPurchasing would start with my restore button on the initial screen. Some people said that they got rid of the error by adding an IAP listener. This is what makes me think that the problem is that IAP has not started.
I don’t know why I’m getting this error or how to fix it. My log file is attached with identifying info masked.