So I started watching previousText.Length while clicking through dialogue and noticed it just keeps getting bigger and bigger the entire time. Sometimes a little smaller, but always trending towards bigger.
Code: Select all
if (accumulateText && !string.IsNullOrEmpty(subtitle.formattedText.text))
{
if (numAccumulatedLines < maxLines)
{
numAccumulatedLines++;
}
else
{
// If we're at the max number of lines, remove the first line from the accumulated text:
previousText = previousText.Substring(previousText.IndexOf("\n") + 1);
Debug.LogWarning("Previous Text Length: " + previousText.Length);
}
}
I tried to make sure there are no scripts overriding this.
What am I missing or what might I check? This is in version 2.2.38.2