Canvasing the World Space UI

In the previous chapter, we discovered how to interact with game objects in the world space scene. Not only can these objects be balls and toys or tools and weapons, but they can also be buttons you interact with and other graphical user interface (GUI)—or just UI—widgets. Furthermore, Unity includes UI canvas components and an event system for building menus and other UIs.

UI usually refers to onscreen, two-dimensional graphics, which overlay the main gameplay and present information to the user with status messages, gauges, and input controls, such as menus, buttons, sliders, and so on. In Unity, UI elements always reside on a canvas. The Unity manual describes the Canvas component as follows:

The Canvas component ...

Get Unity 2020 Virtual Reality Projects - Third Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.