Haiat
05.12.2007, 18:56
Как сделать задержку цикла?то есть чтобы когда происходит onLoad он не переходил к следущему шагу,а только с помощью continue
for (q=0; q<news[0].length; q++) {
clip = _root.n.attachMovie("novost", "novost"+q, q);
clip.razdel.text = news[0][q];
clip.razdel.pole.autoSize = true;
clip.text.pole.autoSize = true;
clip.text.text = news[1][q];
clip._x = 0-clip._width;
img = clip.createEmptyMovieClip("novost"+q+"image", clip.getNextHighestDepth());
loadMovie("1.jpg", img);
img.onLoad = function() {
img._x = 0;
img._y = clip._height+5;
clip._y = 0+hg;
hg += clip._height+img._height+10;
continue;
};
}
for (q=0; q<news[0].length; q++) {
clip = _root.n.attachMovie("novost", "novost"+q, q);
clip.razdel.text = news[0][q];
clip.razdel.pole.autoSize = true;
clip.text.pole.autoSize = true;
clip.text.text = news[1][q];
clip._x = 0-clip._width;
img = clip.createEmptyMovieClip("novost"+q+"image", clip.getNextHighestDepth());
loadMovie("1.jpg", img);
img.onLoad = function() {
img._x = 0;
img._y = clip._height+5;
clip._y = 0+hg;
hg += clip._height+img._height+10;
continue;
};
}