In my project, UnityIAP looks like work properly on Window computer, when I just use unity run function.
Here is log.
UnityIAP Version: 1.22.0
UnityEngine.Purchasing.StandardPurchasingModule:Instance()
IAPManager:InitializePurchasing() (at Assets/Scripts/IAPManager.cs:39)
Using configuration builder objects
UnityEngine.SetupCoroutine:InvokeMoveNext(IEnumerator, IntPtr)
OnInitialized: PASS
UnityEngine.Debug:Log(Object)
IAPManager:OnInitialized(IStoreController, IExtensionProvider) (at Assets/Scripts/IAPManager.cs:183)
UnityEngine.SetupCoroutine:InvokeMoveNext(IEnumerator, IntPtr)
UnityIAP: Promo interface is available for 3 items
UnityEngine.SetupCoroutine:InvokeMoveNext(IEnumerator, IntPtr)
[when I hit purchase button]
Purchasing product asychronously: ‘com.illill.perpl.coin250’
UnityEngine.Debug:Log(Object)
IAPManager:BuyProductID(String) (at Assets/Scripts/IAPManager.cs:116)
IAPManager:Buy250Coin() (at Assets/Scripts/IAPManager.cs:68)
Get_stage:ClickBuy() (at Assets/Scripts/Start_menu/Get_stage.cs:38)
UnityEngine.EventSystems.EventSystem:Update()
ProcessPurchase: PASS. Product: ‘com.illill.perpl.coin250’
UnityEngine.Debug:Log(Object)
IAPManager:ProcessPurchase(PurchaseEventArgs) (at Assets/Scripts/IAPManager.cs:214)
UnityEngine.Purchasing.PurchasingManager:InitiatePurchase(Product)
IAPManager:BuyProductID(String) (at Assets/Scripts/IAPManager.cs:119)
IAPManager:Buy250Coin() (at Assets/Scripts/IAPManager.cs:68)
Get_stage:ClickBuy() (at Assets/Scripts/Start_menu/Get_stage.cs:38)
UnityEngine.EventSystems.EventSystem:Update()
UnityIAP: Promo interface is available for 3 items
UnityEngine.Purchasing.PurchasingManager:InitiatePurchase(Product)
IAPManager:BuyProductID(String) (at Assets/Scripts/IAPManager.cs:119)
IAPManager:Buy250Coin() (at Assets/Scripts/IAPManager.cs:68)
Get_stage:ClickBuy() (at Assets/Scripts/Start_menu/Get_stage.cs:38)
UnityEngine.EventSystems.EventSystem:Update()
purchase({0}): com.illill.perpl.coin250
UnityEngine.Purchasing.PurchasingManager:InitiatePurchase(Product)
IAPManager:BuyProductID(String) (at Assets/Scripts/IAPManager.cs:119)
IAPManager:Buy250Coin() (at Assets/Scripts/IAPManager.cs:68)
Get_stage:ClickBuy() (at Assets/Scripts/Start_menu/Get_stage.cs:38)
UnityEngine.EventSystems.EventSystem:Update()
But when I build and publish android app, purchasing button doesn’t work.
I already published my app on production track. So I want to fix it as soon as possible…
please help me…
Here is log when I launch my app and hit purchase button on android phone.
07-02 13:43:36.633 27550 28251 I UnityIAP: Owned items response: 0
07-02 13:43:36.633 27550 28251 I UnityIAP: Continuation token: null
07-02 13:43:36.633 27550 28251 I UnityIAP: Querying SKU details.
07-02 13:43:36.643 27550 28251 I UnityIAP: Querying owned items’ purchase history, item type: subs
07-02 13:43:36.643 27550 28251 I UnityIAP: Package name: com.illill.perpl
07-02 13:43:36.643 27550 28251 I UnityIAP: Calling getPurchaseHistory with continuation token: null
07-02 13:43:36.713 27550 28251 I UnityIAP: Purchase history response: 6
07-02 13:43:36.713 27550 28251 I UnityIAP: getPurchaseHistory() failed: 6:Error
07-02 13:43:36.713 27550 28251 I UnityIAP: Querying owned items’ purchase history, item type: inapp
07-02 13:43:36.713 27550 28251 I UnityIAP: Package name: com.illill.perpl
07-02 13:43:36.713 27550 28251 I UnityIAP: Calling getPurchaseHistory with continuation token: null
07-02 13:43:36.753 27550 28251 I UnityIAP: Purchase history response: 6
07-02 13:43:36.753 27550 28251 I UnityIAP: getPurchaseHistory() failed: 6:Error
07-02 13:43:36.753 27550 28251 I UnityIAP: onQueryInventoryFinished: false
07-02 13:43:36.753 27550 28251 I UnityIAP: Error query Purchase History (response: 6:Error)
07-02 13:43:36.753 27550 28251 I UnityIAP: Failed to Query inventory. UnityIAP will automatically retry in 300000ms
07-02 13:43:36.753 27550 28251 I UnityIAP: QueryInventory: 3
07-02 13:43:36.753 27550 28251 I UnityIAP: invoking callback
[when I hit purchase button]
07-02 13:45:00.543 27550 29710 I Unity : BuyProductID FAIL. Not initialized.
07-02 13:45:00.543 27550 29710 I Unity : UnityEngine.Logger:Log(LogType, Object)
07-02 13:45:00.543 27550 29710 I Unity : UnityEngine.Events.UnityEvent:Invoke()
07-02 13:45:00.543 27550 29710 I Unity : UnityEngine.EventSystems.ExecuteEvents:Execute(GameObject, BaseEventData, EventFunction`1)
07-02 13:45:00.543 27550 29710 I Unity : UnityEngine.EventSystems.StandaloneInputModule:ProcessTouchPress(PointerEventData, Boolean, Boolean)
07-02 13:45:00.543 27550 29710 I Unity : UnityEngine.EventSystems.StandaloneInputModule:ProcessTouchEvents()
07-02 13:45:00.543 27550 29710 I Unity : UnityEngine.EventSystems.StandaloneInputModule:Process()
07-02 13:45:00.543 27550 29710 I Unity :
07-02 13:45:00.543 27550 29710 I Unity : (Filename: ./Runtime/Export/Debug.bindings.h Line: 45)