The Hierarchy window

This window is a hierarchical view of the elements in the Scene view, which are represented by their names. On the top, we will always have the scene, and all the objects we add to the scene will hang from it. In the following screenshot, we have different elements, with some of them (Cube, Canvas) containing more elements.

The hierarchical view allows us to easily find the elements and the relationships between them (parenting) that affect the way they behave. For example, if we move the Cube element, its child object, ChildOfCube, will move along with it. However, if we only want to move the ChildOfCube element, we would select it in the Hierarchy window and move it, without affecting its parent CubeIn terms of the local/global positioning we explained in the previous section, the children's local position, rotation, and scale will be relative to those of the father:

The Cube object being selected in the Hierarchy window and Scene view

We will also use this window to quickly add new elements by right-clicking on it and selecting the one we want to add to the scene.

On the other hand, objects in the scene can be selected by clicking on them in the Scene view or in the Hierarchy window. The latter is very useful when an object has multiple children since we can ensure that we are selecting the correct element. In the Scene view, they could be overlapping.

A quick tip: double-clicking on the name of an object in the Hierarchy window makes the scene zoom into that object.

The Scene view and Hierarchy window are the two windows we can use to manipulate the elements in a scene, that is, the elements that we will build into our device. Now, we are going to learn how the Inspector window works when one of the elements in the scene is selected.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.117.196.217