MobileIAP and Cordova: Items being granted without payment

Not favoritedFavorited Favorited 0 favourites
  • 6 posts
From the Asset Store
In this template the music plays without looping in your game
  • Ever since the bug appeared where players receive store items simply by closing the payment window, and the mobileIAP plugin grants the purchase even if the payment wasn't completed. I've been searching for ways to work around this issue.

    My question is about the expression mobileIAP.transactionID, Ashley.

    Only you can clarify this, as the manual provides no explanation on how to use it.

    Does it actually return the current transaction's ID? At what point is this ID retrieved? How does the expression know which transaction is in progress?

    I'm asking because there are already bug reports about this issue, and I believe this expression might be the solution.

    I hope you can help clarify this doubt.

  • Do you have details of this bug? Sounds rather worrying!

  • citron2010The bug occurs as follows: when the player starts the purchase process and selects a regional payment method. In Brazil, for example, there's a method called Pix, which allows the user to generate a code that is used to make the payment through a banking app. The problem happens when the user simply generates this code but, instead of completing the payment, just returns to the game. What happens is that the system interprets the purchase as successful and grants the user the consumable item.

    This does not happen when the item is a non-consumable product and we use the condition "On transaction finish" together with the condition "Has product [product ID]". I’ve done several tests, and this doesn't work with consumable items. For this reason, I’m looking for information to see if it's possible to use the transaction ID to create a method to prevent this issue, but unfortunately, I haven’t yet received a response from Ashley.

  • In general if you think you've run in to a bug you should file an issue following all the guidelines. We don't normally respond to bug reports on the forum other than to say that, because usually such reports omit key information and so it's impossible for us to investigate.

    Also it's very common with bug reports for addons that integrate with third-party services - like IAP - end up just being misconfiguration or mis-use of the plugin. It's very difficult for us to support such cases as we can't see your IAP configuration or your account details, and often when we set it up we get it right, and don't see any issue. It's also particularly time-consuming to do that, so generally we have a higher bar to prove that the Construct plugin really has a bug, especially as it's been used widely by lots of people over a period of years.

    Finally if you want definitive proof that a purchase is legitimate in order to rule out things like piracy, you need to implement server-side validation. The IAP plugin has an option for using a validator URL to do that, which is a feature of the underlying cordova-plugin-purchase plugin and they also provide a service you can use for that.

  • Hi Ashley,

    Thanks for your reply, but I need to be clear: my post isn't a bug report, and I know how to file those. My concern here is the lack of clarity in the documentation, as the manual doesn't explain the use of the mobileIAP.transactionID expression.

    It's important to note that my game has had a functioning IAP store for over four years without this specific issue, which indicates it's not a simple "misconfiguration" on my part.

    I'm investigating the possibility of mobileIAP.transactionID being a way to work around the current problem where items are granted without payment. This happens specifically with methods like Pix in Brazil, but it could affect other regional payment methods.

    For this, I need to know:

    If mobileIAP.transactionID actually returns the current transaction's ID.

    At what specific point this ID is retrieved.

    And how the expression identifies which transaction is in progress.

    I hope you can focus on clarifying these specific questions about mobileIAP.transactionID, as the information isn't available in the manual and could help solve a problem affecting regional transactions.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • The manual entry says:

    In On transaction finished, the ID of the transaction that finished, using the ID provided by the store.

    I'm not sure there's much else to add - that tells you when to retrieve it and what it is. Each store transaction is assigned an ID, and that expression just returns the ID assigned by the store. Construct doesn't have any involvement in it other than passing along the transaction ID from the store to the plugin.

Jump to:
Active Users
There are 0 visitors browsing this topic (0 users and 0 guests)