My floor is supposed to change from outter layer to last layer in color, like in those club's like club sanity. Here's my script:
local outter = game.Workspace.outter:GetChildren()
local second = game.Workspace.second:GetChildren()
local third = game.Workspace.third:GetChildren()
local last = game.Workspace.last:GetChildren()
while true do
for i,v in pairs(outter) do
spawn(function()
v.BrickColor = BrickColor.Red()
wait(1)
v.BrickColor = BrickColor.Black()
end)
end
for b,n in pairs(second) do
spawn(function()
n.BrickColor = BrickColor.Red()
wait(1)
n.BrickColor = BrickColor.Black()
end)
end
for h,j in pairs(third) do
spawn(function()
j.BrickColor = BrickColor.Red()
wait(1)
j.BrickColor = BrickColor.Black()
end)
end
for o,p in pairs(last) do
spawn(function()
p.BrickColor = BrickColor.Red()
wait(1)
p.BrickColor = BrickColor.Black()
end)
end
wait(1)
end
Here's a video of what is going on: https://gyazo.com/43c8a28164465867f24b264b2a2b8245
All help is appreciated!

1 comment
I have no idea how the second part of the code works, but I understand the first part. That part helped. Thanks! You don't need to explain the second part. I'd rather go step by step slowly. I'll get into the stuff you're showing later on. Thanks so much for your help! :D