Preparing the scene for the UI
Now that we have a good understanding of the UI system, it's time to implement something within our game to practice a little bit. But the most important outcome from the rest of the chapter is to understand how to program UI within the framework of Unity.
First of all, we need to create a Canvas in our scene, and as a consequence, an event system will also be created. You can do it by right-clicking on the Hierarchy panel and then navigating to UI | Canvas. Select the Canvas object from the Inspector and tweak the options in the Inspector based on your needs. This really depends on your target platform (more on this in the last chapter of this book), and the best way to understand which of these options suit your ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access