Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

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

Asked by 6 years ago
Edited 6 years ago

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)


0
Is this a Client or Server script? Is filtering enabled? ArcticDev 9 — 6y

1 answer

Log in to vote
0
Answered by
TheePBHST 154
6 years ago

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

Ad

Answer this question