Color By Shape for iPad is now available on AppStore
I'm happy to announce that the new "Color By Shape" app is now available on the Apple AppStore: http://itunes.apple.com/app/color-by-shape/id475203362.
The landing page crated by martycud.com is available here: http://sierakowski.eu/colorbyshape/.

This time the approval process was very slick, the app was available 4 working days after submission. As with the release of Jumping Droid/Robot I'm sharing couple of technical tricks and techniques I used and issues I faced when working on this project in the AS3 Tips section of this blog. If you played the game, please share your comments :)
Jumping Droid and Jumping Robot landing page
Jumping Droid and Robot have got a very nice landing page: http://sierakowski.eu/jumpingrobot/ designed by martycud.com. I hope you gonna like it :)


Jumping Droid rejected on Apple AppStore for using Droid
"Jumping Droid" unfortunately didn't make it to the Apple's AppStore. Of course I didn't expect that Apple would easily accept a game with running Droid but I was hoping there was a chance when I found another game called "Super Droid World" and recently "Kill the Droid!".
Actually problems arised at the very beginning. The whole process of becoming an Apple Developer was a real pain. The game was ready to submit on May 11th and I thought it would be quick and straightforward process similar to submitting the same game to the Amazon AppStore. Unfortunately I faced the first obstacle when it came to paying $99 subscription fee. It turned out that there was no online store that would allow making the payment in Ireland. The only way to pay was to send a fax to Apple American number with credit card details (!!!). Like many people around, I don't even have a landline as having cell phone and internet is just enough these days. I know that there are online websites providing fax services, but come on, who wants to send a scan of your credit card details to people you don't know? When I found somebody with a fax machine, it turned out that my Visa Electron wouldn't work with Apple so I used my other standard Visa card from different bank that had actually my second address assigned to it. And I forgot that this address didn't match the address that I had typed when signing up for developer account. So after a week I received another document called Identity Verification Form requesting a copy of my driving licence or passport signed or stamped by a solicitor. When I explained back to Apple support what was the reason for these address discrepancies and that I would love to correct my address on the website, they just sent me that form again. Fortunately I live in a country where English is a first language, but just imagine if you are in a non-English country... such a small mistake may cost you going to a court interpreter to translate this Apple's form to your native language, then going to your solicitor, who can now read and understand what Apple wants and then going back to the court interpreter in order to translate already stamped document back to English so Apple can understand it. Anyway the whole thing took a while but finally I became a proud Apple developer. I'm happy to confirm that if you live in Ireland you can still submit your apps online and you don't have to send CDs with your app burned to Cupertino ;)
Anyway, the reason for rejection is point 8.5 of Apple Review Guidelines, which is: "Use of protected 3rd party material (trademarks, copyrights, trade secrets, otherwise proprietary content) requires a documented rights check which must be provided upon request". As a more detailed explanation I got this: "We found that your app contains features that may infringe on rights owned by Google Inc., which is not in compliance with the App Store Review Guidelines.".
But Google is very clear about using the Droid robot picture and Droid word in the apps names http://www.android.com/branding.html. They basically say that "Android Robot can be used, reproduced, and modified freely in marketing communications ... proper attribution is required under the terms of the Creative Commons Attribution license.". So what is a proper attribution? Under this link http://code.google.com/policies.html#attribution Google gives an example of what kind of attribution sentence is required when some portion of a page was used in a project "Portions of this page are modifications based on work created and shared by Google and used according to terms described in the Creative Commons 3.0 Attribution License.". I have written that sentence on the About screen of the game. Regarding Android official names they say that "Any name with 'Droid' alone may not be used in a name." which is fine, my game is called "Jumping Droid", not just "Droid". So I think there is no issue here, "Jumping Droid" meets all requirements in regards to Google.
I wrote all this above as a response to Apple but the only thing I have got back from them was the week after: "Thank you for your response and attention to the copyright issue. We appreciate your patience as we review your representation.". In the meantime I found there was another game available on the AppStore called "Kill the Droid!" http://itunes.apple.com/us/app/kill-the-droid!/id451513461 and I can't see any difference between that game and mine except the fact that the other one is targeted against Droids ;) while mine is neutral. The "Super Droid World" game http://itunes.apple.com/us/app/super-droid-world/id435410094 had already been available before I submitted the "Jumping Droid" for the first time.
It has already been a couple of weeks since the "Jumping Droid" was rejected and I still haven't got answers to my question why was my game rejected and other Droid games not. But rather then just wasting my time and waiting for nothing, the brother of Jumping Droid was born called "Jumping Robot" and he had more luck with Apple's approval process: http://itunes.apple.com/us/app/jumping-robot/id451002961.
Jumping Droid runs 60 frames per second on iPod Touch with AIR 2.6
Keeping the same game code for Android and iOS I have been able to make the game running fast on both platforms!
As I mentioned already in a previous post, despite some hardware and software differences it is easy to detect the platform and enable or disable some game features. Apple's iDevices are lacking Menu button but I didn't want to loose the options menu that pauses game, disables/enables sound or comes back to the main menu. So I placed a droid-looking menu button on the screen instead. Another thing that is different is that there is no option to programmatically force to quit an app on iOS as this could be done by pressing Home button. So Quit button that is available when running game on Android is not added to a stage on iOS and other buttons are repositioned. And one last thing is that in version 1.4.0 of Jumping Droid I decided to use masks for the floors' holes to improve look of the game backgrounds. AIR 2.6 supports GPU acceleration for masks and I was getting very similar performance with and without them. I didn't notice any difference with masks on Samsung Galaxy S as well, but HTC Desire dropped to 29 fps... So I'm leaving Android version without masks for now.
In the version 1.3.0 of the game I added dynamic frame rate so when the game is paused or when the user is in one of the menu screens or the game is working at the background (as it was interrupted by a phone call or the user just switched to different app) then frame rate is set to 10 to conserve battery consumption.
You may wonder what's the best way to detect at runtime on what platform the game is running on? I use Capabilities class:
if (Capabilities.manufacturer.toLowerCase().indexOf("ios") != -1) { //do some iPhone/iPod/iPad specific stuff } else if (Capabilities.manufacturer.toLowerCase().indexOf("android") != -1) { //do some Android specific things }
So as the game is not available (yet?) on the Apple Appstore, you can have a look how it performs on iPod Touch. And check the last minute of the movie to see the level with over 20 enemies.
Is crossplatform and multiscreen development possible with the Flash Platform?
Is it possible to write one code, use the same graphics assets and deploy a succesfull game/app on both Google Android and Apple iOS devices?
The first thing to clarify is what do "crossplatform" and "multiscreen" mean? Cross-platform or multi-platform means that an application works on multiple different operating systems or hardwares. In Flash world (or rather AIR) this would mean working on Windows, Mac, Linux on desktop computers and iOS, Android and Blackberry Tablet OS on mobile devices. Multi-screen means that an app is designed to work correctly on devices with different screen resolutions. So properly developed app's should change graphical layout to correctly fit (look good) on desktops, smartphones and tablets screens.
And in regards to the main question of this article - of course I wouldn't be writing this post if it wasn't :) Hey, enough of empty words, I know that you want to see some evidence? Well I'm happy to say that I just took my Jumping Droid game code and assets created originally for AIR for Android project and compiled first with the Adobe iPhone Packager from Flash Professional CS5 and then with the AIR 2.6 and I couldn't believe that it works straight away and actually the animation seems to be even smoother! As you may expect there are small differences, such as the fact that iPhone doesn't have a hardware Menu button that I used to pause the game and I will need to create one on the screen instead. Also another "feature" of iOS is that it doesn't provide an option to quit apps and the only way to do that is to press the iPod/iPhone/iPad's Home button. Anyway, it is going to be only a small code modification to either enable or disable some hardware specific features.
Ok I know what you are thinking now - stop talking and show me the example :)
Let me know what you think. In next couple of days when I will be back from bank holiday weekend I will show you a new version of the game with the Menu button on screen running 60 fps on iPod Touch 3rd gen!
Jumping Droid submitted (and approved) on Amazon Appstore for Android
"Amazon Appstore for Android" was opened 22 March 2011 and quickly became famous because it offers some paid Android apps for free, it allows test - drive apps before purchasing and finally because of Apple objections to use "appstore" name.
When it comes to publishing, the main difference to Google's Android Market is that all submitted apps need to be reviewed and approved by Amazon personnel. So I wasn't sure what kind of time frame I could expect from submitting to approval. I read other developers stories and it was vary, sometimes few days, sometimes weeks. Reviewers had obviously some backlog just after opening the store but later they seemed to approve apps quicker. I submitted Jumping Droid today (27/04/2011) and I'm hoping it won't be rejected :)
[Update: the game was successfully approved 04/05/2011 - just week after submitting! - Now I submitted updated version 1.3.0 and it is another week of waiting for approval. And guys not only checked the game but even corrected & improved the game description - need to work harder on my english... :)]

http://www.amazon.com/sierakowski-eu-Jumping-Droid/dp/B004Z92U8C/qid=1305134954.
AIR developers can submit their apps to Amazon Appstore without any code modifications but they have to be published specifically for it. This means that two separate apk files will need to be created - for Android Market and for Amazon Appstore. By default ADT creates apps with download URL for Android Market and Amazon Appstore requires this URL to be changed to http://www.amazon.com/gp/mas/dl/android?p=com.adobe.air.
So if you are publishing to Amazon Appstore, the adt command should be as follows:
adt -package -target apk -airDownloadURL http://www.amazon.com/gp/mas/dl/android?p=com.adobe.air -storetype pkcs12 -keystore yourkey.p12 yourapp.apk yourapp-app.xml yourapp.swf icon36x36.png icon48x48.png icon72x72.png
To learn more, visit Adobe article by Christan Cantrell: http://blogs.adobe.com/cantrell/archives/2011/03/air-2-6-applications-and-the-amazon-appstore-for-android.html.
Jumping Droid published on Android Market
"Jumping Droid" is my first serious multi-screen project published with AIR 2.5. I took me a while to complete it, the game itself and the logic behind it is quite simple but optimisation work to get in working at 30 frames per second was really challenging.
The idea is based on the classic ZX Spectrum game by Albert Ball / Imagine Software "Jumping Jack" from 1983 http://www.youtube.com/watch?v=Ai-ocyGR_LQ. Few of my initial concepts didn't really work and I had to redo some parts of it from the scratch. One of the goals was to avoid using bitmaps designed for one screen resolutions only as I wanted this game to work on various devices including 320 x 480 and 960 x 640 iPhones & iPods as well as 800 x 480 HTC Desire or Samsung Galaxy and tablets with 1024 x 768. So actually I didn't really specified any target screen resolutions, the game detects device parameters and rescales all the sprites to adjust a device's screen layout and then converts them to bitmap data. This way the quality of all objects on a screen is perfect on every device and converting everything to bitmaps and using of the GPU guarantees great performance.
I think every ActionScript developer should try to develop even a simple app or a game for mobiles to check his/her optimisation skills. I never faced half of these problems when working on desktop projects. There are some things that are mobile-specific but many can and should be used in desktop projects as well. Well, to be honest I learnt a lot and I'm going to write an article about optimisation tips in general and for mobiles soon.
In the meantime you can download and play "Jumping Droid" on your Android device from Android Market: https://market.android.com/details?id=air.JumpingDroid.
If you want to check the memory usage or number of frames per second then fine :) I left the option for that in About menu on the main game screen.
If you don't want to or can't play :) then just watch the YouTube movies to see how it performs on Samung Galaxy and HTC Desire:
Let me know your comments, opinions or if there are any bugs that you found when playing it :) There shouldn't be any!

