Optimize Your Android Game for Google Play: Icons, Notifications, Themes, and More
This guide details essential Android game adjustments required for Google Play approval, including proper icon sizes, stacked notification handling, system‑styled dialogs and loading screens, immersive navigation key settings, screen orientation and density support, and back‑button behavior, providing code samples and manifest configurations for each improvement.
Table of Contents
Google app icons
Status bar notification
System theme style
Navigation keys
Screen adaptation
Back button
Background
When submitting a game to Google Play, Google provides optimization suggestions that improve user experience. This article lists the required adaptations based on Google Play standards and provides modification examples.
1. Google app icons
Game icon: five sizes (48×48, 72×72, 96×96, 144×144, 192×192) placed in mdpi, hdpi, xhdpi, xxhdpi, xxxhdpi directories.
Push icon (white + transparent): five sizes (24×24, 36×36, 48×48, 72×72, 96×96) placed in the same density folders.
See Android Studio icon creation tutorial in “Game Optimization Series 2 – Android Studio Icon Tutorial”.
Example:
2. Status bar notification
When both the game and an SDK send notifications, different IDs can cause two separate messages, which may be rejected by Google Play.
<code>NotificationManager.notify(int id, Notification notification)</code>Desired effect: stack notifications from the same app.
Modification example:
<code>private void mergeNotifications() {
int mergeId = 0;
String groupKey = "com.android.example.WORK_EMAIL";
String channelId = "1";
Notification notification1 = new NotificationCompat.Builder(MainActivity.this, channelId)
.setSmallIcon(R.drawable.ic_launcher_background)
.setContentTitle("Push needs stacking")
.setContentText("This is an SDK notification")
.setGroup(groupKey)
.build();
Notification notification2 = new NotificationCompat.Builder(MainActivity.this, channelId)
.setSmallIcon(R.drawable.ic_launcher_background)
.setContentTitle("Push needs stacking")
.setContentText("This is a game notification")
.setSmallIcon(R.drawable.ic_stat_name)
.setGroup(groupKey)
.build();
Notification mergeNotification = new NotificationCompat.Builder(MainActivity.this, channelId)
.setContentTitle("Push needs stacking")
.setContentText("2 unread messages")
.setSmallIcon(R.drawable.ic_stat_name)
.setStyle(new NotificationCompat.InboxStyle()
.addLine("This is a game notification")
.addLine("This is an SDK notification")
.setBigContentTitle("2 unread messages")
.setSummaryText("Push test"))
.setGroup(groupKey)
.setGroupSummary(true)
.build();
NotificationManagerCompat notificationManager = NotificationManagerCompat.from(this);
notificationManager.notify(1, notification1);
notificationManager.notify(2, notification2);
notificationManager.notify(mergeId, mergeNotification);
}</code>3. System theme style
Dialogs and loading screens should follow the system theme on Android 5.0+. Non‑system styles are not acceptable.
Correct system‑styled example:
If custom designs are used, they can remain, but two implementation methods are provided:
Method 1: Do not set android:theme in or tags to inherit system style.
<code><manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.game37.themeapplication">
<application
android:allowBackup="true"
android:icon="@mipmap/ic_launcher"
android:label="@string/app_name"
android:roundIcon="@mipmap/ic_launcher_round"
android:supportsRtl="true">
<activity android:name=".MainActivity"
android:screenOrientation="sensorLandscape">
<intent-filter>
<action android:name="android.intent.action.MAIN"/>
<category android:name="android.intent.category.LAUNCHER"/>
</intent-filter>
</activity>
</application>
</manifest></code>Method 2: Keep android:theme and use AppCompat themes or custom themes inheriting Theme.AppCompat.
<code><manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.game37.themeapplication">
<application
...
android:theme="@style/Theme.AppCompat">
<activity android:name=".MainActivity"
android:screenOrientation="sensorLandscape"
android:theme="@style/testStyle">
<intent-filter>
<action android:name="android.intent.action.MAIN"/>
<category android:name="android.intent.category.LAUNCHER"/>
</intent-filter>
</activity>
<activity android:name=".MainActivity2"
android:theme="@style/Theme.AppCompat.NoActionBar"/>
</application>
</manifest></code>Custom style example:
<code><style name="testStyle" parent="Theme.AppCompat">
<item name="android:actionBarStyle">@style/FullscreenActionBarStyle</item>
<item name="android:windowActionBarOverlay">true</item>
<item name="android:windowBackground">@null</item>
</style>
<style name="FullscreenActionBarStyle" parent="Widget.AppCompat.ActionBar">
<item name="android:background">@color/colorAccent</item>
</style></code>Resulting screenshots illustrate the effects.
Note: If the theme is changed and input fields appear with white text on white background, use Theme.AppCompat.Light.DarkActionBar to fix.
4. Navigation keys
System navigation keys should not obstruct functionality; use IMMERSIVE_STICKY mode for full‑screen (API 19+).
<code>getWindow().getDecorView().setSystemUiVisibility(
View.SYSTEM_UI_FLAG_LAYOUT_STABLE |
View.SYSTEM_UI_FLAG_LAYOUT_HIDE_NAVIGATION |
View.SYSTEM_UI_FLAG_LAYOUT_FULLSCREEN |
View.SYSTEM_UI_FLAG_HIDE_NAVIGATION |
View.SYSTEM_UI_FLAG_FULLSCREEN |
View.SYSTEM_UI_FLAG_IMMERSIVE_STICKY);
</code>Screenshot shows the effect.
5. Screen adaptation
Screen orientation: set android:screenOrientation="sensorLandscape" in the activity to keep consistent landscape orientation.
Support multiple screens by adding the following element to AndroidManifest:
<code><supports-screens
android:anyDensity="true"
android:largeScreens="true"
android:xlargeScreens="true"
android:normalScreens="true"
android:resizeable="true"
android:smallScreens="true" /></code>6. Back button
The back button must provide navigation, pause/cancel game, close dialogs, and return to previous menu levels. Improper handling can cause Google Play rejection.
Typical scenarios include needing to exit during loading or close dialogs when the button is pressed.
FAQ
If the main Activity extends androidx.appcompat.app.AppCompatActivity, a Theme.AppCompat theme is required; therefore, set the theme accordingly.
Note
If theme changes cause input fields to display white text on white background, use the recommended theme android:theme="@style/Theme.AppCompat.Light.DarkActionBar".
37 Mobile Game Tech Team
37 Mobile Game Tech Team
How this landed with the community
Was this worth your time?
0 Comments
Thoughtful readers leave field notes, pushback, and hard-won operational detail here.