Developing mobile games on Unity is one of the most accessible ways to turn an idea into a real project that can be downloaded by millions of users. Android how the platform opens up huge opportunities: from indie projects to AAA games with advanced graphics. But how do you get started if you've never created a game? This article will help break down the process: from installing the necessary software to optimizing the game for weaker devices and publishing it in Google Play.
We will not delve into programming from scratch (there are separate guides for this), but we will consider all the stages that you will have to go through: setting up the development environment, working with 3D models, testing on real devices and even monetization. We will pay special attention to the typical mistakes of beginners - for example, why the game can lag on budget smartphones or how to avoid refusals when moderating in C#), but weโll look at all the stages that youโll have to go through: setting up the development environment, working with 3D models, testing on real devices, and even monetization. We will pay special attention to typical mistakes made by beginners - for example, why the game can lag on budget smartphones or how to avoid refusals when moderating in Google Play Console.
If you have already tried to create 2D projects, switching to 3D will seem like a logical step. The main thing is to understand that 3D graphics requires more resources, so optimization is critical here. Are you ready to experiment?
1. Preparing the working environment: what needs to be installed
Before you start creating a game, you need to prepare all the tools. Without the correct settings Unity and additional modules, you will not be able to build an apk file for Android. Here is the minimum set:
- ๐ฅ Unity Hub โ project manager (download from official website). It will allow you to manage several versions of the engine simultaneously.
- ๐ฅ๏ธ Unity Editor โthe development environment itself. For 3D games, the version
2022 LTS(Long Term Support) or later is suitable. Avoid alpha/beta versions - they may contain critical bugs. - ๐ค Android Build Support - module for building under Android. Installed via
Unity Hub โ Installs โ Add Modules. - ๐ฑ Android SDK and NDK - tools from Google for compiling code. They can be installed via Android Studio or separately.
- ๐ง Java JDK โneeded to work with Android SDK. Recommended version:
JDK 11.
After installation, check the settings in Edit โ Preferences โ External Tools. The paths to Android SDK, NDK and JDKshould be indicated here. If the fields are empty, specify them manually.
โ ๏ธ Attention: If you use macOS, make sure that you have Xcode installed (even for Androiddevelopment). Some dependencies require its presence.
You should also immediately configure Android emulator (via Android Studio) or connect a physical device via USB for testing. The emulator is convenient for quick checks, but it will not show real performance on weak devices.
โ๏ธ Checklist before starting work
2. Creating a new 3D project in Unity
Now that everything is ready, it's time to create the first project. Launch Unity Hub, click New Project and select template 3D Core. This is a basic template with a camera, lighting and a simple landscape.
After creating the project, you will see four main windows:
- ๐ฎ Scene โ levels are edited here.
- ๐ Hierarchy โ hierarchy of all objects in the scene.
- ๐ ๏ธ Inspector โ properties of the selected object.
- ๐๏ธ Project โfiles and assets of your project.
The first thing to do is save the scene (File โ Save Scene) and configure lighting. By default, Unity uses Baked Lighting, which can be slow on mobile devices. For Android it is better to switch to Realtime Lighting or hybrid mode:
- Select an object
Directional Lightin the hierarchy. - B Inspector set
Mode = Realtime. - Reduce
Shadow ResolutiontoLoworMedium.
โ ๏ธ Attention: Shadows (shadows) is one of the most resource-intensive features in 3D. On weak devices, it is better to disable them or use them only for key objects.
Also, do not forget to configure camera. By default, it may be too close to objects or have the wrong aspect ratio. For mobile games, the Orthographic (for 2.5D) or Perspective (for full 3D) mode is usually used.
How to change the scene background?
In the window Scene click on the gear icon (โ๏ธ) โ Scene Visibility โ select the background color or add Skybox via Window โ Rendering โ Lighting Settings.
3. Importing 3D models and animations
You most likely won't create all the models yourself (although Unity does have built-in primitives like cubes and spheres). To import ready-made 3D objects, the .fbx or .objformats are used. You can:
- ๐จ Download from free resources: Sketchfab, TurboSquid, Mixamo (for animations).
- ๐ฅ๏ธ Create in 3D editors: Blender (free), Maya, 3ds Max.
- ๐ค Generate using AI: Kaedim, Masterpiece Studio.
To import a model:
- Drag the file into the folder
Assetsin the window Project. - Unity will automatically create a prefab (
.prefab). Drag it onto the stage. - If necessary, edit the material (
Material) - for example, replace the texture or adjust the reflection of light.
For animations, use the system Animator:
- Import the animation file (format
.fbxwith rig). - Create
Animator Controller(Create โ Animator Controller). - Assign animations to states (Idle, Run, Jump).
- Bind the controller to the model via a component
Animator.
| File format | Support in Unity | Recommendations |
|---|---|---|
.fbx |
Full | The best choice for models with animations and rigs |
.obj |
Partial | Suitable for static objects, but without animations |
.blend |
Only through the plugin | Use Blender for export to .fbx |
.gltf/.glb |
Via package GLTF Utility | Good for the web, but not always optimal for mobile games |
Critical for Android: optimize models before importing! Remove unnecessary vertices, reduce the number of polygons (the goal is no more than 50,000 per screen) and compress textures (resolution no higher than 1024x1024 for mobile devices).
4. Programming game logic in C#
Without code, the game will not be interactive. Unity uses C# a language that is relatively easy to learn. Even if you're a beginner, basic scripts for character movement or collision handling can be written in a few minutes.
Create a new script: Assets โ Create โ C# Script. Name it, for example, PlayerController, and double-click to open it in the editor (recommended Visual Studio or Rider). Here is a simple example of a script for controlling a character:
using UnityEngine;public class PlayerController : MonoBehaviour
{
public float moveSpeed = 5f;
public float jumpForce = 10f;
private Rigidbody rb;
private bool isGrounded;
void Start()
{
rb = GetComponent<Rigidbody>();
}
void Update()
{
float moveX = Input.GetAxis("Horizontal") moveSpeed Time.deltaTime;
transform.Translate(moveX, 0, 0);
if (Input.GetButtonDown("Jump") && isGrounded)
{
rb.AddForce(Vector3.up * jumpForce, ForceMode.Impulse);
isGrounded = false;
}
}
void OnCollisionEnter(Collision collision)
{
if (collision.gameObject.CompareTag("Ground"))
{
isGrounded = true;
}
}
}
This script allows the character:
- ๐ Move left/right along the X axis (using keys
A/Dor arrows). - ๐ Jump when press
Space(only if the character is on the ground). - ๐ Stop when colliding with objects with the tag
Ground.
Don't forget to attach the script to the character model and configure Physics:
- Add a component
Rigidbody(for physics). - Add
Collider(for example,Box ColliderorCapsule Collider). - Set up tags (
Tag) for objects with which interaction.
โ ๏ธ Attention: On mobile devicesFixedUpdateworks more stable thanUpdatefor physical calculations. Use it to move objects withRigidbody.
To test the game on a smartphone without building an APK, use Unity Remote 5. Connect your phone via USB, launch the application on the device and click Play in the editor - control will be transferred from the PC.
5. Optimizing a game for Android: how to avoid lags
One โโof the main problems when developing 3D games for Android โ performance. Even average devices may not be able to play the game if it is not optimized correctly. Here are the key points: Performance data-i="190">๐ผ๏ธ Compress textures: format
๐น Graphics
- ๐จ Use
Lightweight Render Pipeline (LWRP)orUniversal Render Pipeline (URP)โ they are optimized for mobile devices. - ๐ผ๏ธ Compress textures: format
ASTC(best quality/size) orETC2(for most devices). - ๐๏ธ Disable
Anti-Aliasingor install2xinstead8x. - ๐ Reduce the number of light sources - one
Directional Light+ severalPoint Lightswith a limited radius.
๐น Physics
- ๐ฏ Use
Layer Collision Matrix(Edit โ Project Settings โ Physics) to disable unnecessary collisions between objects. - ๐ For static objects (walls, floors) check
Is KinematicinRigidbody. - ๐ Reduce
Fixed TimestepinTime Manager(but not lower0.01, otherwise the physics will become unstable).
๐น Code
- ๐๏ธ Remove unnecessary objects using
Object.Destroyor useObject Pooling. - ๐ Avoid
FindandGetComponentinUpdateโ cache links inStart. - ๐ฑ Test on real devices, not just in editor! The emulator will not show real memory consumption.
It is also worth setting graphics quality depending on the device. To do this:
- Go to
Edit โ Project Settings โ Quality. - Remove unnecessary quality levels (leave
LowandMedium). - Adjust settings for each level (for example, disable shadows on
Low).
| Option | Low (weak devices) | Medium (medium devices) |
|---|---|---|
| Shadows | Disabled | Hard Shadows Only |
| Anti-Aliasing | Disabled | 2x MSAA |
| Texture resolution | Half Res |
Full Res |
| VSync | Donโt Sync |
Every V Blank |
Optimization is not a one-time action, but a process. Test the game on different devices (from budget to flagship) and use Unity Profilerto find the bottlenecks. places.
6. Build APK and test on the device
When the game is ready, it's time to assemble it into a .apkfile. To do this:
- Go to
File โ Build Settings. - Select the platform
Androidand pressSwitch Platform. - In
Player Settings(Edit โ Project Settings โ Player) configure: Company NameandProduct Name(will be displayed in Google Play).Minimum API Levelโnot lowerAndroid 5.0 (API 21)for maximum compatibility.Target API Levelโthe latest stable version (at the time of writing -API 33).Scripting BackendโIL2CPP(better performance, but takes longer to build).
Build, select the folder to save and wait for completion.Before publishing on Google Play be sure to test the APK:
- ๐ฑ On real devices with different characteristics.
- ๐ In different screen orientations (if you support both portrait and landscape modes).
- ๐ฎ With different types of controls (touch screen, gamepad).
โ ๏ธ Attention: If the game weighs more than 150 MB, you will need to use Android App Bundle (.aab) instead of .apkGoogle Play automatically optimizes the size for different devices.
To distribute test builds, use:
- ๐ง Google Play Open Testing โ for public tests.
- ๐ Firebase App Distribution โfor closed tests with a limited number of users.
- ๐ Manual distribution via Telegram, Discord or cloud storage.
7. Publishing on Google Play: requirements and tips
To publish a game on Google Play, you will need:
- Developer account (
$25one-time). - Prepared materials:
- ๐ Icon (
512ร512,PNG, without transparency). - ๐ธ Screenshots (minimum 2, preferably 4-6 in different resolutions).
- ๐ฅ Video preview (not necessary, but enlarges conversion).
- ๐ Description (in Russian and English, with keywords for ASO).
- ๐ Icon (
Publishing process:
- Download
.aab-file in Google Play Console (Production โ Create New Release). - Fill in information about the content (age rating, presence of violence, etc.).
- Indicate the price (free or paid) and country of distribution.
- Submit for moderation (usually takes 1-3 days).
Common reasons for rejection:
- ๐ซ Lack of privacy policy.
- ๐ Incorrect age rating (for example, the presence of unmarked blood
12+). - ๐ฑ The game crashes on Google test devices.
- ๐ฎ Screenshots do not correspond to real gameplay.
โ ๏ธ Attention: If your game contains microtransactions, you will need to connect Google Play Billing Library and configure products in Play ConsoleThe use of third-party payment systems (for example, direct transfers) is prohibited by Google rules.
After publication, follow the reviews and metrics in Google Play Console:
- ๐
ANR & Crashesโerrors and crashes. - ๐
User Acquisitionโwhere installations come from. - โญ
Ratings & Reviewsโuser reviews (answer negative ones!).
8. Monetization and game promotion
Even the coolest game will not generate income if no one sees it. Here are the main ways of monetization and promotion:
๐ฐ Ways to earn money
- ๐ Paid game โ users pay for downloading. Suitable for niche projects with unique gameplay.
- ๐ Free-to-Play (F2P) with purchases - a free game with the option to purchase in-game currency, skins or bonuses. The most popular model.
- ๐ข Advertising - banners, videos between levels (AdMob, Unity Ads). Income depends on the number of impressions.
- ๐ Subscriptions โmonthly fee for access to premium content (suitable for MMORPGs or games with regular updates).
๐ข Promotion
- ๐ฑ ASO (App Store Optimization) โ page optimization Google Play for search queries. Use keywords in the title and description.
- ๐บ Social networks - short videos of gameplay on TikTok, YouTube Shorts, Instagram Reels.
- ๐ค Cross-promotion - exchange of advertising with other indie developers.
- ๐ฎ Events and competitions - for example, distribution of skins for reposting or completing a level.
To integrate advertising, use:
- Google AdMob โthe easiest way to display banners and videos.
- Unity Ads โintegrates well with the engine, high Fill Rate.
- AppLovin โsuitable for games with a high audience.
Example code for displaying a banner via AdMob:
using GoogleMobileAds.Api;using UnityEngine;
public class AdManager : MonoBehaviour
{
private BannerView bannerView;
void Start()
{
MobileAds.Initialize(initStatus => {});
string adUnitId = "ca-app-pub-3940256099942544/6300978111"; // Test ID
this.bannerView = new BannerView(adUnitId, AdSize.Banner, AdPosition.Bottom);
AdRequest request = new AdRequest.Builder().Build();
this.bannerView.LoadAd(request);
}
}
โ ๏ธ Attention: Do not overload the game with advertising! Optimal frequency: 1 banner per screen or 1 video advertisement between levels. Too intrusive monetization leads to mass deletions.
Successful mobile games are not only about high-quality gameplay, but also about competent marketing. Start promoting at the beta testing stage to gather an audience for the release.
FAQ: Frequently asked questions about creating 3D games in Unity for Android
๐น Do you need to be able to app to create a 3D game in Unity?
Basic knowledge C# required for creating interactive elements (character control, level logic). However, for simple projects you can get by with ready-made assets from Asset Store (for example, Standard Assets or plugins like Playmaker for visual scripting). For complex mechanics (multiplayer, AI), programming is necessary.
๐น What kind of computer is needed to develop 3D games?
Minimum requirements:
- ๐ฅ๏ธ Processor: Intel Core i5 / AMD Ryzen 5.
- ๐ง RAM: 8 GB (16 GB is recommended for complex projects).
- ๐ฎ Video card: NVIDIA GTX 1050 / AMD RX 560 (more powerful is needed to work with URP/HDRP ).
- ๐พ SSD: required for fast compilation.
For testing on Android any smartphone with USB debugging is sufficient.
๐น How long does it take to create a simple 3D game?
Depends on complexity:
- ๐ Simple platformer or arcade game: 1-3 months (when working 10-15 hours a week).
- ๐ Medium complexity game (RPG, shooter): 6-12 months.
- ๐ AAA project: years (and a team of several people).
The most time is spent on debugging, optimization and testing.
๐น Is it possible to make money from an indie game on Google Play?
Yes, but it requires effort. Examples of successful indie projects:
- Flappy Bird (earned $50k/day from advertising).
- Crossy Road (free game with purchases, millions of downloads).
- Among Us (started as a little-known project, then became a hit).
Key success factors: unique gameplay, high-quality optimization and active promotion.
๐น How to update a game after publishing it on Google Play?
Process updates:
- Fix bugs or add new content to the project.
- Increase
Version CodeiVersion NameinPlayer Settings. - Collect new
.aab-file. - Upload it to Google Play Console as a new update.
- Wait for moderation (usually faster than with the first release).
Important: do not change Bundle ID (for example, com.yourcompany.gamename), otherwise it will be considered a new game.