of     1   

Aelerity
#170665217Monday, August 10, 2015 7:32 PM GMT

wait (5) if 1 then script.Parent.BrickColor = BrickColor.new == "Really red" if 2 then script.Parent.BrickColor = BrickColor.new == "Really blue" if 3 then script.Parent.BrickColor = BrickColor.new == "New Yeller" if 4 then script.Parent.BrickColor = BrickColor.new == "Hot pink" if 5 then script.Parent.BrickColor = BrickColor.new == "Lime green" end while true do wait (.25) math.random(1,5) end end end end end This doesn't work. Basically what I want is after 5 seconds the script picks a random number between 1 and 5 every .25 seconds and the brick becomes that color. And it does this forever. But it doesn't work. "There's candy in the white van kids!"
DeathsLASTwords
#170666484Monday, August 10, 2015 7:45 PM GMT

while true do wait(5) local rand = math.random(1,5) if rand == 1 then script.Parent.BrickColor = BrickColor.new == "Really red" if rand == 2 then script.Parent.BrickColor = BrickColor.new == "Really blue" if rand == 3 then script.Parent.BrickColor = BrickColor.new == "New Yeller" if rand == 4 then script.Parent.BrickColor = BrickColor.new == "Hot pink" if rand == 5 then script.Parent.BrickColor = BrickColor.new == "Lime green" end end end end end end
Aelerity
#170670022Monday, August 10, 2015 8:15 PM GMT

Everytime i do your script it crashes :/ "There's candy in the white van kids!"
DeathsLASTwords
#170670147Monday, August 10, 2015 8:16 PM GMT

Give me a moment to test
DeathsLASTwords
#170670399Monday, August 10, 2015 8:19 PM GMT

you tried to make a boolean with the brick color... it works fine on a baseplate, tried it myself, heres the new script, just put the script into a brick... while true do wait(5) local rand = math.random(1,5) if rand == 1 then script.Parent.BrickColor = BrickColor.new("Really Red") if rand == 2 then script.Parent.BrickColor = BrickColor.new("Really blue") if rand == 3 then script.Parent.BrickColor = BrickColor.new("New Yeller") if rand == 4 then script.Parent.BrickColor = BrickColor.new( "Hot pink") if rand == 5 then script.Parent.BrickColor = BrickColor.new("Lime green") end end end end end end
DeathsLASTwords
#170670510Monday, August 10, 2015 8:20 PM GMT

wait (5) if 1 then script.Parent.BrickColor = BrickColor.new == "Really red" if 2 then script.Parent.BrickColor = BrickColor.new == "Really blue" if 3 then script.Parent.BrickColor = BrickColor.new == "New yeller" if 4 then script.Parent.BrickColor = BrickColor.new == "Hot pink" if 5 then script.Parent.BrickColor = BrickColor.new == "Lime green" end while true do wait (.25) math.random(1,5) end end end end end -- of course you capitalized them wrong too...
DeathsLASTwords
#170670622Monday, August 10, 2015 8:21 PM GMT

^^ New Yeller* (my keyboard has an autocorrect function app thingy )
KEVEKEV77
#170671703Monday, August 10, 2015 8:29 PM GMT

no. while true do local ran = math.random(1,5) wait (5) if ran == 1 then script.Parent.BrickColor = BrickColor.new("Really red") end if if ran == 2 then script.Parent.BrickColor = BrickColor.new("Really blue") end if ran == 3 then script.Parent.BrickColor = BrickColor.new("New yeller") end if ran == 4 then script.Parent.BrickColor = BrickColor.new("Hot pink") end if ran == 5 then script.Parent.BrickColor = BrickColor.new("Lime green") end end
CaptainGector
#170671942Monday, August 10, 2015 8:31 PM GMT

This is what I did: while true do wait(1) local rand = math.random(1,5) print(rand) if rand == 1 then script.Parent.BrickColor = BrickColor.new(21) elseif rand == 2 then script.Parent.BrickColor = BrickColor.new(1010) elseif rand == 3 then script.Parent.BrickColor = BrickColor.new(1009) elseif rand == 4 then script.Parent.BrickColor = BrickColor.new(1032) elseif rand == 5 then script.Parent.BrickColor = BrickColor.new(1020) else print("Error") end end
lupine
#170672136Monday, August 10, 2015 8:33 PM GMT

colors = {21,1010,1009,1032,1020} while wait(1) do local r = colors[math.random(1,#colors)] script.Parent.BrickColor = BrickColor.new(r) end That should do it.
CaptainGector
#170672319Monday, August 10, 2015 8:35 PM GMT

The original script used BrickColor.new == " " I used Brickcolor.new(0) I reverted to color codes after the script kept failing to run, even though it was printing out the correct numbers.
CaptainGector
#170672400Monday, August 10, 2015 8:35 PM GMT

@Lup That's the RIGHT way to do it!
Aelerity
#170675092Monday, August 10, 2015 8:58 PM GMT

ok thanks guys for your help! "There's candy in the white van kids!"

    of     1