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

My gui script is not making a different gui visible?

Really don't know what ROBLOX is doing these "updates" for, but now my script doesn't work

script.Parent.MouseButton1Click:Connect(function()
	game.StarterGui.Frame.TextBox.Visible = true
end)

It doesn't show up, and I honestly have no idea why.

3 comments

1

use PlayerGui instead of StarterGui

0

Thanks!

0

Np. Make sure to write [SOLVED] Beside the question's name.

1 answer

Roblox updates haven't really affected the way we have to script as of yet.

Here are a few Issues:

  1. First, your Frame and TextBox isn't inside a ScreenGui which makes it invisible.
  2. Second, your editing the StarterGui which is what is cloned into every player's Gui which won't update.

So how can you fix this?

  1. By putting Frame and TextBox into a ScreenGui

  2. Instead of getting StarterGui, get player Gui

Now what you are doing is MouseButton1Click which SHOULD be handled by the client. With this information what you could do is:

local plr = game.Players.LocalPlayer

script.Parent.MouseButton1Down:Connect(function()
	plr.PlayerGui.YourScreenGuiName.Frame.TextBox.Visible = true
end)

Hopefully, this gave you an idea of what to do.

Best of luck developer.

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