I made this leaderstats script: ``game.Players.PlayerAdded:Connect(function(player)
local leaderstats = Instance.new("Folder") leaderstats.Name = "leaderstats" local Points = Instance.new("IntValue") Points.Name = "Points" end)``
the leaderboard script works but this one doesn't (im saying this because both are related)
game.Players.PlayerAdded:Connect(function(player)
if player.leaderstats.Points.Value == 5 then
script.Parent.Transparency = 0.5
script.Parent.CanCollide = false
end)
it gives me this error
23:33:14.041 - Workspace.door1.Script:5: Expected identifier when parsing expression, got ')'
I was under the impression that all events end with "end)" so could someone tell me what im doing wrong?