lightPart = script.Parent
local canLight = true
function lightOn(bodypart)
if canLight then
canLight = false
local light = Instance.new("PointLight")
light.Parent = lightPart
light.Range = 25
light.Brightness = 5
wait(5)
lightPart.PointLight:Destroy()
canLight = true
end
end
lightPart.Touched:Connect(lightOn)
lightPart = script.Parent
local canLight = true
function lightOn(bodypart)
if canLight then
canLight = false
local light = Instance.new("PointLight")
light.Parent = bodypart
light.Range = 25
light.Brightness = 5
wait(5)
bodypart.PointLight:Destroy()
canLight = true
end
end
lightPart.Touched:Connect(lightOn)