Hi, the script does work on Dynamic Lighting which I use. But I am using the same script to change the material of the light bulb. How do I fix this?

function change()
for i = 1, 8 do
workspace:FindFirstChild("BasicLightLane"..i).Material.("Neon") = not workspace:FindFirstChild("BasicLightLane"..i).Material.("Neon")
if workspace:FindFirstChild("BasicLightLane"..i).Material.("Plastic") then
end
end
end

script.Parent.MouseButton1Down:connect(change)

1 comment

0

I just left a few bits on where it operates the switch, oops.