So, I have this script. I'm trying to disable a SpotLight when someone clicks on the gui. The script in the GUI is this:
car = game.workspace.Car
function onClicked()
car.Headlight1.SpotLight.Enabled = false
car.Headlight2.SpotLight.Enabled = false
end
script.Parent.MouseButton1Click:connect(onClicked)
I'm new to scripting, so this could be completely wrong. Just need some help, hope someone can help. |