Unity is a cross-platform game engine and editor made by Unity Technologies. Developers build scenes in its editor and write gameplay code in C#, then export to targets such as Windows, macOS, Android, iOS, consoles and the web.
Why it matters
Unity is popular for mobile, indie and cross-platform projects, and also for non-game uses such as simulations, AR and VR, and interactive visualization. Its asset store and large community reduce the work needed to start. Licensing and pricing terms have changed over the years, so check Unity's current terms before committing a commercial project.
Example
A minimal Unity script that moves an object, written as a component:
using UnityEngine;
public class Mover : MonoBehaviour {
public float speed = 3f;
void Update() {
transform.Translate(Vector3.forward * speed * Time.deltaTime);
}
}
Update() runs once per frame, and multiplying by Time.deltaTime keeps the speed independent of frame rate.
Common mistakes
- Doing heavy work inside
Update()every frame, which hurts FPS. - Skipping profiling on real target devices; the editor on a desktop PC hides mobile limits.
- Assuming one project builds identically for every platform without testing.
Related
Get notified when this term updates
Plus occasional practical tips on uptime and monitoring, nothing else. Unsubscribe anytime.
This page is general information written by our editorial team and updated when documentation changes. Servers and providers differ, so test changes safely first. See our editorial policy and disclaimer.