100% found this document useful (2 votes)
345 views

Unity For Beginners

Unity is a popular game engine that allows developers to create 2D and 3D games and other interactive content. It provides features like physics, rendering, scripting, and more without requiring extensive programming. The document discusses the basics of Unity, including its interface, essential concepts like scenes and game objects, common components, importing assets, prefabs, and scripting. It provides an overview of getting started with Unity for beginners.

Uploaded by

LuDK
Copyright
© © All Rights Reserved
100% found this document useful (2 votes)
345 views

Unity For Beginners

Unity is a popular game engine that allows developers to create 2D and 3D games and other interactive content. It provides features like physics, rendering, scripting, and more without requiring extensive programming. The document discusses the basics of Unity, including its interface, essential concepts like scenes and game objects, common components, importing assets, prefabs, and scripting. It provides an overview of getting started with Unity for beginners.

Uploaded by

LuDK
Copyright
© © All Rights Reserved
You are on page 1/ 43

Unity for beginners

1.
What is Unity ?
Unity is a Game Engine, it means an architecture that developers
use to make their games. It provides features like : physics, input,
rendering, scripting, collision detection, artificial intelligence
and more without the need to program them.
2.
Why Unity ?
Which Games Engines are Most Popular?
The short answer is Unity & Unreal Engine. Both platforms
are capable of creating stunning visuals and cross-platform
applications and both platforms are perfectly appropriate for
creating complex XR solutions and indie projects alike.
3.
Unity vs unreal

Made with Unity (1:14) Made with Unreal Engine (3:52)


UNITY
FireWatch
UNREAL ENGINE
FireWatch
$150 Unity Pro .
Free vs Pro version

● Unity is royalty free. If revenue or funding is greater than $200K in the last 12 months, you are
required to use Pro or Enterprise.
● Unreal is free to use and incurs 5% royalties when you monetize your game or other interactive
off-the-shelf product and your lifetime gross revenues from that product exceed $1,000,000.
4.
Create a new project
1 2

4
5.
Unity’s Interface
A - Toolbar D - Scene View
B - Hierarchy Window E - Inspector Window
C - Game View F - Project Window
6.
Scene view navigation
7.
essential unity concepts
Scenes
GameObject and Components

Tag

Object name Layer

The transform
component

The light
component

Add a new
component
Every Game Object in a Scene has a Transform. It's used to store and manipulate the position, rotation
and scale of the object. Every Transform can have a parent, which allows you to apply position, rotation
and scale hierarchically. This is the hierarchy seen in the Hierarchy pane.
Tags
Layers
8.
Most Common components
The Component: Transform
The Component: Camera
The Component: Others

● Light - To create a new light (spot, directional, point, area).

● MeshFilter/MeshRenderer - To display a 3d model.

● Collider - To define 3D space for collisions.

● Rigidbody - To define physic properties (mass, constraints)

● AudioListener - To define a listener for the audio.

● AudioSource - To play audio (music, sfx)

● ParticleSystem - To display particle systems.


9.
Create a 3D primitive
Create a Simple Primitive
10.
Creating components with scripting
Creating and using Scripts
Example
MonoBehaviour Simplified Life Cycle
LOOP

https://docs.unity3d.com/Manual/ExecutionOrder.html
MyScript Source Code
using UnityEngine;

public class MyScript : MonoBehaviour


{
public float speed = 2.0f;
private Transform transformComponent;

void Start()
{
transformComponent = GetComponent<Transform>();
}

void Update()
{
float newX = transformComponent.position.x + speed * Time.deltaTime;
Vector3 newPosition = new Vector3(newX, transformComponent.position.y, transformComponent.position.z);
transformComponent.position = newPosition;
}
}

All public members of your custom


component will give editable
properties in the Inspector.
11.
Import a 3D object
Soap Derby
https://sketchfab.com/3d-models/soapbox-derby-c7e556e5a17e48d0ae9e04c24a0647b9

CaisseSavon.fbx

textCaisseSavon.png
Create Material and apply it
12.
Create a prefab
Prefabs
Create a Prefab from the Soap Derby
13.
mini tutorial
Demo Training

https://github.com/ludonkey/demotraining
14.
Go further
https://www.youtube.com/channel/UCYbK_tjZ2OrIZFBvU6CCMiA

You might also like