Book Image

Creating E-Learning Games with Unity

By : David Horachek
Book Image

Creating E-Learning Games with Unity

By: David Horachek

Overview of this book

Table of Contents (17 chapters)
Creating E-Learning Games with Unity
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
Index

Exploring the TextMesh component


The TextMesh user interface component operates differently than the previous two components. It actually generates a polygonal mesh based on the text rather than display a 2D font or 2D texture. It then places the mesh at the location and orientation specified in the GameObject's transform. This means that we can place this mesh directly in the game world!

Ideal use of TextMesh

One of the useful applications of TextMesh is that it can be placed in the world at its transform position. This makes it adept at labeling objects that move around the world. This can be done by parenting the TextMesh component to the GameObject, with a slight vertical offset in the TextMesh transform.