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

why this add folder to player script isnt working?

so i made a script that inserts a folder into a player, then inserts a value into it. so the issue is that the folder appears but its empty. not getting any errors.

game.Players.PlayerAdded:Connect(function(plr)
	local folder = Instance.new("Folder",plr)
	folder.Name = "bdbfolder"
	local bdb = Instance.new("IntValue",folder)
	bdb.Name = "bdb"
end)

1 answer

Try this

game.Players.PlayerAdded:Connect(function(plr)
    local folder = Instance.new("Folder")
    folder.Parent = plr
    folder.Name = "bdbfolder"

    local bdb = Instance.new("IntValue")
    bdb.Parent = folder
    bdb.Name = "bdb"
end)

2 comments

0

nope

0

put it in the serverscriptservice with a normal script

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