here is my code, it runs but nothing is happening and no error.
local purpleLight = game.Workspace.Model.Purple.PointLight local yellowLight = game.Workspace.Model.Yellow.PointLight local greenLight = game.Workspace.Model.Green.PointLight local blueLight = game.Workspace.Model.Blue.PointLight local Trigger = game.Workspace.Trigger function triggert() purpleLight.Enabled = true wait(1) purpleLight.Enabled = false blueLight.Enabled = true wait(1) blueLight.Enabled = false yellowLight.Enabled = true wait (1) yellowLight.Enabled = false greenLight.Enabled = true wait(1) greenLight.Enabled = false end
I believe you are not calling the function, as well as the function command is quite outdated. This is how I would go about it, since I don't know what you want it to be triggered on, I'm using touch.
local purpleLight = game.Workspace.Model.Purple.PointLight local yellowLight = game.Workspace.Model.Yellow.PointLight local greenLight = game.Workspace.Model.Green.PointLight local blueLight = game.Workspace.Model.Blue.PointLight local Trigger = game.Workspace.Trigger Trigger.Touched:Connect(function(hit) if hit.Parent:FindFirstChild('Humanoid') then purpleLight.Enabled = true wait(1) purpleLight.Enabled = false blueLight.Enabled = true wait(1) blueLight.Enabled = false yellowLight.Enabled = true wait (1) yellowLight.Enabled = false greenLight.Enabled = true wait(1) greenLight.Enabled = false end end)
Let me know if this works!
Try adding "triggert()" at the end of the script.