Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
✓ ANSWER ACCEPTED

This script works in Run, but not Play Solo. Why is that?

number = 0

while true do
	number = number + 1
		wait()
		game.StarterGui.ScoreGui.Number.Text = number
	wait(.5)
end

It works when I press Run, but when I join the game or play solo, it does not work. Does anybody have a solution?

1 answer

✓ Accepted answer

In studio mode all GUIs in StarterGui are shown to your screen for easy editting of them. You should never be trying to affect the GUIs in there since a clone of all of them are sent to the Player when they join the game. Instead, put that code in a LocalScript in StarterGui and use script.Parent.ScoreGui.Number.Text = number

This discussion is preserved as it was. New answers, comments, and votes are closed.