I’m trying to give certain players a special nametag above their head? How would I do this? I don’t really know where to start.
You mean like edit the one they already have, or create a custom one?
If you want a custom one, you’ll insert a BillboardGui into their head, like @DeodorantSlice37 already mentioned. Make sure to change their default name’s DisplayDistance to 0 in their Humanoid to hide it.
If you just want to edit their name tag that already exists, you should modify the DisplayName property of their Character.Humanoid.
First, you create a BillboardGui and name it “Nametag.” Set the size to 4,0, 1,0. Set the StudsOffset property to 0, 3.5, 0. Put a TextLabel inside it. Change the Text to “Name.” Put the nametag in ReplicatedStorage. Next, create a server script and write this code:
local ReplicatedStorage = game:GetService(“ReplicatedStorage”)
local Players = game:GetService(“Players”)
local Nametag = ReplicatedStorage.Nametag
Players.PlayerAdded:Connect(function(Player)
Player.CharacterAdded:Connect(function(Character)
repeat wait() until Character:FindFirstChild(“Head”)
local newNametag = Nametag:Clone()
newNametag.Parent = Character.Head
newNametag.Adornee = Character.Head
newNametag.TextLabel.Text = Player.Name
end)
end)
I hope this works. It did for me!
This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.