I am setting up an admin panel for my game. Everything in the script seems to be okay, but the output says the PlayerGui is not a member of Player...
What did I do wrong? How can I fix my mistakes?
Here's my code:
function Entered(Player)
local isAdmin = {["Bolohuc"] = true, ["Bolohucalt"] = true, ["Bolohucalt2"] = true}
function findPlayer(name)
for _, Player in ipairs(game.Players:GetPlayers()) do
if Player.Name:lower() == name:lower() then
return player
end
end
end
if isAdmin[Player.Name] then Player.PlayerGui.Server.Tabs.Admin.Visible = true print(Player.Name .. "isAdmin") else print (Player.Name .. "isnotAdmin") end
end
game.Players.ChildAdded:connect(Entered)
I SOLVED THIS PROBLEM MYSELF. THANKS!

2 comments
Can you use Player.Name:lower as an argument for an if statement? Don't even know if that's possible...
I got this from the Roblox Wiki. I'm just using the wiki for something completely different for an admin panel. Here's where I got it from: http://wiki.roblox.com/index.php?title=Chat_commands