Short circuit light script broken

Right, I’m trying to make a light that looks like it’s short-circuiting but the code seems to stop after changing the part material, I’ve tried changing the colour with Color3 and BrickColor but they don’t seem to work and it just stops the entire script, if I use a local script it just gets stuck at the very start. I think it has got something to do with changing the part colour since that is where the script appears to stop. I may just be using the wrong type of script though.

The model is here: https://gyazo.com/35b6d2be08f0854a09a55708e48623f9

local light1 = script.Parent.Model.Model.P1.SpotLight
local light2 = script.Parent.Model.Model.P2.SpotLight
local light3 = script.Parent.Model.Model.Model.P3.SpotLight
local light4 = script.Parent.Model.Model.Model.P4.SpotLight
local lightp = script.Parent.Part

while true do
	lightp.Material = "Plastic"
	lightp.BrickColor.Name = "Smokey grey"
	
	light1.Enabled = false
	light2.Enabled = false
	light3.Enabled = false
	light4.Enabled = false
	
	wait(.5)
	
	lightp.Material = "Neon"
	lightp.BrickColor.Name = "Pastel light blue"

	light1.Enabled = true
	light2.Enabled = true
	light3.Enabled = true
	light4.Enabled = true
	
	wait(1)
	
	lightp.Material = "Plastic"
	lightp.BrickColor.Name = "Smokey grey"

	light1.Enabled = false
	light2.Enabled = false
	light3.Enabled = false
	light4.Enabled = false
	
	wait(.5)
end

To change the material and brickcolor, DO NOT use strings. Use Enums:
Instead of "Plastic", use Enum.Material.Plastic, and instead of lightp.Brickcolor.Name = "Smokey grey", just use lightp.Brickcolor = Brickcolor.new("Smokey grey"). Use intuition to do this for the other parts.

You can also see errors by going to View at the top, then find Output. Click on it to open output which shows you errors, which is probably why your script is stopping.

Dosen’t seem to work, script is below.

local light1 = script.Parent.Model.Model.P1.SpotLight
local light2 = script.Parent.Model.Model.P2.SpotLight
local light3 = script.Parent.Model.Model.Model.P3.SpotLight
local light4 = script.Parent.Model.Model.Model.P4.SpotLight
local lightp = script.Parent.Part

while true do
	lightp.Material = Enum.Material.Plastic
	lightp.Brickcolor = BrickColor.new("Smokey grey")
	
	light1.Enabled = false
	light2.Enabled = false
	light3.Enabled = false
	light4.Enabled = false
	
	wait(.5)
	
	lightp.Material = Enum.Material.Neon
	lightp.BrickColor.Name = BrickColor.new("Pastel light blue")

	light1.Enabled = true
	light2.Enabled = true
	light3.Enabled = true
	light4.Enabled = true
	
	wait(1)
	
	lightp.Material = Enum.Material.Plastic
	lightp.BrickColor.Name = BrickColor.new("Smokey grey")

	light1.Enabled = false
	light2.Enabled = false
	light3.Enabled = false
	light4.Enabled = false
	
	wait(.5)
end

Can you please open the output and look at what it says there? It’s under the view tab at the top, top left icon in the big group.

You forgot to capitalize the c in lightp.Brickcolor

lightp.Brickcolor = BrickColor.new("Smokey grey")

Changing the brick colour is what breaks it, light works though.

works now just won’t change colour.