Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
-1

How do you create a TextLabel in the game without having it in StarterGui?

Asked by 9 years ago

Here is what I have tried:

local Workspace.Instance.new(TextLabel)
local TextLabel.parent = Workspace

1 answer

Log in to vote
0
Answered by 9 years ago

Before I Answer Your Question

Your script is kind of wrong (but nothing you can't fix with lots of practice!) Here would be the correct way to write it

NOTE

All you can have is one line of code to have the parent to whatever you have.

--In a local script
local screenGui = Instance.new('ScreenGui', StarterGui)
local TextLabel = Instance.new('TextLabel',StarterGui.screenGui)

To Answer Your Question...

No it isn't possible for the TextLabel to be present and visible without the starterGui, since it's inserted directly into PlayerGui.

Oh, And By The Way...

I suggest you get better at scripting before moving to ScreenGuis. I can tell by the way your code was written.

GreekGodOfMLG

0
Thanks dude! Now I am just working on choosing random maps. NeonicPlasma 181 — 9y
0
No problem, and check out math.random() for that choosing random maps! GreekGodOfMLG 244 — 9y
Ad

Answer this question