Testing In App Purchases

Testing In App Purchases can be a tricky business and each platform requires its own setup. The following sections briefly explain how to get the testing process set up correctly for the platforms that support it. 

iOS

For in app purchase testing with the iOS module, you must fulfill the following requirements:

  • For testing on iOS, you must have ticked the "Sandbox Mode" option in the Global Game Settings - In App Purchases Tab, although your app will not properly simulate communication with the store since it uses a local proxy file to simulate the store state for the app.
  • You will need to have created a new App Id in your iTunes Connect profile, with in app purchases enabled.
  • The product must be added to iTunes Connect and the "Cleared for Sale" check box marked otherwise testing will not work.
  • You will need a "Test User" to your iTunes Connect account, and have signed out of your normal account on your test device. When testing, use the test user information when prompted.

Android

Android devices can use in app purchases on either the Google Play Store or the Amazon App Store. For Google Play, setup is simple and after programming your app, you can test it easily by creating an executable, uploading it to your Google Play developers page and making sure to enable the in app purchases from the appropriate section. You do not need to publish the app yet. Please note the following:

  • For testing purposes on Google Play, the version number of your test *.apk has to be the same (it may accept a higher version number) as the version of the APK you’ve uploaded.
  • On Google Play, until you’ve published a title the only accounts that will be able to make purchases are test accounts you’ve registered at the given test URLs (under “Edit Profile – Test Accounts”)

For testing in app purchases with Amazon, things are slightly different. You will need to code the IAPs in your game as you would for a release, then go to your Amazon developer page and set up the app for Live App Testing. With Live App Testing you can share your game with a group of testers who can then download it and test all the features, including IAP, with no charges actually being made to the accounts. This greatly simplifies testing and is easy to set up - Amazon have a full walkthrough for you to follow on their developer pages here: Getting Started With Live App Testing.

When uploading your APK for testing (and when it goes live) don't forget to tick the Amazon Store box in the Global Game Settings and GameMaker:Studio.

Tizen

For Tizen in app purchases, you can test with a Tizen device, but not with the emulator and you must have uploaded a version of the game to the Tizen Store, and registered an "Item group ID" for your game and purchases. This should then be added to the Global Game Settings In App Purchases Tab in the appropriate section.

Once that is done, you can test purchases on your developer device, with the following things to note:

  • You must have installed the "IAP Client TPK" and "Tizen Account TPK" on the developer device (see the READ_ME here for information on how to achieve this). Note that commercial devices will not need this as the files will have been pre-installed.
  • You will need a Tizen Store account to be able to buy anything, and this is only available through signing in on your developer device.
  • When you activate your purchases using iap_activate, you should supply an empty ds_map as as GameMaker: Studio will pull all the product details directly from the store.
  • You should be aware that currently Tizen, as a new OS for devices, is undergoing constant changes, and this may mean that certain things break or do not work until the final commercial version is released and the Tizen Store is online.

Windows 8

The Windows 8 target works with In App Purchases, but there are a few important differences with how it works compared to iOS and Android:

  • For testing on Windows 8, you must have ticked the "Sandbox Mode" option in the Global Game Settings - In App Purchases Tab, although your app will not properly simulate communication with the store since it uses a local proxy file to simulate the store state for the app.
  • You must have the "Use Internet" checkbox enabled in the Global Game Settings - Windows 8 Tab to successfully download content.
  • Consumable purchases are not explicitly supported by the Windows Store, although this will be available in a future update.

Windows Phone

Windows Phone in app purchases are simply set up by creating your game with the necessary code and doing either:

Or:

  • Create your app and upload it to the Windows Phone store, marking it as a "beta" project. You can then test your purchases directly.
Have more questions? Submit a request

0 Comments

Article is closed for comments.
Powered by Zendesk