Search Unity

Changing colour of a font?

Discussion in 'Scripting' started by BubyMB, Jun 10, 2016.

  1. BubyMB

    BubyMB

    Joined:
    Jun 6, 2016
    Posts:
    140
    Hey guys! I am using this code;
    Code (csharp):
    1.  
    2.         GUIStyle MainStyle = new GUIStyle();
    3.         MainStyle.font = MainFont;
    4.                     if (GUI.Button(new Rect((Screen.width / 2) - 25, (Screen.height / 2), 100, 30), "Start", MainStyle))
    5.                     {
    6.                      
    7.                     }
    8.  
    How would I make the text white?