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

why won't the menu close properly?

Event = game.ReplicatedStorage:WaitForChild('GameStart') Guis = game.StarterGui:WaitForChild('Credits')and game.StarterGui:WaitForChild('Playbutton')

Event.OnServerEvent:Connect(function(Player) --Play button-- Player.PlayerGui.Playbutton.Enabled = false

--Credits-- Player.PlayerGui.Credits.Enabled = false Player.PlayerGui.CreditsOpened.Enabled = false

--Donations-- Player.PlayerGui.Donation.Enabled = false Player.PlayerGui.DonationOpened.Enabled = false

end)

**(the issue is that 'DonationOpened' and 'CreditsOpened' won't turn of when told to, the Play button, Credits button and Donation button will but these won't, sorry if it's obvious, I'm just a dumb kid lol) **

3 comments

0

it's not really set on the button, it turns of the parent of which does have .Enabled as a variable

0

Please put it in a code block to make it easier to read

0

You can’t access PlayerGui in a server script. You have to do it in a LocalScript.

1 answer

You can not set enabled on a frame or button i think, use .Visible instead.

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