part = script.Parent function TouchedBrick()--Function name can be anything! while true do part.Transparency = .5 wait(3) part.Transparency = 0 wait(3) end part.Touched:connect(TouchedBrick)--Touched is an event to a part.
Your only error here is you forgot one end
.
end are important if you want to stop a function
, Loop
or another more things.
here's your code fix ;)
part = script.Parent function TouchedBrick()--Function name can be anything! while true do part.Transparency = .5 wait(3) part.Transparency = 0 wait(3) end end part.Touched:connect(TouchedBrick)--Touched is an event to a part.
here we go now it should work.