How do i make a player's clothes appear when they died/respawned?
I have a script where it morphs the players shirt, and pants, but when they die, it disappear.
This is the script :
01 | game.Workspace.ChildAdded:connect( function (player) |
02 | local name = player.Name |
03 | local playerinplayers = game.Players:FindFirstChild(player.Name) |
04 | if playerinplayers ~ = nil then |
05 | playerinplayers.CanLoadCharacterAppearance = false |
07 | player.Head.Transparency = 0 |
08 | local bodycolors = Instance.new( "BodyColors" , player) |
09 | bodycolors.TorsoColor = BrickColor.new( "Pastel yellow" ) |
10 | bodycolors.RightArmColor = BrickColor.new( "Pastel yellow" ) |
11 | bodycolors.LeftArmColor = BrickColor.new( "Pastel yellow" ) |
12 | bodycolors.HeadColor = BrickColor.new( "Pastel yellow" ) |
13 | bodycolors.LeftLegColor = BrickColor.new( "Pastel yellow" ) |
14 | bodycolors.RightLegColor = BrickColor.new( "Pastel yellow" ) |
16 | local shirt = Instance.new( "Shirt" , player) |
18 | local pants = Instance.new( "Pants" , player) |
20 | script.Disabled = true |