Guys I created a christmas decoration widget with 13 lights and I want to make them blink.
I used 13 TimeCores for each light, I changed the Refresh interval(ms) of each one (same value for the same color light) and I used this script.
Code:
function timercore1OnUpdate(Sender)
{
l1.Visible = true;
sleep(1000);
l1.Visible = false;
}
function timercore2OnUpdate(Sender)
{
l2.Visible = true;
sleep(1000);
l2.Visible = false;
}
function timercore3OnUpdate(Sender)
{
l3.Visible = true;
sleep(2000);
l3.Visible = false;
}
function timercore4OnUpdate(Sender)
{
l4.Visible = true;
sleep(1000);
l4.Visible = false;
}
function timercore5OnUpdate(Sender)
{
l5.Visible = true;
sleep(1000);
l5.Visible = false;
}
function timercore6OnUpdate(Sender)
{
l6.Visible = true;
sleep(1000);
l6.Visible = false;
}
function timercore7OnUpdate(Sender)
{
l7.Visible = true;
sleep(1000);
l7.Visible = false;
}
function timercore8OnUpdate(Sender)
{
l8.Visible = true;
sleep(1000);
l8.Visible = false;
}
function timercore9OnUpdate(Sender)
{
l9.Visible = true;
sleep(1000);
l9.Visible = false;
}
function timercore10OnUpdate(Sender)
{
l10.Visible = true;
sleep(1000);
l10.Visible = false;
}
function timercore11OnUpdate(Sender)
{
l11.Visible = true;
sleep(1000);
l11.Visible = false;
}
function timercore12OnUpdate(Sender)
{
l12.Visible = true;
sleep(1000);
l12.Visible = false;
}
function timercore13OnUpdate(Sender)
{
l13.Visible = true;
sleep(1000);
l13.Visible = false;
}
The script seems to work partially but the bad is that the cpu is too high(!)..
Any idea or any other way to do this...?
_________________
...and remember: don't take life too seriously...My profile on Deviantart:
http://jimking.deviantart.com/