Reader small image

You're reading from  Unity Certified Programmer Exam Guide - Second Edition

Product typeBook
Published inMay 2022
Reading LevelIntermediate
PublisherPackt
ISBN-139781803246215
Edition2nd Edition
Languages
Right arrow
Author (1)
Philip Walker
Philip Walker
author image
Philip Walker

Philip Walker originally started as a 3D game artist, but then decided he wanted to combine his current skills with coding so that he could see through the majority of his games' and apps' development himself. Philip has worked in various different industries as an artist and as a Unity developer using various types of technology and techniques.
Read more about Philip Walker

Right arrow

Importing and animating the background

In this section, we are going to get familiar with Unity's Animator Controller. We will make our player's ship travel at lightspeed (well, give the impression that it is, anyway) by creating a fast-moving background of stars and particles (yes, that's right, more particles) at the start of the level, then we'll slow everything down when there are enemies up ahead.

Before we start animating at "lightspeed," we need to prepare the Hierarchy window:

  1. In the Hierarchy window, right-click on an open-space area.
  2. Select Create Empty from the dropdown.
  3. Click on the new game object and rename it GameSpeed.
  4. Do this again and name the second game object _SceneAssets.
  5. Drag GameSpeed onto the _SceneAssets game object.
  6. Make sure both game objects' Transform property values are set to Reset.
  7. Finally, drag the _SceneAssets game object from the Hierarchy window into the Assets/Prefab Project...
lock icon
The rest of the page is locked
Previous PageNext Page
You have been reading a chapter from
Unity Certified Programmer Exam Guide - Second Edition
Published in: May 2022Publisher: PacktISBN-13: 9781803246215

Author (1)

author image
Philip Walker

Philip Walker originally started as a 3D game artist, but then decided he wanted to combine his current skills with coding so that he could see through the majority of his games' and apps' development himself. Philip has worked in various different industries as an artist and as a Unity developer using various types of technology and techniques.
Read more about Philip Walker