I was making Curtains for my camper Done it correctly Copied of the WIKI, Here's what I typed
function onClick(playerwhoclicked) script.parent.brickcolor = BrickColor.Random() end
script.Parent.ClickDetector.MouseClick:connect(onClick)
I was making Curtains for my camper Done it correctly Copied of the WIKI, Here's what I typed
function onClick(playerwhoclicked) script.parent.brickcolor = BrickColor.Random() end
script.Parent.ClickDetector.MouseClick:connect(onClick)
This discussion is preserved as it was. New answers, comments, and votes are closed.
1 comment
You didn't do it correctly... Lua is case sensitive. Meaning "parent" should be "Parent" and "brickcolor" should be "BrickColor".