How to keep a BillboardGui into a player character after it's death?

Hello everyone! :smiley:
I’ve made a name tag with a BillboardGui, and I’ve ran into a problem: whenever the player dies after it respawns the tag disappears.
To fix this problem I’ve tryied to connect a Died event to the PlayerAdded event, and I wrote this snippet of code:

game.Players.PlayerAdded:Connect(function(plr)
    plr.Character:FindFirstChild("Humanoid").Died:Connect(function()
        local tagClone = game.ReplicatedStorage.NameTag:Clone()
        --- other code here
    end
end

The problem is that it works only one time (does it works only one time because it gets garbage collected?).
Have you got any idea on how to fix the problem (or another method to accomplish this)?

Thanks in advance!

image Turn this off on the BillboardGui

It doesn’t work :slightly_frowning_face:

Anyway I’ve found a workaround: I’ve used a local script firing an event each time the player dies, and a server script that listens to this event and create a new copy of the tag, parenting it to the player’s character.

Anyway thanks! :smiley:

2 Likes