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

I don't think my equal signs are registering?

local currecyName = "Money" local DataStore = game:GetService("DataStoreService"):GetDataStore("TestDataStore")

game.Players.PlayerAdded:Connect (function(player)

local folder = Instance.new("Folder")
folder.Name = "leaderstats"

local currency = Instance.new("IntValue")
currency.Name = currecyName
currency.Parent = folder

end)

2 comments

0

The script preview is not working...

0

what's the parent of folder huh?

1 answer

This question was kinda confusing but I have tried my best (the equal signs are registering). You forgot to parent the folder to the player.

local currecyName = "Money" local DataStore = game:GetService("DataStoreService"):GetDataStore("TestDataStore")

game.Players.PlayerAdded:Connect (function(player)

	local folder = Instance.new("Folder")
	folder.Name = "leaderstats"
	folder.Parent = player -- This right here you forgot	 

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

if this seemed to work an upvote would be appreciated

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