Показать сообщение отдельно
Старый 02.07.2003, 15:21
Iv вне форума Посмотреть профиль Отправить личное сообщение для Iv Посетить домашнюю страницу Iv Найти все сообщения от Iv
  № 10  
Iv
 
Аватар для Iv

Регистрация: Apr 2001
Адрес: Moscow
Сообщений: 1,475
1) грузи все сразу. вот так например:
Код:
_root.load_array = new Array("first.swf", "second.swf", "third.swf");
_root.loadMovies = function(in_array) {
var i = 0, p_mc, n_mc;
for (i; i<in_array.length; i++) {
n_mc = _root.createEmptyMovieClip("targ"+i+"_mc", i);
n_mc.loadMovie(in_array[i]);
in_array[i] = n_mc;
}
_root.onEnterFrame = _root.preload;
_root.txt_string = "please wait. loading...";
return (in_array);
};
_root.preload = function() {
var t, l, p;
for (i in this.mc_array) {
l += this.mc_array[i].getBytesLoaded();
t += this.mc_array[i].getBytesTotal();
}
if (t and t == l) {
delete this.onEnterFrame;
_root.init();
return;
} else if (t and l) {
_root.txt_string = l+" / "+t+" kb \t "+Math.round(l/t*100)+"%";
}
};
_root.mc_array = _root.loadMovies(_root.load_array);
delete _root.load_array;
_root.init = function() {
trace("all is loaded. next step is possible");
};
2) в функции init задай действия. которые тебе нужны после загрузки.