How do I make it so when people join my game, they wear a certain shirt?
I'm trying to make a new game, and I can't find out how. Please help, and thanks!
This will work.
local shirtid= --Put the ID here. No need to subtract one, the script does that local pantsid= --Put the ID here. No need to subtract one, the script does that Game.Players.PlayerAdded:connect(function(p) p.CharacterAdded:connect(function() if p.Character:FindFirstChild("Shirt") then p.Character.Shirt:Destroy() end if p.Character:FindFirstChild("Pants") then p.Character.Pants:Destroy() end local shirt=Instance.new("Shirt") shirt.ShirtTemplate="http://www.roblox.com/asset/?id="..(shirtid-1) shirt.Parent=p.Character local shirt=Instance.new("Pants") pants.PantsTemplate="http://www.roblox.com/asset/?id="..(pantsid-1) pants.Parent=p.Character end) end)
If I were you, I would remove their current one and either clone one in from lighting or insert a new one with a certain AssetID.
game.Players.PlayerAdded:connect(function(plr) s = Player:FindFirstChild("Shirt") if s then s:Destroy() end Instance.new("Shirt").AssetID = IDhere end)
That should do it.
Change their character's shirt's ShirtTemplate property to the asset id of the desired shirt template.
Same with me but i want to know how to do it with the whole body instead of just one part