Nametag Not Showing Up

game.Players.PlayerAdded:Connect(function(plr)
	plr.CharacterAdded:Connect(function(char)
		
		local Clone = game.ReplicatedStorage.NameTag:Clone()
		Clone.Parent = char.Head
		
		local Username = Clone.UsernameTag
		local Rank = Clone.NameRank
		
		Rank.Text = plr:GetRoleInGroup(7694413)

		Username.Text = plr.Name
		
		print ("hi")
	end)
end)

This is not working for some reason.

-It prints “hi”
-When I check my player’s head, the gui is not there.
-I’m sure I got the path right
-No errors in output.

This worked before, so I don’t know what’s happening. The nametag suddenly stopped showing up.

You should use adornee:

game.Players.PlayerAdded:Connect(function(plr)
	plr.CharacterAdded:Connect(function(char)
		
		local Clone = game.ReplicatedStorage.NameTag:Clone()
		Clone.Adornee = char:WaitForChild("Head")
		Clone.Parent = char:WaitForChild("Head")
		
		local Username = Clone.UsernameTag
		local Rank = Clone.NameRank
		
		Rank.Text = plr:GetRoleInGroup(7694413)

		Username.Text = plr.Name
		
		print ("hi")
	end)
end)

There is nothing wrong with the script.
Is “NameTag” a BillboardGui? If so, can you check the properties?

Also, you should not use adornee.
Adornee should only be used when you want the GUI change for certain players.

1 Like

Yes, it is indeed a BillboardGui.

Properties:
image
image
image
image

I will try this just incase!

Thank you for helping

Still no name-tag, rip.
image

Do you have text label in it???

Three text labels!
image

image
This is what it looks like when I put it in workspace.

I’ve had some issues with this before. You should try moving the name tag/billboard GUI to be a child of the script. (I’m assuming your script is in server script storage) [Edit: I’m not sure exactly why, but this has fixed my similar issue in the past. The script should work fine but for some reason, for me at least, it’s been the problem of it being in replicated storage]

Maybe also try using print(Clone.Parent) so we can see where the clone is, because it should definitely get made.

Trying right now…

image
No nametag.

image
It says the clone’s parent is my head. But…
image

I’m checking what the head’s parent is to see if it’s my character… or idk… something else.

[Edit: It say’s i’m the head’s parent.]

I was moving stuff around and noticed that it works with the HumaniodRootPart but not the head is it because it is a mesh part, and also the Dummy for the rig importer has Parts as heads not mesh parts while your character has a mesh part head.

1 Like

Yes! I’ve had this problem before, don’t understand it whatsoever but yeah that’s definitely not just you. And @CloudyCloset_Holder I’ve got a script on one of my places and I’ll definitely try to get that and share it to fix your issue, unless someone beats me to it (it might be a little bit)

Try finding the player’s character in a different way. See if it works:

local ReplicatedStorage = game:GetService("ReplicatedStorage")
local Clone = ReplicatedStorage:WaitForChild("NameTag"):Clone()

game.Players.PlayerAdded:Connect(function(plr)
   plr.CharacterAdded:Connect(function()

      -- Finding the character from workspace
        Clone.Parent = game.Workspace:WaitForChild(plr.Name).Head
      
        local Username = Clone.UsernameTag
		local Rank = Clone.NameRank
		
		Rank.Text = plr:GetRoleInGroup(7694413)

		Username.Text = plr.Name
		
		print ("hi")
	end)
end)

(I had the same problem too)

image

Works when I parent the Nametag to the HumanoidRootPart! Thanks.

Gonna try to see if this works just incase so I don’t have to move the nametag up since it’s in the humanoid rootpart

[Edit: That works too! Thank you :grinning_face_with_smiling_eyes: ]

2 Likes

Yeah another problem I see with the HRP is that it is it wont move with your head but with HRP and it looks odd.

Found a temp solution add a wait(1) or how long just before you Parent it to the head and it should work.

1 Like
game.Players.PlayerAdded:Connect(function(plr)
    plr.CharacterAdded:Connect(function(char)
        local Clone = game.ReplicatedStorage.NameTag:Clone()
  
        local Username = Clone.UsernameTag
	    local Rank = Clone.NameRank
	
	    Rank.Text = plr:GetRoleInGroup(7694413)

	    Username.Text = plr.Name
	
        Clone.Parent = char:FindFirstChild("Head")
    end)
end)