Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

Clicking block to add hat onto player?

Basically set up everything except what happens when it is clicked, I have no idea how to insert a hat directly onto someone's head.

Thanks.

1 comment

0

Not a request site, unless you show your own script.

1 answer

local clickDet = Instance.new("ClickDetector", script.Parent) --Creats a ClickDetector and parents the part


function onClicked(plr)
	local accessory = game.Lighting['ACCESSORY NAME HERE']:Clone() --Put the accessory in lighting, or someplace else
	accessory.Parent = plr.Character
end

clickDet.MouseClick:Connect(onClicked)

I use this method for doing my accessorizing! Hope this helps.

This discussion is preserved as it was. New answers, comments, and votes are closed.