Hi, I'm making a scene that tells a story using text. I'm using GUI.Label to do it. It worked perfectly fine until I changed the font to one I got from dafont.com. Now it just writes completely off the screen when it gets there, instead of going to the next line. Here's the script. (By the way, I adapted the typewriter script for this, because my game is like an rpg).
var letterPause = 0.01;
var Story : int = 1;
var words : String = "";
var fontStyle : GUIStyle;
private var word;
function Start () {
if(Story == 1)
{
word = " Once upon a time, there was a man. This man was strong, cunning, and brave. His name was Elden Bremseth. Elden longed for adventure. When he turned 18, he went for it.";
}
TypeText ();
}
function TypeText () {
for (var letter in word.ToCharArray()) {
words += letter;
yield WaitForSeconds (letterPause);
}
}
function OnGUI()
{
GUI.Label(Rect(5,0,Screen.width - 50,Screen.height),words,fontStyle);
if(GUI.Button(Rect(Screen.width/2,Screen.height - 100,150,100),"Continue to Game"))
{
MainMenuScript.loadGame();
}
}