Switch to Book Layout1: Getting Started2: Building Logic
3: Actors
4: Scenes
5: Game Mechanics6: Advanced Topics7: Testing & Tuning8: The Last 10%M1: Mobile - IntroM2: Mobile - BasicsM3: Mobile - ServicesM4: Mobile - PublishingA: Troubleshooting
B: How-To Guides
C: ReferenceD: Resources3.0 Drafts (In Progress)
|
||
|
Level: Beginner
In-App PurchasesIn-App Purchases are an exciting new way for mobile Stencyl games to monetize and bring success to their creators. It’s well known that given a free app and a paid app, the free app will be downloaded on average, 10x as much as the paid app. This gives the creator more opportunities to monetize the free app by providing downloadable, supplementary content (new levels or game modes), an unlock for the full game, consumables and much more. Starting with Stencyl 1.4, iOS developers can add In-App Purchases to their games. Like all things Apple, the devil is entirely in setting up In-App Purchases in iTunes Connect. The amount of Stencyl-specific work is minute in comparison. What this Primer CoversThis guide will show you how to set up In-App Purchases in iTunes Connect and get you up to the critical point – getting iOS to display its standard prompt for purchasing an item. Prerequisites
Step 1: Go to iTunes Connecthttps://itunesconnect.apple.com Step 2: Set up a Sandbox Account
Step 3: Set up a new game with IAPs
What if you want to operate on an existing game? You can, but only under certain conditions that Apple dictates. For the sake of keeping this guide simple, I’m not going to cover that case today but will in the full guide. Step 4: Mark Game as Ready to UploadWhen you are ready to proceed, mark the game as Ready to Upload, but do NOT actually submit the binary! Step 5: Set up Purchases in StencylIn a gist, setting up purchases in Stencyl is a simple process.
Here are the exact steps. In this instance, we just want to prompt the player to buy a product.
Don’t test your game quite yet – there’s still one more step to go. Step 6: Prepare your Device
Step 7: Test it on the device!Now, run your game on the device. If everything was properly set up, your app should prompt you to purchase your product. Congratulations! If you are less fortunate and nothing happens after 10-15 seconds, read on. TroubleshootingSince you are testing on the device, likely through Xcode, you will see the game’s output in the lower pane. If you see something along the lines of “Error [NUM]: Cannot connect to the iTunes Store” , then you know for certain that something didn’t quite go right along the way. Here’s a list of everything we know that could go wrong. Out of your control
In your control
If none of these solutions work, ask on the forums. In-App Purchases are challenging to add, not because they’re particularly difficult, but because of the obtuse system of setting them up. Unfortunately, we have little sway in making this process easier, besides documenting every last possibility of failure.
Last Updated: 2013-04-10 by Jon
8161 have read this article
Disclaimer: The Stencyl Team does not actively monitor comments on articles. If you're seeking help for your game,
please ask a question on the forums. Thanks!
5 Comments
MikeyPB
Good Article. The only thing I tripped up on was the option to host content with Apple. I checked Yes, which was wrong (I'm certainly not hosting anything!). Thankfully, the Apple site alerted me to this when I went back to iTunes Connect (head in hands) to see what I had done wrong. You have to create a new game entry in iTunes connect (through the 'manage your apps' option). This means inputting a lot of info about your game, as it seems to be the first step to publishing. I was unprepared for this so was unsure if I was doing the right thing, just to let others know. 0 4 days, 19 hours ago
paullawton
Make sure you're not stupid like me who spent ages getting it to work because I was using the Apple ID (generated by Apple - something like 6875642) instead of the correct Product ID (entered by you - something like my.unique.product_id). There's a reason it's underlined and in bold :) 0 2 months, 1 day ago
looniegames
Hope this helps. http://developer.apple.com/library/ ios/#documentation/LanguagesUtiliti es/Conceptual/iTunesConnect_Guide/8 _AddingNewApps/AddingNewApps.html 0 3 months, 4 weeks ago |












