IAP sytem breaks on second attempt, Callback not called — Oculus
Welcome to the Oculus Developer Forums!

Your participation on the forum is subject to the Oculus Code of Conduct.

In general, please be respectful and kind. If you violate the Oculus Code of Conduct, your access to the developer forums may be revoked at the discretion of Oculus staff.

IAP sytem breaks on second attempt, Callback not called

I am testing a Gear VR alpha build developed on Unity 2018.2.20f1 using the Oculus Integration 1.36.
I am using the credit cards mentioned for testing IAP items via a test user.

Steps :
  1. Purchase an IAP item (Consumable or Durable), is purchased successfully if using the 'Always succeeds' card or purchase fails on using the 'Always Fails' test card but both operations return via the LaunchCheckoutFlow Callback.
  2. Attempt to purchase any other IAP item similar to point 1. The Oculus home is loaded with the loading animation displayed and then abruptly returns back to the game without any purchase. The Oculus.Platform.IAP.LaunchCheckoutFlow callback is not called in the process so it is stuck on the game loading screen.

The above happens if an 'always succeeds' test credit card is used.
If an 'always fails' test credit card is used the same happens but instead of the Oculus Home loading animation that can be seen for a while the number pad from the previous purchase attempt can be seen for maybe a second before the app loads back into the game window without calling the LaunchCheckoutFlow Callback similar to the 'Always Succeeds' card test.

I have used leaderboards, achievements, pricelist retrieval etc and all seem to be working fine.



The checkout code is as follows, however, the callback 'LaunchCheckoutFlowCallback_COINS' is not called on the second purchase.

private void purchaseCoins(string a_strSKU)
{
Oculus.Platform.IAP.LaunchCheckoutFlow(a_strSKU).OnComplete(LaunchCheckoutFlowCallback_COINS);
}

private void LaunchCheckoutFlowCallback_COINS(Oculus.Platform.Message<Oculus.Platform.Models.Purchase> a_Msg)
{
if (a_Msg.IsError)
{
GameManager.DisplayNotificationForGivenTime(GameManager.NOTIFICATION_TITLE_ATTENTION, GameManager.ERROR_MSG_USER_IAP_PURCHASE_FAILURE);
UI.UI_LoadingPanel.ToggleDisplay(false);
return;
}
Oculus.Platform.IAP.ConsumePurchase(a_Msg.GetPurchase().Sku);
UI.UI_LoadingPanel.ToggleDisplay(false);
}

Comments

  • NinjaGaijinNinjaGaijin Posts: 191 Oculus Staff
    @FretBuzzBoogie Welcome to the Oculus Developer Forums!

    Thank you for the heads up (and for the bug report). Our engineering team is aware of this and working on a fix.
    If you need immediate help or want additional support/context on an issue you are having with our platform or integrations:

    1. Gather any and all logs, screenshots, and version numbers of relevant software (Oculus SDK, engine, etc.)
    2. Please submit a ticket here (include what you've gathered in step 1).
    3. Tag me @NinjaGaijin once you have done so!
  • FretBuzzBoogieFretBuzzBoogie Posts: 2
    NerveGear
    @NinjaGaijin Hi NinjaGaijin, is there any update on this bug, I've checked the latest Unity Oculus 1.37 SDK and the bug still exists in the IAP. The bug is marked as fixed on the bugs portal.

    Will it be fixed in future SDK's or is it a bug on the Oculus services side and could you give me an estimate if possible?

     Thank you.
Sign In or Register to comment.