Sunday, January 26, 2014

In-App Billing and Testing

My main focus of my projects recently has been getting In-App billing working in the scrolling shooter. I've been right on the cusp of having it working properly. Several times in the past week I got into it, lost track of time, and ended up staying up far too late and was wiped out at work the next day. However, I'm about 90% confident that I now have it working. Initially, the player has free access to the first two levels. They have to beat the first level to open up the second level, of course, and then anybody can get the third level by using the in game link to like Downplay Games on facebook. So really, there are three free levels in the game. To unlock the other 10 (plus the gauntlet mode I mentioned in my previous post) they have to buy the full version. On the main menu screen there is a "Buy Full Version" button that takes you to a Google Play purchase pop up and once you fill out all that, it unlocks the full version. At that point, of course, the player can play all 10 levels, but they still need to beat all the previous levels. So to get to level 10, you need to complete levels 1-9.

I've actually had the purchasing of the full version implemented for a long time. What I've been struggling with is the functionality to actually query Google Play and confirm that the full version is in fact purchased. So users could buy the game, but the game didn't know that they had and nothing unlocked as a result. My preliminary tests are very positive.

This week I purchased two new android phones from a craigslist posting to test on. Well, I gave Tia money and she bought them for me while I was at work, so big thanks to her for that! Anyway, with two more test phones I've been able to test the in-app billing pretty well. It's very hard to do, because first of all, you can test purchasing with your developer account, so my main phone is out. Then, on top of that, once you buy the full version on a test phone that does work, you can't test it on that phone again without a huge time consuming hassle. To repeat test on a phone, you have to refund and cancel the order via google wallet, then wait about 3 days for google to actually process all these changes (during which time the test account retains the full version) until finally things are set back up. Very annoying with only a single test phone to test, wait three days, test again. Now I have 3 test phones though so less of a hassle, but still a hassle. I tested the purchasing with my first test phone before I had the purchase state querying working fully, so that didn't work. Luckily it was pretty solid by the time I got around to testing on my new phones, so things appear to be working well.

As a bonus, I've rooted one of the new test phones and bought a screen recording program that runs smoothly on it so I can finally take videos of games for youtube trailers and such. Before, we had the same program on a rooted phone of Tia's that I was borrowing, but I've had it for like a year, and now I could finally give it back to her since I have the video capture stuff covered on my own now.

Now I just need to do a little more testing of the in app billing stuff, and tweak a few gameplay things, plus add a few options to the settings page (toggle off vibration when the player takes damage). Now that in app billing is looking solid, I think I'm finally ready to start trying to find an artist since there isn't any major hurdles left in the project.

Sunday, January 12, 2014

Finishing Up the Scrolling Shooter

I've been finishing up some last details with my arcade scrolling shooter. My brother has been play testing it and we've been tweaking the difficulty of things and adding some gameplay changes that were needed. Nothing major, but collectively a lot of changes. One thing I did add that is significant is a new game mode that is unlocked once the player unlocks all the normal levels. This new mode is kind of a gauntlet that pits the player against enemies from all the levels all together, one after another. I think it's pretty fun.

One thing I still want to do is to add a simple text area on the level select screen that gives the players general tips and suggestions about how to play the game. I'm going to try to thing of some tips and then throw them all in a string file, then randomly grab one from there and use it to populate the text when the level select screen is created.

Additionally, I'm excited to get working on the in app billing for the game. This will be the first game that I've done that has just a single version. My previous games and apps have had a Lite version and a Full version. I'm working on getting Google's in app billing to work where the game comes with 2 or 3 levels initially and then the user can purchase the rest. This is something I've wanted to work on for quite a while, but due to some weird restrictions with Google play, I can't test in app purchasing with my developer account and I cant change the account that's tied to my phone without doing a factory reset, which I've been unwilling to do. The reason I'm excited now is that I recently got a new phone and so my old phone has just become a test device. I haven't done the factory reset on it yet, but once I am sure that all my content there is backed up, I'm going to reset it and set it up with a test account email and then I will be able to get things finalized. I tested the purchasing with my brother's phone and it successfully allows you to buy the full version, but right now that doesn't actually do anything because I haven't actually coded in any level restrictions based on the state of the player's purchases. It's not something I'm worried about though. Shouldn't take too long to get things set up how I want them once I get around to it. Things are looking good for the game but now I need to start looking for an artist to come on board and help me out with making things look good.