My project almost done

Hi, probably someone can help me here.

I’m re-doing my portfolio and i just got a problem and i can’t finds any solution…

Oki, the basic idea is to have a picture for each hour of the day as a background. here is my test file:http://www.cedricanderson.net/v2/test2.fla

I have no content in that file, it just have code which is:


import mx.transitions.Tween;
import mx.transitions.easing.*;

var maintenant = new Date();
var heure = maintenant.getHours();
var minute = maintenant.getMinutes();
var seconde = maintenant.getSeconds();
var pic = (heure + ".jpg");
var deuxieme = (heure++);
var pic2 = (deuxieme + ".jpg");
var temps = (60);
var pourcent = (minute / 60 * 100);
var pourcent2 = ((minute + 1) / 60 * 100);


if(heure <= 2){
    _root.createEmptyMovieClip("conteneur",0);
     conteneur.loadMovie("22.jpg");
}

else{
    _root.createEmptyMovieClip("conteneur",0);
         conteneur.loadMovie(pic);
    _root.createEmptyMovieClip("conteneur2",1);
          conteneur2.loadMovie(pic2);
        new Tween(conteneur2, "_alpha", Regular.easeIn, pourcent, pourcent2, temps, true)
}

loadMovieNum("horloge.swf",5);

my timeline is 600frames long (at 10img/sec)

So the main problem for now is that when it reache the 600th frames and go back to the first one, it make a “flash”. Is there a way to change that? in fact, i would like to dont have 600frame on the timeline, if i could do the same thing in a loop inside the code, it would be pretty nice (but i dont know how to use loop)

So if someone see anyway i could make that easier and better :slight_smile:

thank you!!