Game Development Reference
In-Depth Information
1.
Open the Label template by clicking the expand arrow next to its name
(Figure
10-5
).
Figure 10-5.
The Label template
Before you start experimenting with the Label's parameters, you will have to tell the script to use the
new GUI Skin asset.
2.
Add the following variable to the EndGameGUI script:
public GUISkin newSkin; // custom skin to use
At the top of the
OnGUI
function, add
3.
GUI.skin = newSkin;
4.
Save the script, and assign the Garden GUISkin to the New Skin parameter
in the Game Manager's EndGameGUI component.
5.
Click Play so you will be able to see the changes as you experiment with the
Label template.