Hi, im making a game were I need the pointlight in my brick to change colors. Not random colors, specific colors I want. (Red, orange, yellow, neon green, green, cyan, blue, magenta, purple.) I would like these to repeat forever. Not really fast though, I dont plan on my players getting seizures. Like the colors will cycle in a minute of so then the cycle repeats.
Please help me out with this!
THANKS!
~123bbz
I see that you need one. What are you going to do to get it? If you need help scripting ask a question. Anything other than scripting questions post on the ROBLOX forum.
This may not be the most efficient, but it will do the job. It uses a for loop to "tween" the colors.
while true do for i=1, 60 do script.Parent.Color = Color3.new(1, i/60, 0) wait(.1) end for i=1, 60 do script.Parent.Color = Color3.new(1-(i/60), 1, 0) wait(.1) end for i=1, 60 do script.Parent.Color = Color3.new(0, 1, i/60) wait(.1) end for i=1, 60 do script.Parent.Color = Color3.new(0, 1-(i/60), 1) wait(.1) end for i=1, 60 do script.Parent.Color = Color3.new(i/60, 0, 1) wait(.1) end for i=1, 60 do script.Parent.Color = Color3.new(1, 0, 1-(i/60)) wait(.1) end end