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.

I have fairly good experience with Java, but new to Android development. I would like to develop a 2D game which would have animations and online play.

Can I initially develop this game on my pc using Java and then implement in Android?

Will the canvas in Java be sufficient or should I use a game engine?

share|improve this question
    
"on my pc", what else would be your environment? Mac? Try to rephrase your question for more clarity. Do you, or do you not want to use the Android SDK, if so, what is your reasoning? –  Erik Jan 23 '13 at 16:20
    
I could be wrong, but I believe the questioner is of the view that developing for android must be done on an Android device. 99.9999% of android development is done on a personal computer. –  Cameron Fredman Feb 26 '13 at 22:45
add comment

6 Answers 6

It sounds like your goal here is just to make games.

Use LibGDX. With this Library you can test it and deploy it to Windows/Linux/Android/HTML5. It's also free.

share|improve this answer
1  
+1 this is an awesome feature of libGDX in my opinion. –  ashes999 Jan 15 '13 at 15:22
    
+1 Been using LibGDX for years and it is still the original and the best Android + whatever game engine :) –  aaronsnoswell Jan 15 '13 at 18:19
    
Really like libGDX, still learning it but it's absolutely delicious. –  nospamthanks Jan 24 '13 at 11:43
add comment

You would make it easier for yourself implementing a game framework. Also if you'd develop your game outside the android framework you might use libraries that don't exist on android.

I'd suggest you build and test it directly on android drom the first line of code you write while using a game framework. You can however build a big part of your game as a jar library so you can re-use parts of it. This library can then be imported in your android project and you can see if it runs (and your not missing libs etc)

share|improve this answer
add comment

LibGDX is my weapon of choice, note though that many of the tutorials out there are set up pre-0.9.6 and quite a lot got changed in that update, rendering most of them useless. https://www.youtube.com/user/doctoriley has a decent series of tutorials which should give you a starting point (not exactly best practice but you get to understand how it all hangs together) and the code can be found at https://bitbucket.org/GQGK/creating-a-game-in-java-youtube-series/overview if you want it.

LibGDX is excellent, a layer on top of lwjgl which provides support for Android, desktop (win/lin/mac) and html5 (though frankly I'd say just use an applet instead as it's quite limited) and I believe work-in-progress iOS support too.

The documentation is relatively solid (though the wiki is incomplete and outdated) and it has been used in commercial projects.

share|improve this answer
add comment

There is great blog just for you with number of tutorials for game development for Windows, Mac and Android with Java. Check out this tutorial: http://obviam.net/index.php/getting-started-in-android-game-development-with-libgdx-create-a-working-prototype-in-a-day-tutorial-part-1/

Unfortunately author of the blog stopped writing, but nevertheless it's a great start, and I've done most of tutorials in August and they were all valid.

share|improve this answer
    
Do they still work with the post 0.9.6 stage2d refactoring? –  nospamthanks Jan 24 '13 at 11:42
    
To be frank I don't know. I used latest stack of libgdx and android 4.1 sdk this august, but didn't see if tutorial is valid after that. –  nirth Jan 27 '13 at 19:11
add comment

Android does support the native Java API, but it is heavily reliant on the extended Android-specific API. If you really want to do this, then I would advise writing as much of the game logic completely independent of the platform interface (a good practice anyway).

I would recommend working directly with the Android API though.

share|improve this answer
add comment

Yes, you can make Android Game without the prior knowledge of JAVA and without Android SDK. It is a Hypernext Android creator which gives you complete environment to make an Android game.

share|improve this answer
    
I'd suggest from the original question stating the desire to build the game in java and then port to android that java is not a problem, and likely the user wants to have both platforms working. –  nospamthanks Jan 24 '13 at 11:42
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.