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

Why wont this work, the value wont seem to spawn?


print("Character Info script version 3.00 loaded")


function onPlayerEntered(newPlayer)

local stats = Instance.new("IntValue")
stats.Name = "CharacterInfo"

local Skin = Instance.new("Color3Value")
Skin.Name = "Skin"
Skin.Value = 255,255,255

stats.Parent = newPlayer
Skin.Parent = stats

while true do
	if newPlayer.Character ~= nil then break end
	wait(5)
end



stats.Parent = newPlayer

end game.Players.ChildAdded:connect(onPlayerEntered)


1 comment

0

Is this a Client or Server script? Is filtering enabled?

1 answer

In ROBLOX, to make the game identify the stats you're trying to give the player is known as leaderstats

Leaderstats is the main name for player stats and if the game doesn't see that name in any value, it won't count as a player stat.

It has to be exactly named leaderstats for it to work properly. So what you need to do is change CharacterInfo to leaderstats

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