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

Why I cannot press text button like play button?

I made a text button much like those play buttons. i put local script inside it and boom it's not working. I cannot press it. It's like a scriptless button. Any idea?

3 comments

0

May i see the script please?

0

What is in the localscript? What do you mean by scriptless button?

0

It doesn't react. So it's just a scriptless or useless button

3 answers

✓ Accepted answer

So there are a few issues with your script. First of all, you need to edit your question to include the script (but that's a bit off-topic.) Secondly, When you use StarterGui, it will immediately replicate everything to the PlayerGui. So here's the solution. Put your localscript UNDER the ScreenGui not under the Playbutton.

script.Parent.Playbutton.MouseButton1Click:Connect(function()
	script.Parent.ImageLabel.Visible = false
end)

Now what are the edits I made? First of all, you can just put your GUIs under one ScreenGui, so just put your ImageLabel under the ScreenGui. Secondly, you don't need to set the Active property. You can set the visible property to false. Also, I would like to add, once the button is clicked, it will remain false, for as long as possible. Just remember, when you're changing things in the StarterGui, it won't change anything. You need to access the ImageLabel either using script.Parent or the PlayerGui.

4 comments

0

This might be the answer but it still doesn't work for me. I'll just quit the game since it's a text story game. Thanks

0

Don’t quit!

0

Don’t quit!

0

Don't quit!

Not an answer but here for example

script.Parent.Parent.Playbutton.MouseButton1Click:Connect(function()
	game.StarterGui.ScreenGui.ImageLabel.Active=false
end)

you can try:

script.Parent.MouseButton1Click:Connect(function()

script.Parent.Parent.Parent.Frame.Visible = false

end)

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