This is the script: local currencyName = "Horrors"
game.Players.PlayerAdded:Connect(function(player)
local folder = Instance.new("Folder") folder.name = "leaderstats" folder.Parent = player local currency = Instance.new("IntValue") currency.Name = currencyName currency.Parent = folder
end) I've rewritten it multiple times and it still doesn't work. Anything I possibly did wrong?
The code is fine. Except it's folder.Name, not folder.name the name in folder.name needs to be a capital letter. Also make sure it's a script, not a local script.
Your code is fine other than needing to change folder.name on line 2 to folder.Name, but you need to have this in a script, rather than a local script for it to work.