Take the 2-minute tour ×
Game Development Stack Exchange is a question and answer site for professional and independent game developers. It's 100% free, no registration required.

Is there any way to convert a Flash games(file with .swf extention) to work with android devices? I want the game to use Android device native controls like sensor, accelerometer, etc.

share|improve this question
add comment

6 Answers

up vote 6 down vote accepted

petr's answer assumes you already know how to deploy a Flash app on Android; maybe you already know that, but you don't mention it in your question so I want to point out that you can package a Flash .swf as an Android .apk using AIR.

Once you are actually deploying your in-development game as an Android app then you get to the higher level concerns of adapting your game logic to the new input devices.

share|improve this answer
    
i am just starting on it thanks for your link i will look into it. –  Akram May 25 '12 at 12:36
add comment

You can convert a Flash game to run on an Android device if you package it up with Adobe AIR, with the Android SDK through terminal using -apk and you can script / code in the #import features that allow you to do some native control for the game. However, from personal experience ; I've made a couple AIR / Android games and the problem with AIR is that it doesn't handle very well. I say this that you won't be able to have an "hell-shooter" with 600 things going off on screen at once. AIR handles games decently such as Machinerium because it isn't GPU / CPU intensive. Anything above a simple point and click starts to chug.

AIR won't magically convert your game. You'll have to get your hands dirty, and change a lot of things around in AS3.

AIR though, is great for making quick prototypes for mobile games though. Just download Flash-develop and it comes with automatic AIR / Android projects.

share|improve this answer
add comment

I don't think it's possible in some "automatic" or even semi-automatic mode. The only way is to manually convert game logic into other platform. Quite possible it will be pretty strightforward process for logic part if both games use standard game loop structure. However draw, sound and input implementation can differ significantly between platforms.

share|improve this answer
    
thanks for your ans looking forward for any other idea +1 to your answer. –  Akram May 25 '12 at 10:58
add comment

There is a one application called Andaired which will help you to convert your Flash game into mobile Android game, self-signed and ready for publishing on Google Play.

It wraps Adobe AIR SDK tools and you no longer need to mess up with command lines.

share|improve this answer
add comment

At the time of this answer the only way of doing (I`m aware of) will result in an iPhone game trough Stencyl http://www.stencyl.com/. In the game I converted from Flash to Android we had to do as Petr Abdulin suggested and we even created our company own engine. However you can wait until Stencyl launch their Android/Html5 publishing build.

If you stick with converting yourself, which isn`t that difficult, I strongly recommend to pick andengine, CoronaSDK or other engine to help you, that will make your life easier.

Good luck!

share|improve this answer
add comment

Yes, you can convert swf to apk (Android), ipa (iOS) and bar (Rim) in a single pass. You can do it directly from the swf without having source (see here), but most of time you have to modify your program to handle portrait/lanscape, multitouch, et cetera.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.