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

Why does my GUI only show after I reset?

Asked by
dreamy67 135
9 years ago

I have a GUI in StarterGui that is already set at visible = false from the properties tab. I have a line of code that makes it visible and changes the Text. However, the GUI does not show up on my screen until AFTER I reset. How can I fix this?

0
Please provide script, we are not mind readers. M39a9am3R 3210 — 9y

2 answers

Log in to vote
3
Answered by
NotSoNorm 777 Moderation Voter
9 years ago

See, The problem is, is that you're changing the StarterGui, NOT, the playergui. The StarterGui just replicates itself to the player, not changing/updating it.

instead try this:

    for _, Player in pairs(game.Players:GetChildren()) do
        if Player:IsA("Player") then
            Player.PlayerGui.ScreenGui.Frame.TextLabel.Visible = true
        end
    end
0
Thanks! dreamy67 135 — 9y
Ad
Log in to vote
0
Answered by
xuefei123 214 Moderation Voter
9 years ago

Whats the script? And where is it located?

0
Its in the workspace. The code is: game.StarterGui.ScreenGui.Frame.TextLabel.Visible = true dreamy67 135 — 9y

Answer this question