Make in app purchases with minimal setup and very little programming knowledge.
Same code for all supported platforms.
Just import Easy IAP and add your product IDs and all is done.
Can be tested using Unity Editor.
Support for Consumable. Non-Consumable and Subscriptions.
Easy setup for in app products using a custom made Setttings Window.
Works with Unity 5.3 and above and with Free, Plus or Pro versions of Unity.
Currently supported platforms:
Google Play
App Store (iOS)
Amazon Store
Easy setup from a custom Editor Window:
Simple methods to make a purchase that work for all platforms:
Initialize plugin
//call this method only once at the beginning of the game to initialize product information.
IAPManager.Instance.InitializeIAPManager(InitializeResultCallback);
//this method will be called after initialization process is done
private void InitializeResultCallback(Status status, string message, List<StoreProduct> shopProducts)
{
if (status == Status.Success)
{
//IAP was successfully initialized
//loop through all products
for (int i = 0; i < shopProducts.Count; i++)
{
if (shopProducts[i].productName == "YourProductName")
{
//if active variable is true, means that user had bought that product
//so enable access
if (shopProducts[i].active)
{
yourBoolVariable = true;
}
}
}
}
else
{
Debug.Log(âError occurred â+ message);
}
}
Buy product
IAPManager.Instance.BuyProduct(ShopProductNames.YourProductName, ProductBoughtCallback);
// automatically called after one product is bought
// this is an example of product bought callback
private void ProductBoughtCallback(Status status, string message, StoreProduct product)
{
if (status == Status.Success)
{
//each consumable gives coins in this example
if (product.productType == ProductType.Consumable)
{
coins += product.value;
}
//non consumable Unlock Level 1 -> unlocks level 1 so we set the corresponding bool to true
if (product.productName == "UnlockLevel1")
{
unlockLevel1 = true;
}
//subscription has been bought so we set our subscription variable to true
if (product.productName == "Subscription")
{
subscription = true;
}
}
else
{
//an error occurred in the buy process, log the message for more details
Debug.Log("Buy product failed: " + message);
}
}
Restore Purchases
//only required for iOS App Store
//restores previously bought products
//this is also done automatically every time at initialize
IAPManager.Instance.RestorePurchases(ProductRestoredCallback);
// this is an example of product restored callback
private void ProductRestoredCallback(Status status, string message, StoreProduct product)
{
if (status == Status.Success)
{
//consumable products are not restored
//non consumable Unlock Level 1 -> unlocks level 1 so we set the corresponding bool to true
if (product.productName == "UnlockLevel1")
{
unlockLevel1 = true;
}
//subscription has been bought so we set our subscription variable to true
if (product.productName == "Subscription")
{
subscription = true;
}
}
else
{
//an error occurred in the buy process, log the message for more details
Debug.Log("Buy product failed: " + message);
}
}
I have bought 2 of your plugins (Easy IAP and Easy Achievements and Leaderboards),
I have followed your instructions to the letter and everything builds fine but once the app is deployed to an Android device the game starts and attempts to access google services I get the App has stopped working message.
Can you provide any assistance on how to resolve the issue?
Hello,
Thank you for using our plugins.
Please connect your app to Android monitor and see what is the reason for the crash then let us know.
If that is not possible please ad us as a tester for your app using gley.mobi@gmail.com e-mail address and send us your test link and we will debug your app for you to see what went wrong with your implementation.
Thanks for the quick reply I have used the Android Monitor and found the APPID was incorrectly configured in the manifest file, in the manifest file the APPID starts with \ but it needs to start with \u003. The Easy Achievements is working like a treat now, next up Easy IAP
ITunes states that any IAP that contains more than one needs to be upgradable. So, if i am subscribed to a 0.99$ subscription and there is a second sub i can get for 9.99$ there must be a function that allows me to upgrade to that 9.99$ sub. So if i sub to the 9.99 i then get out of my 0.99 sub at the end of the billing cycle and enter into a new sub for 9.99. Your asset doesnt have this feature. There is no way to detect this. There has to be a way to detect receipts and upgrade this. Itunes says its a thing cause our app got denied cause we didnt have an upgrade feature.
Sorry,
What you are asking is not possible with Unity IAP, or I did not understand correctly what you ware asking. Subscriptions cannot be linked one to another and what you are asking is a store feature not an app feature. It is possible to get the info from the receipt but your subscriptions became active in the moment is purchased because the store provides that info, it cannot be altered at the app level to be active after the previous subscription(another one) expires.
We cannot help you in this problem, send us an e-mail at gley.assets@gmail.com with your invoice number and we will offer you a refund.
Hi~
My game is a premium app for now. I plan to switch to free and start IAP in the future. But I will still need to recognize if the player has paid for my game. How can I use EasyIAP to check the receipt. I donât know how to code, but I know how to use playmaker. Could you offer me a step by step tutorial or some direction? Thank You~
Hello,
Sorry,
Currently I never done that before. As I read if your app is started as payed app, it is not possible to make it free(I might be wrong). Unity IAP is used for In App Purchase. If your user bought your app that not counts as an In App Purchase and it cannot be checked using Unity IAP you have to check it using another APIs.
I might be wrong. Please inform yourself about what exactly do you need and if it is possible using our plugin we will help you but for the moment I think that what you ask is not possible from an IAP plugin.
Thank you for the answer~
I read that you can validate the receipt locally. So I think if can get the original purchased app version info from the receipt, I can recognize the player paid for the app or not. Can I use EasyIAP to do that?