Two months ago, I released Milk Carton Boy Shake Well for Flash mobile. I developed it using FlashDevelop, Away3D, and Flex SDK 4.1 and didn’t use any mobile specific APIs (gesture, touch, or accelerometer). Basically I just adjust the screen size for 400×678 and the game works really well on Android Browser with Flash Player.
Now I have my Samsung Galaxy S, it’s much easier to test the game. It is quite easy to convert an existed FlashDevelop’s Flash project to Android AIR project. So I immediately convert the game to Adobe AIR app and tested on my Android.
Here are some interesting things that I found during the testing:
Milk Carton Boy for Adobe AIR performs (a little bit) slower compare to Flash Player! This is quite surprising since I expect that it could run faster, well at least runs at the same speed π I’m using Adobe AIR 2.5.1.1774 and my Flash Player version is 10.1.92.8
I really need to implement a button to quit the game.Β I never see any Flash game with a quit button. That’s because we don’t need it π
When the user closes the browser or browses to other page, our Flash game will be gone automatically. However, Adobe AIR app, just like other Android app, will be moved to memory if the user press HOME button or BACK button. It will stay in the memory until the OS kills it (when it needs more memory). That’s why if you don’t explicitly quit your app, it will stay (or even keeps on playing) on background.
As a bonus, here’s what I did to convert my FlashDevelop project for Flash to FlashDevelop for Android π
- Copy your FlashDevelop project to another file name, like myGameAndroid. You can have two project files on the same project folder
- Now open you project file on any text editor (Don’t double click it). Modify the following properties:
- Pre-Build command
<preBuildCommand>taskkill /f /fi "IMAGENAME eq adl.exe"</preBuildCommand></pre>
- Build Option. Inside the
<build>
, change the <option additional=”” /> to <option additional=”+configname=air” /> - Other project options
<!-- Other project options --> <options> <option showHiddenPaths="False" /> <option testMovie="Custom" /> <option testMovieCommand="$(FlexSDK)binadl.exe;application.xml bin" /> </options>
- Pre-Build command
- Make sure that you have installed Adobe AIR SDK 2.5 on top of your Flex SDK, creates the
application.xml
, and the certificate file. See my previous post about creating Adobe AIR app for Android - Delete any files on obj folder before opening the project file
Enjoy!