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

idk it keeps saying error name is not a valid member of boolvalue? please help i'm new

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

local leaderstats = Instance.new
leaderstats.Name = "leaderstats"
leaderstats.Parent = player

local cash = Instance.new("IntValue")
cash.Name = "cash"
cash.Value = 10000
cash.Parent = leaderstats

end)

5 comments

0

What are you trying to do?

0

any errors? It all looks fine to me

0

In the top bar in studio, click on view then output, then run the game and see if any red stuff shows up in the output

0

I can help if I know what you're trying to do

0

I'm trying to make like a leaderboard thing and it shows ur cash in the corner and stuff cause im starting to make a egg simulator

1 answer

✓ Accepted answer

You assigned the leaderstats variable to the Instance base-class constructor, which registered the variable as a function reference. You need to call the constructor method with the provided Object name to actually instantiate it:

local Leaderstats = Instance.new("Folder")

1 comment

0

BRO THANK YOU SO MUCH U REALLY SAVED MY DAY U THE BEST!!!!!!!

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