I have this leaderstats script :
game.Players.PlayerAdded:connect(function(player)
local leader = Instance.new("Folder",player)
leader.Name = "leaderstats"
local Points = Instance.new("IntValue",leader)
Points.Name = "Points"
Points.Value = 0
local Title = Instance.new("StringValue",leader)
Title.Name = "Title"
Title.Value = "Noob Finder"
while true do
wait(.6)
if Points.Value > 100 then
Title.Value = "Good Finder"
end
end
end)
and i want to show the title value above players head. But I tried and it didn't work for other players and it didn't update. Please help me
Gui above head script:
game.Players.PlayerAdded:connect(onPlayerRespawned)
function onPlayerRespawned(newPlayer)
wait(1)
if newPlayer then
gui=Instance.new("BillboardGui")
gui.Parent=newPlayer.Character.Head
gui.Adornee=newPlayer.Character.Head
gui.Size=UDim2.new(4,0,2,0)
gui.StudsOffset=Vector3.new(0,3,0)
texta=Instance.new("TextBox")
texta.Size=UDim2.new(1,0,1,0)
texta.TextSize = 35;
texta.Font = 10;
texta.TextStrokeTransparency = 1;
texta.TextStrokeColor3 = Color3.new(0,0,0)
texta.BackgroundTransparency = 1
texta.TextColor3 = Color3.new(255,255,255)
texta.Parent=gui
if newPlayer.leaderstats.Title.Value == 'Noob Finder' then
texta.Text = "[Noob Finder]"
texta.TextColor3 = Color3.new(255,0,0)
end
if newPlayer.leaderstats.Title.Value == 'Good Finder' then
texta.Text = "[Good Finder]"
texta.TextColor3 = Color3.new(255,255,0)
end
end
end
function onPlayerEntered(newPlayer)
newPlayer.Changed:connect(function (property)
if (property == "Character") then
onPlayerRespawned(newPlayer)
end
end)
end
game.Players.PlayerAdded:connect(onPlayerEntered)

5 comments
Close out your PlayerAdded event
I don't know what that means... I'm begginer
take a look ad the character added event. The player added event is for when they join the game not when the player character spawns in
in your first script remove the inf loop as it will not stop when the player leaves the game. Take a look at the changed event for the value object IntValue
if Points.Value >= (not >) 100 (I'm not sure if it works im a complete noob at scripting oof)