BomberUnits
...a Unity learning project
Label Class Reference

A label handles all kinds of world space hovering displays for game objects. More...

+ Inheritance diagram for Label:
+ Collaboration diagram for Label:

Public Member Functions

void Awake ()
 AWAKE is called even when the component is not active! Here we use the global showLabels as default. More...
 
void SetActive (bool active)
 
void Show ()
 
void Hide ()
 
void SetVisible (bool visible)
 
void SetText (string s)
 
void SetTargetCamera (Camera c)
 

Public Attributes

GameObject canvas
 
Text text
 

Detailed Description

A label handles all kinds of world space hovering displays for game objects.

This class is intended to be extended in the future. For now it has text display capabilities. The canvas and text game object setup uses an available prefab.

Definition at line 9 of file Label.cs.

Member Function Documentation

◆ Awake()

void Awake ( )
inline

AWAKE is called even when the component is not active! Here we use the global showLabels as default.

This can be switched on and off depending on more detailled settings for individual object types bearing a label.

Definition at line 24 of file Label.cs.


The documentation for this class was generated from the following file: