Currently my game has an Activity for the splash screen then it starts the main class activity then it starts a menu activity then from the menu there is an activity for each option (only two at the moment), Start and About.

Splash --> Main --> Menu --> (Start, About)

The start then sets a Content View for my game to draw to the screen.

What additional parts to a game should have or require an activity and what parts that I may or may not have don't need to be an Activity.


An activity is a single, focused thing that the user can do. Almost all activities interact with the user, so the Activity class takes care of creating a window for you in which you can place your UI with setContentView(View)

Since we know what an Activity is, now I am just looking for places that it would be used in a game?


We have a great explanation of the game architecture in Android. This diagram is awesome!

enter image description here


Use a single activity. Have a look at the basic game architecture here: http://www.thegamecoder.com/blog/?p=46

Implement your menus inside the MainView class in the link.

| improve this answer | |
  • \$\begingroup\$ What other things could you want to do with a game in Android that would require more activities? Anything? \$\endgroup\$ – KRB Sep 14 '11 at 18:07
  • \$\begingroup\$ I can't think of anything. I'd handle things like web requests with an asynchronous thread of some sort. \$\endgroup\$ – ApoorvaJ Sep 15 '11 at 13:14

Have a look at Replica Island. It's written by one of the Google engineers. They use different activities for everything. But I think using one activity is way easier! Other games and some of the available game engines do it that way. The downside is that you have to implement behaviour like button presses etc. yourself.

| improve this answer | |
  • \$\begingroup\$ I was wondering about this myself, they use multi-threading too right? one for game logic /sound and one for graphics if I remember correctly. \$\endgroup\$ – bot_bot Feb 24 '12 at 14:01

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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