i try to run a movie clip for an amount of time (39, 40, etc), this movie clip is a object which moving to a location (x,y). so i try using interval for 1 second, but the problem is every second it load new movie clip and remove the previous one. So the out put is like looping of a object moving for one second only, not yet reach the location (x,y) yet. When i use button (click), it work, i click 5 times, it show 5 object moving to the location(x,y)
here is the script
on(press)
{
setInterval(pass,1000);
function pass()
{
_root.population += 1;
_root.attachMovie(“pass”, “m”+_root.population, this.getNextHighestDepth());
_root[“m”+_root.population].play();
}
}
any idea to make it loop for an amount of time for automatic? thanks for reply