To create a minimap, follow these steps:
- From the Hierarchy panel, create a new UI Panel object (Create | UI | Panel) named Panel-miniMap. Since this is the first UI GameObject to be created in this Scene, new Canvas and EventSystem GameObjects should be created automatically, and the UI Panel should be a child of the Canvas GameObject.
- With the Panel-miniMap GameObject selected in the Inspector, do the following:
- In the Rect Transform, set the alignment to top-right (click the top-right box while holding down the Shift and Alt keys)
- In the Rect Transform, set Width to 128 and Height to 128
- We'll create a Render Texture file to which our minimap Camera will copy its view. In the Project panel, create a new Render Texture ...