• Announcements

    • khawk

      Download the Game Design and Indie Game Marketing Freebook   07/19/17

      GameDev.net and CRC Press have teamed up to bring a free ebook of content curated from top titles published by CRC Press. The freebook, Practices of Game Design & Indie Game Marketing, includes chapters from The Art of Game Design: A Book of Lenses, A Practical Guide to Indie Game Marketing, and An Architectural Approach to Level Design. The GameDev.net FreeBook is relevant to game designers, developers, and those interested in learning more about the challenges in game development. We know game development can be a tough discipline and business, so we picked several chapters from CRC Press titles that we thought would be of interest to you, the GameDev.net audience, in your journey to design, develop, and market your next game. The free ebook is available through CRC Press by clicking here. The Curated Books The Art of Game Design: A Book of Lenses, Second Edition, by Jesse Schell Presents 100+ sets of questions, or different lenses, for viewing a game’s design, encompassing diverse fields such as psychology, architecture, music, film, software engineering, theme park design, mathematics, anthropology, and more. Written by one of the world's top game designers, this book describes the deepest and most fundamental principles of game design, demonstrating how tactics used in board, card, and athletic games also work in video games. It provides practical instruction on creating world-class games that will be played again and again. View it here. A Practical Guide to Indie Game Marketing, by Joel Dreskin Marketing is an essential but too frequently overlooked or minimized component of the release plan for indie games. A Practical Guide to Indie Game Marketing provides you with the tools needed to build visibility and sell your indie games. With special focus on those developers with small budgets and limited staff and resources, this book is packed with tangible recommendations and techniques that you can put to use immediately. As a seasoned professional of the indie game arena, author Joel Dreskin gives you insight into practical, real-world experiences of marketing numerous successful games and also provides stories of the failures. View it here. An Architectural Approach to Level Design This is one of the first books to integrate architectural and spatial design theory with the field of level design. The book presents architectural techniques and theories for level designers to use in their own work. It connects architecture and level design in different ways that address the practical elements of how designers construct space and the experiential elements of how and why humans interact with this space. Throughout the text, readers learn skills for spatial layout, evoking emotion through gamespaces, and creating better levels through architectural theory. View it here. Learn more and download the ebook by clicking here. Did you know? GameDev.net and CRC Press also recently teamed up to bring GDNet+ Members up to a 20% discount on all CRC Press books. Learn more about this and other benefits here.
Sign in to follow this  
Followers 0
tom_mai78101

If you're developing games on an old smartphone with Android 4.0 installed, what should I do with the menu button?

9 posts in this topic

[url="http://androidandme.com/2012/01/news/google-the-menu-button-is-dead-and-thats-a-good-thing/"]According to this article here,[/url] Google announced that Android no longer requires a dedicated Menu button.

Since I have an HTC Evo 3D phone, with Android 4.0 installed, I have a menu button. What should I do with it?

And how do I use the new "Action Bar" on Android 4.0?

Thanks in advance.
0

Share this post


Link to post
Share on other sites
The menu button has been gone since 3.x; you won't find it on most tablets. They also don't have a search button.

If you want to take advantage of specific buttons then do so, just realize that you cannot count on any button actually being present and usable by your app.
0

Share this post


Link to post
Share on other sites
It's slightly trickier then that. The action bar provides a lot of great features the android dev site has an extensive article on how to use it ([url="http://developer.android.com/guide/topics/ui/actionbar.html"]http://developer.android.com/guide/topics/ui/actionbar.html[/url]). But you also have to bear in mind the common android dev issue of compatibility. Unfortunately 81% of the android devices are current are using 2.2 or 2.3 ([url="http://developer.android.com/about/dashboards/index.html"]http://developer.android.com/about/dashboards/index.html[/url]) which is what most developers build against. So, you will need to decided what your support strategy will be for 4.0+ users and 2.2 and 2.3 user who make up the bulk of the user base. The action bar is just one of the many features that you'll be unable to fully use on older devices. Others include direct wifi connective

It maybe that you release a 2.2 and 4.0 version of your app and maintain two codes bases. Or you use the compatiability back to provide limited support on legacy devices, or various other tricks.
1

Share this post


Link to post
Share on other sites
For compatibility issues, isn't there a way to detect if the Android OS my app is being run on is a version older than 3.X?

I used to know that in C++, when you're programming for certain OS, you can use something like this (And yes, I do know my macros are incorrect, but the point is given):

[CODE]
#if __WINDOWS__
#elseif __APPLE__
#elseif __LINUX__
#endif
[/CODE]

Would it be possible to code something like this for Android?
0

Share this post


Link to post
Share on other sites
[quote name='tom_mai78101' timestamp='1343828236' post='4965200']
For compatibility issues, isn't there a way to detect if the Android OS my app is being run on is a version older than 3.X?

I used to know that in C++, when you're programming for certain OS, you can use something like this (And yes, I do know my macros are incorrect, but the point is given):

[CODE]
#if __WINDOWS__
#elseif __APPLE__
#elseif __LINUX__
#endif
[/CODE]

Would it be possible to code something like this for Android?
[/quote]

Those are compile time macros so you'd rather want something similar to getVersionEx on Windows.

[url="http://developer.android.com/reference/android/os/Build.VERSION.html"]http://developer.and...ld.VERSION.html[/url] should do the trick.

only annoying part is that the SDK_INT field is only available in newer versions (API versions 4+ (Android 1.6 and up) , and the RELEASE field is a string that may contain non numbers (it can be 4.1b3 for example). (There is also a deprecated SDK field but i wouldn't recommend using that).

If you don't care about 1.5 and down you can just use the value in SDK_INT to see what features you'll have available. Edited by SimonForsman
0

Share this post


Link to post
Share on other sites
If I continue to rely on dynamic version checking (by programming a conditional flag that makes the app detect the right Android OS version, and using that conditional flag to run codes targeted for specific versions of Android), would it make the Android app development [b]more[/b] or [b]less[/b] manageable?

The reason I ask this, is that in Android SDK, if I were to develop an app for Ice Cream Sandwich, I would see some deprecated values, and sometimes I might get confused with which deprecated functions should I intentionally use.

And there may be a possible scenario that two or more developers were working on the same project targeting at different Android versions. Some lead developer of the team wanted to merge the project together, so that developer A continues the work for Gingerbread, while developer B continues for Ice Cream Sandwich. More like the term branching, the project is then branched into seperate minor projects that ultimately decides the fate of the app itself.

Would that also have an outcome, all because that the menu button and the search button is useless in Android 4.0 on older Android smartphones? Edited by tom_mai78101
0

Share this post


Link to post
Share on other sites
There are a couple of approaches you could take.

Google Play allow you to have multiple apk files for the same app targeting different devices or api versions. So you can build your app against 2.2 and then have a second version of it that is built on 4.0 that references the 2.2. version but has 4.0 specific versions of your UI. This requires good design practices around separating your ui code from your functional code generally know as an api layer.

Another option along a similar line which I came across the other day and I'm currently trying out on my current app is to use an api layer and a factory pattern along with custom widgets. The idea is that rather then use the action bar directly you refer to a custom action bar that provides all the same functionality but under the covers does
version checks and providers either the action bar or a customer built equivalent depending on what the device supports. There is a added complexity around this of course and does mean you may see ui differences between versions. You will also have to build against a newer version then you are supporting which means you have to have
extensive tests against older api versions.

Or you could also take a hard line design decision not support any features that aren't in 2.2 and 4.0

But not matter what you choose you should never ever have developers working on there own bits it what ever version they prefer. Everyone should be working against common set standards and guidelines otherwise things will become unmanageable. That includes api versions, coding standards, naming conventions, etc..
1

Share this post


Link to post
Share on other sites
You can also make use of ActionBarSherlock (http://actionbarsherlock.com/). I recently integrated it into an app I'm making
0

Share this post


Link to post
Share on other sites
This is covered pretty well here: http://stackoverflow.com/questions/8774317/handling-the-missing-menu-button-in-new-versions-of-android-3-x-and-up
0

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0