Hi, I’m trying to make a load previous shirt script from character viewport. So basically if you die the character viewport will give you the previous shirt you were wearing.
This is the script that I’m working on:
local Player = game.Players.LocalPlayer
local Char = Player.Character
local Shirt = Player.PlayerGui.UniformGUI.Frame.ViewportFrame.ViewportCharacter.Character.Shirt
Char:WaitForChild("Humanoid").Died:Connect(function()
Shirt:Clone()
wait(8)
game.Workspace[Player.Name].Shirt:Destroy()
wait(1)
Shirt.Parent = game.Workspace[Player.Name]
end)
I still have no clue why this won’t work but any helps will be appreciated, Thanks.