I'm making an Alarm system for a game I'm working on. When the player touches a laser beam being emitted from a sentry camera and is spotted the alarms part should change the colour to Bright Red. I don't know whats going wrong with my local script and there aren't any errors printed out. Code:
function onTouch(hit)
script.Parent.BrickColor = BrickColor.new("Really red")
end
script.Parent.Touched:connect(onTouch)
Please help me with this issue. Thank you in advance.

4 comments
Use Scripts instead of LocalScripts, it should work.
ok
Thank you, its solved now.
i gave more information about that issue, please accept it as an answer. Thanks