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

TextLabel not showing up?

Asked by 9 years ago

I made a script to show a GUI changing texts giving people, who click the "Play"button, information. It used to work before, now it won't. After I changed one of the texts, it broke.

All the GUIs start off Visible.

01mouse = game.Players.LocalPlayer:GetMouse()
02txt = script.Parent.TextLabel
03script.Parent.MouseButton1Click:connect(function()
04    game.Players.LocalPlayer.CameraMaxZoomDistance = 0.5
05    script.Parent.Visible = false
06    txt.Text = "Okay, " ..game.Players.LocalPlayer.Name.. "."
07    wait(5)
08    txt.Text = "Your task is simple."
09    wait(5)
10    script.Parent.Sound:Play()
11    txt.Text = "Run from him."
12    wait(3)
13    txt.BackgroundTransparency = 0.1
14    txt.TextTransparency = 0.1
15    wait(0.0000000001)
View all 43 lines...

There is nothing in the output. Could somebody help me out with this?

0
Line 05, you make it invisible. Perci1 4988 — 9y
0
That's the button going invisible. I want the button invisible. Grenaderade 525 — 9y

1 answer

Log in to vote
2
Answered by
Merely 2122 Moderation Voter Community Moderator
9 years ago

To clarify Perci1's answer, on line 5 you set the Frame's Visible property to false, so any children of the frame will be completely hidden. After that you are changing the Transparency properties of a TextLabel inside the Frame, but of course you're never going to see the changes because the Frame has to be Visible in order to see the TextLabel.

0
By the way, it's not in a frame. ._. Grenaderade 525 — 9y
0
Well whatever object it's in. Merely 2122 — 9y
Ad

Answer this question