il problema è che non puoi usare lo stesso intervalID per entrambi i caricamenti
prova a modificare il tuo script in questo modo:
codice:function preload1(clip1, width1, height1, interval){ car = clip1.getBytesLoaded(); tot = clip1.getBytesTotal(); perc = Math.round((car/tot)*100); clip1.createTextField("testo", 1, (this._width/2), (this._height/2), 200, 20); clip1.testo.wordWrap = true; testoformat = new TextFormat(); testoformat.color = "0x123466"; testoformat.font = "Verdana"; clip1.testo.setTextFormat(testoformat); if(!isNaN(perc)) { clip1.testo.text = "Caricamento..."+perc+"%"; clip1.testo.setTextFormat(testoformat); } if(car == tot && tot>1024){ clearInterval(this[interval]); altezza = (clip1._height*width1)/clip1._width; larghezza = (clip1._width*height1)/clip1._height; if (clip1._width > width1 || clip1._height > height1){ if (clip1._height < clip1._width){ clip1._width = width1; clip1._height = altezza; } else if (clip1._height > clip1._width){ clip1._width = larghezza; clip1._height = height1; } else { clip1._width = clip1._height = height1; } if(clip1._height > height1){ clip1._height=height1; clip1._width=larghezza; } } clip1.testo.text = ""; } }; this.createEmptyMovieClip("contenitore_mc1",this.getNextHighestDepth()); contenitore_mc1.loadMovie("image1.jpg"); this["c"] = setInterval(preload1, 100,contenitore_mc1, 100, 100, "c"); contenitore_mc1._x = -301.4; contenitore_mc1._y = -128.4; this.createEmptyMovieClip("contenitore_mc2",this.getNextHighestDepth()); contenitore_mc2.loadMovie("image2.jpg"); this["d"] = setInterval(preload1, 100,contenitore_mc2, 100, 100, "d"); contenitore_mc2._x = -107; contenitore_mc2._y = -128.4;

Rispondi quotando