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

How do I add a value to a player?

I want to add a numbervalue into a player when the join the game, but how do i do this? Thanks.

1 answer

✓ Accepted answer
game.Players.PlayerAdded:Connect(function (player)
	local x = Instance.new("IntValue")
	x.Parent = player
	x.Name = "Put The Name of the Value here"
	x.Value = 0 --change to the value you want it to be 
end)

2 comments

0

You forgot to add a ) at the end of "end". However, it works. Thank you.

0

oh you are right,sorry for mistake, i will edit it.

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