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

PlayerGUI is not a valid member of player. Any way to fix this issue?

Asked by 5 years ago

I am having trouble making a brick that when you click on it. Opens up a gui. But for some reason. When I try to put in the code which is.

local function click(playerr)
playerr.PlayerGUI.ScreenGUI.Frame.Visible = true

end
script.Parent.Notecheck.MouseClick:Connect(click)

And I keep getting this error PlayerGUI is not a valid member of Player

Is there anything that can fix this issue?

1 answer

Log in to vote
1
Answered by
aazkao 787 Moderation Voter
5 years ago
Edited 5 years ago

Thats because PlayerGUI is named PlayerGui, roblox is case sensitive

    playerr.PlayerGui.ScreenGui.Frame.Visible = true

and i am pretty sure you didnt rename the ScreenGui object to ScreenGUI, so i corrected that for you too

0
Thank you very much. It actually works now. Thanks for your help. fighterjosh5475 0 — 5y
0
nice, please accept the answer then aazkao 787 — 5y
0
I wonder if lots of answers go unaccepted on this site because new users do not know how to accept answers? aazkao 787 — 5y
0
Because it's scummy to remind users User#19524 175 — 5y
View all comments (3 more)
0
How so? I put in effort and take some time to help people out with their problems, the least they can do is accept the answer, how is that even remotely scummy? I dont get your logic here tbh aazkao 787 — 5y
0
I saw your post on the forum about accepting answers, please re-read this statement said by the moderator "Users are supposed to accept an answer if it helped solve their problem, but a lot of them today won't, hence the need for a reminder." aazkao 787 — 5y
0
@incapaz I already talked to you about this lol minikitkat 687 — 5y
Ad

Answer this question