Hello everyone, I’ve been “playing” with unity for a month now, just for hobbie, so much fun! I’m making my first app and I have this odd annoying thing happening: when I display a text, the text is duplicated twice in the game with two different font sizes like in the picture below.
I just want the big font to be displayed.
Here’s my code for the GUI
void OnGUI()
{
if(isRunning == true)
{
GUI.Label(new Rect(50, 25, 100, 30), "Player Score: " + playerScore, style);
GUI.Label(new Rect(750, 25, 100, 30), "Special Bullets: " + SpecialBullet, style);
GUI.Label(new Rect(50, 100, 100, 30), "Record: " + Record, style);
}
else
{
Debug.Log(NewRecord);
if (NewRecord == true)
{
GUI.Label(new Rect(Screen.width / 2 - 50, Screen.height / 2 - 15, 100, 30), "Game Over. \n You made a new record of: " + (playerScore), styleDead);
PlayerPrefs.SetFloat("Record", Record);
}
else
{
GUI.Label(new Rect(Screen.width / 2 - 50, Screen.height / 2 - 15, 100, 30), "Game Over. \n Your score was: " + (playerScore), styleDead);
}
}
}
Here’s the style that I use for the GUISkin
Everything is set to default.
I can’t find any mistake anywhere, little help?
Thank you very much to everyone!

