Customising the UI MiniMap
Last updated
Last updated
Implementing the GC Minimap is very simple as shown below.
From the PivecLabs/UIComponents/Prefabs folder, drag the prefab named Canvas - Minimap to your scene Hierarchy.
Add a Trigger for OnStart and add the Action Display MiniMap.
Customising the Minimap is simply changing the Prefab. The following tutorial will explain how to do this.
Locate the UI Components PreFab in the Prefabs folder.
2. Select the Canvas - Minimap, and in the inspector window, click on Open Prefab. You should see the following in your scene hierarchy window.
3. If you select the Canvas - Minimap GameObject, you will see that we have configured the Minimap Canvas as Screen Space Overlay and added a Canvas group to allow you to use fade in/out from the GC Actions. You will want to do this when you display another UI Canvas, or the player wishes to hide the Minimap.
4. Next you can select the Panel - Minimap. You will see that we have added a Mask, which is a circular image. You can change this to other shapes, or uncheck the checkbox if you wish to have a square map.
5. The next item is the RawImage - texturemap. We suggest that you leave this as it is. This is where the topdown camera image is rendered. You sholud leave the colour white, as darkening it will make it difficult to see, but you may wish to experiment with different settings.
6. Now select the MiniMap Frame. This is the compass image that surrounds the mask and you can change this for a graphic of your choice, simply by dragging in another image into the Source Image sot in the Inspector window. However, you may need to go back and change the Mask in Point 4, if it is a different shape.
7. You may also wish to not have the frame rotating with the Camera. If this is the case, simply uncheck the Frame Rotate Script in the Inspector window and he frame will remain fixed.
8. Lastly, there is the MiniMap Pointer. You can either change this for another graphic, of disable it and you will see the Player character moving in the center of the map.
In the future releases of this pack, we will add additional parameters for configuring the Camera.