this.createEmptyMovieClip('test', this.getNextHighestDepth());
var pics:Array = new Array();
pics[0] = '1.jpg';
pics[1] = '2.jpg';
pics[2] = '3.jpg';
pics[3] = '4.jpg';
pics[4] = '5.jpg';
for ( i = 0; i < pics.length; i++ ){
pic_cont = _root.test.createEmptyMovieClip('pic'+i, this.getNextHighestDepth());
pic_cont._x = 10*i;
pic_cont._y = 10*i;
var img:MovieClipLoader = new MovieClipLoader();
var list:Object = new Object();
img.addListener(list);
list.onLoadStart = function(){
trace("Load started.");
}
list.onLoadError = function(){
trace("Error");
}
img.loadClip( pics*, 'test.pic'+i);
delete img, list;
}
Won’t work and I can’t figure out whats wrong with it. If I trace img.loadClip( pics*, ‘test.pic’+i); it returns false. But the error function never get’s called. Any idea what i’m doing wrong?
EDIT: I’ve got it working, the code is the code i’m using that works, but all of the images stack on top of each other. I can’t figure out how to fix this.