multicolor text problem

Hi. This is probably a really stupid question because i'm new to Corona, but basically, what i'm trying to do is to get a piece f text to go through all the colors it possibly could. My code so far is this:
local endgame = display.newText( "You Lose!",100,200, ,124)

local function multic()
for a=0,255 do
for b=0,255 do
for c=0,255 do
endgame:setTextColor( a,b,c)
c=c+1

end
b=b+1
end
a=a+1
end

end
timer.performWithDelay(100, multic)

Unfortunately, when i run the program, it stops responding for about a minute, and then comes back again with black text. Help is desperately needed.

Hi Christopher,

Here's why it does not work

You are setting the color fast, really fast, but the app is not getting a breather to update itself.

Secondly, if you are trying to skip , you can set that in the loop itself as

1
2
 for a=0,255,2 do
 end

Thanks a lot, this really helps.
Another question:
how do you get the code to go different colours instead of just remaining normal?
Thanks again.

views:1655 update:2011/10/11 8:57:46
corona forums © 2003-2011