Search Unity

[Closed] IAP Related Issue

Discussion in 'Unity IAP' started by AllanMSmith, Jan 11, 2016.

Thread Status:
Not open for further replies.
  1. AllanMSmith

    AllanMSmith

    Joined:
    Oct 2, 2012
    Posts:
    180
    Hey,

    We were using a plugin for In-App purchasing but switched over to Unity's solution as we were having a few issues on android builds using our previous plugin. Unity In App is working nicely, we managed to make receipt validations and so forth, everything seems to be working fine. However, for some reason... after we implemented unity in-app, sometimes our game kind of get stuck on the loading scene... no errors thrown, no nothing, it just stays there... I've tested multiple times and by just removing the UnityPurchasing folder from plugins solves the issue so I'm guessing it must be somehow related.

    Since there is no error... no nothing in Xcode while running the project on the device, I have no idea what the issue is, its actually hard to say with a 100% certainty that its Unity IAP that is causing the issue... btw, I actually see the debug log telling me that inapps have been successfully initialized before the game gets stuck...

    Just wanted to know if anyone has any idea what might be causing this issue? anyone had similar issue? Btw, I tried only removing the "Initialize Purchases" call, but the game got stuck anyway... I literally had to remove the UnityPurchasing folder for the game to start working properly again.

    Thanks in advance,
    Allan
     
  2. Banderous

    Banderous

    Joined:
    Dec 25, 2011
    Posts:
    669
    You can pause the app in XCode when it enters this state to see what it is doing; select Debug > Pause

    Then please send a screenshot of the stack trace of the main thread, as in the attached example.
    Screen Shot 2016-01-12 at 11.37.39.png
     
  3. Banderous

    Banderous

    Joined:
    Dec 25, 2011
    Posts:
    669
    If you still saw the hang despite not initialising IAP then it cannot really be an IAP bug. It may more likely be a deadlock which may or may not be triggered depending on the timing of different pieces of code; removing the purchasing folder may slightly affect the loading times thus being a way to trigger the deadlock.
     
  4. AllanMSmith

    AllanMSmith

    Joined:
    Oct 2, 2012
    Posts:
    180
    I wasnt able to test this because due to animation related unity bugs in 5.3.1 I had to roll back to 5.2.4, which doesnt have the in-app purchasing in it, so I'm back to using my old plugin. Haven't run into this issue again since then. When I can go back up a version I will be sure to update this thread if I manage to get this issue again.

    Anyway, thanks for the answer!
     
Thread Status:
Not open for further replies.