So I have been trying to find something like this and I found some that's 5 years old but what I need is to touch a block and get a hat put on my head but I some how cant find out how to and this is what I found and it works! But I thought I found it but it was wrong so can you help me with it? |Script|
shirtid = "http://www.roblox.com/asset/?id=751061408"
pantsid = "http://www.roblox.com/asset/?id=1134006219"
accessoryid = "https://web.roblox.com/catalog/416833190/Tokyokhaos-Lion"
script.Parent.Touched:connect(function(hit)
if hit.Parent:findFirstChild("Humanoid")then
char = hit.Parent
if char:findFirstChild("Shirt") then
char.Shirt.ShirtTemplate = shirtid
else
a = Instance.new("Shirt", char)
a.Name = "Shirt"
a.ShirtTemplate = shirtid
end
if char:findFirstChild("Pants") then
char.Pants.PantsTemplate = pantsid
else
b = Instance.new("Pants", char)
b.Name = "Pants"
b.PantsTemplate = pantsid
end
if char:findFirstChild("Accesory") then
char.Pants.PantsTemplate = pantsid
else
b = Instance.new("Accessory", char)
b.Name = "Accessory"
b.HatTemplate = accessorysid
end
end
end)
|Info| The clothing part works its just the hat part the dose not! |Warning!| Anybody can use the fixed script!

4 comments
Accessories don't have a property called HatTemplate
Then how do I fix it?
So like speacial mesh?
I guess you can do that