I am making something where It makes you wear a shirt automatically.
person = game.Players.LocalPlayer.Character if person.Shirt ~= nil then -- Means if it isn't nil or not. person.Shirt.ShirtTemplate = "http://www.roblox.com/asset/?id=133991511" else shirt = Instance.new("Shirt") shirt.Name = "Shirt" shirt.ShirtTemplate = "http://www.roblox.com/asset/?id=133991511" end
It will not work. Help?
Thank you for the help.
The template of the shirt won't change online so you have to Clone the shirt into the player, I have done this myself and was also frustrated at the fact of it not working. So try this.
x = Instance.new("Shirt") x.ShirtTemplate = "http://www.roblox.com/asset/?id=133991511" -- If you have not -1 from the end for the shirt I'D game.Players.PlayerAdded:connect(function(plr) z = plr.Character:GetChildren() for i = 1,#z do if z[i].Name = "Shirt" then z[i]:Destroy() x:Clone().Parent = plr.Character end end
If this helped +1, if this answered question check mark :)