How to fix values not displaying

You can write your topic however you want, but you need to answer these questions:

  1. What do you want to achieve? Keep it simple and clear!

Live updating value.

  1. What is the issue? Include screenshots / videos if possible!

Error:

  ServerScriptService.Script:23: attempt to index number with 'GetPropertyChangedSignal'
  1. What solutions have you tried so far?
Code.
local template = game.StarterGui.NameTag
game.Players.PlayerAdded:Connect(function(Player)
	Player.CharacterAdded:Connect(function(Character)
		local Hd = Character.Head
		local NameTag = template:Clone()	
		NameTag.Parent = Hd
		NameTag.Adornee = Hd
		
		local lval = Player.status.launches.Value
		local username = Player.Name
		local dispname = Player.DisplayName

		NameTag.launches.Text = "Launches: " .. lval 
		NameTag.Username.Text = username
		NameTag.displayname.Text = "@" .. dispname


		if NameTag.Parent == Hd then
			print("given.")
		end
		
		
		lval:GetPropertyChangedSignal("Value"):Connect(function()
			NameTag.launches.Text = "Launches: " .. lval
		end)

		
		
print("rgb")
			while true do
				math.randomseed(tick())
				local rColor = Color3.new(math.random(),math.random(),math.random())
				for i = 0 ,1, .05 do
					NameTag.top.BackgroundColor3 = NameTag.bottom.BackgroundColor3:lerp(rColor,i) -- RGB
					NameTag.bottom.BackgroundColor3 = NameTag.top.BackgroundColor3:lerp(rColor,i) -- RGB
					wait()
				end
				wait(.01)
			end
	end)

end)

Change these parts

to this

  1. local lval = Player.status.launches
  2. NameTag.launches.Text = "Launches: " .. lval.Value

Remove .Value from the lval variable definition.

it still does not seem to live update.
Here is how I know…

Please help!

Couldn’t you use .Changed() instead? Plus the text will not show on the client, unless you apply it on the client

Please write me an example due to I do not know how to use this.

So your trying to update the nametag text?

Yes I am updating the nametag text.

You would have to make a local script and use

ival.Changed:Connect(function()
     -- Change the text
end

Edit: You can manage the text from a value in replicated storage

so you could do

ival.Changed:Connect(function()
(name tag path).Text = (the string value in replicated)
end

This did not work… :sad:

Show me your script, I will check it out

local template = game.StarterGui.NameTag
game.Players.PlayerAdded:Connect(function(Player)
	Player.CharacterAdded:Connect(function(Character)
		local Hd = Character.Head
		local NameTag = template:Clone()	
		NameTag.Parent = Hd
		NameTag.Adornee = Hd
		
		Character.Humanoid.DisplayDistanceType = Enum.HumanoidDisplayDistanceType.None
		
		local lval = Player.status.launches
		local username = Player.Name
		local dispname = Player.DisplayName

		NameTag.launches.Text = "Launches: " .. lval.Value
		NameTag.Username.Text = username
		NameTag.displayname.Text = "@" .. dispname


		if NameTag.Parent == Hd then
			print("given.")
		end
		
	
	
		lval.Changed:Connect(function()
			NameTag.launches.Text = "Launches: " ..lval
		end)
		
		
			while true do
				math.randomseed(tick())
				local rColor = Color3.new(math.random(),math.random(),math.random())
			for i = 0 ,1, .05 do
					NameTag.top.BackgroundColor3 = NameTag.bottom.BackgroundColor3:lerp(rColor,i) -- RGB
					NameTag.bottom.BackgroundColor3 = NameTag.top.BackgroundColor3:lerp(rColor,i) -- RGB		
				wait()
				end
				wait(.01)
			end
	end)

end)

You need to update the text from the client, because if you look at the text from the server it will look right but the client doesn’t know about it, here is a metaphor.

Say you have art at an art museum and people come and take a picture, but you keep drawing on the picture, those people who took the picture don’t have an updated photo of what it looks like now

Ok so how do I make it update on my nametag that is what i wanted to know…

You update it from the client, if I were you I would use a stringValue and make a local script that detects for the stringValue’s value to change, and set the textlabel.text to the stringValue’s value, I have explained multiple times.

I do not understnad, So i am guna ask someone else for help if that is ok?

I suggest watching this video then, UI Programming, The Correct Way | Roblox Tutorial - YouTube