Unity Fundamentals — Building a UI

Jose Gil
2 min readApr 18, 2021

--

As an experienced UI and UX designer for games, apps, and websites, I know that it can make or break your game. Luckily, Unity provides you with the tools to easily create a UI for your games. In this article, I will cover how easy it is to create UI Elements in Unity.

Unity UI elements

There are many different UI elements that Unity allows you to create. From Text, Sliders, Images to Buttons and more, and they can be created within the Hierarchy at any time.

When you create your first UI element within the Unity Hierarchy, Unity will add a Canvas and EventSystem. Your new UI Element will be a child of the Canvas GameObject.

Unity provides several parameters for you to configure the UI Elements within the Inspector. For example, the Text element in the example below allows you to change its colour, size, justification, style and more.

Experiment with the UI Elements that Unity provides and create some great options for your players

Tips with UI Elements

  • Anchor UI Elements to ensure they remain in the exact location no matter the screen’s size or orientation. You can choose from top left, top right, middle and many more.
  • Change the Canvas Scaler UI Scale Mode within the Canvas to “Scale With Screen Size”. This will help with optimising the screen for different size screens
  • When using the Image UI element, make sure you check the “Preserve Aspect” Checkbox to keep the image the correct size.

This article only briefly touches on the UI abilities of Unity but I hope it has helped you build your games.

--

--