How to I make a unique nametag?
I am making a game where instead of the boring nametags above the players heads I want a custom one which has random colors and goes above the persons head. I tried and I can't seem to get it to work. Can anybody help me? Thanks!
Here is the code:
02 | Color 3. fromRGB( 0 , 100 , 200 ), |
03 | Color 3. fromRGB( 200 , 0 , 0 ), |
04 | Color 3. fromRGB( 0 , 200 , 0 ), |
07 | local Players = game:GetService( "Players" ) |
09 | local gui = game.ServerStorage.BillboardGui |
11 | local clone = gui:Clone() |
13 | Players.PlayerAdded:Connect( function (player) |
15 | clone.Parent = game.Workspace [ player ] |
16 | local newgui = game.Workspace [ player ] :WaitForChild( "BillboardGui" ) |
17 | newgui.TextLabel.Text = player.name |
18 | newgui.TextLabel.TextColor = Color 3 |
19 | newgui.TextLabel.TextColor 3 = colors [ math.random( 1 , #colors) ] |