A couple of weeks ago, Whitaker Trebella’s fun puzzle game Polymer was launched on the App Store.
I bought the game and played it quite a bit that week. I decided that it was a game that people who enjoyed my game Charmed might also really like, so I asked Whit if he would like a free ad for Polymer in Charmed.
Who can say no to free publicity for their new game, right? He was pretty busy with his launch activities though, so I also offered to put together an ad image in the right size for him using his App Store images and screenshots from the game.
Here’s what I came up with as it appears in Charmed. It’s simple, but to the point and not too bad.
Now, I had created an ad system for Charmed a while ago and I used it to promote my Animal Stickers kids app for iPad a while back. It worked just fine for the Animal Stickers promotion, and since Charmed has been downloaded over 360,000 times (mostly freebies), I thought it might make for a nice little boost in downloads for Polymer and help keep it up in the charts.
After putting together the ad, I tested it to make sure it appeared on my iPhone, iPod touch and iPad. Unfortunately it only appeared on my new iPad. This made me somewhat unhappy. Actually, I was pretty annoyed by it. I thought this code was all working already.
Ad System Design
- A tag id for the ad
- A URL to link to or the app ID for the app being shown (to launch directly to iTunes)
- The text for the “No” button to show in the ad dialog
- The text for the “Yes” button to show in the ad dialog
- A link to an “ad viewed” server script
- A link to an “ad clicked” server script
- A link to an image file for the actual ad to show
Once the plist has been downloaded, the code makes a decision on whether the tag id for this ad has already been seen by the user. This information is stored in a plist file locally on the device.
If it decides to show the ad, then it brings up the ad view and starts downloading the image. Once the image is downloaded, it appears in the view. This is normally so fast that you don’t notice any delay.
What Was the Problem?
I started debugging it and soon realized that I had forgotten to set the URL cache policy on the plist file that I use to store the ad information on my server.
When you leave this out, the plist file is not always retrieved from the server, and the contents of the previous plist are used from the local cache instead.
I don’t know how long this cache persists, but it was certainly long enough to cause problems with my ad system.
I had come across this same problem already with some URL handling code in Unicorn Rush and I had fixed it there, so when I saw the “old-style” URL handling code where the cache policy was not being set, I knew what was wrong right away.
This fix for the problem was very simple, but unfortunately it was a bit late to help Whit with Polymer as much as I had hope to. I needed to submit an update for Charmed to the App Store and wait a week for it to be approved (the new version is out now).
Here’s what my URL code looks like now:
NSMutableURLRequest* urlRequest = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:urlStr]]; urlRequest.cachePolicy = NSURLRequestReloadIgnoringLocalCacheData; self.urlConnection = [[[NSURLConnection alloc] initWithRequest:urlRequest delegate:self startImmediately:YES] autorelease];
- Views: 9,358
- Clickthrough Rate: 16.4%
I think that clickthrough rate is actually pretty fantastic and proves that if you show the right ad to the right audience, you’ll get a much better response than the typical 3-5%.
The Moral of the Story
If I hadn’t offered to help Whit promote Polymer, I wouldn’t have discovered this problem until I launched Unicorn Rush, and since I used the same ad system in Flight Deck, it would have had the same problem.
Promoting Unicorn Rush to my existing players is an important cornerstone of my launch strategy, and with that bug in the ad code, it could have jeopardized the launch, so I am glad that I discovered it now.
So consider helping others to help yourself.