Hello,
#include "mc_tween2.as"
var home:MovieClip = this;
function addMovieClip1():Void {
home.attachMovie("grey", "mcGrey", home.getNextHighestDepth());
mcGrey._x = 100;
mcGrey._y = 120;
updateAfterEvent();
}
function addMovieClip2():Void {
setTimeout(function () {
home.attachMovie("blue", "mcBlue", home.getNextHighestDepth());
mcBlue._x = 100;
mcBlue._y = 120;
mcBlue.yScaleTo(1300, 3, "linear");
home.attachMovie("red", "mcRed", home.getNextHighestDepth());
mcRed._x = 100;
mcRed._y = 120;
//mcRed.tween("_height", 30, 3, "linear");
mcRed.yScaleTo(1500, 3, "linear");
}, 1000);
}
function addMovieClip3():Void {
setTimeout(function () {
home.attachMovie("drop", "mcDrop", home.getNextHighestDepth());
mcDrop._x = 270;
mcDrop._y = 50;
mcDrop.ySlideTo(100, 3, "linear");
mcDrop.xScaleTo(1650, 5, "linear", 3);
}, 6000);
setTimeout(function () {
home.attachMovie("foto", "mcFoto", home.getNextHighestDepth());
mcFoto._x = 100;
mcFoto._y = 92;
}, 15000);
}
addMovieClip1();
addMovieClip2();
addMovieClip3();
I have two buttons( ffd and rrw) with who I can go foward or back in animation.
When I click one time on rrw button, animation will jump to the function who was previous(example, if I animation start addMovieClip2 and If i click on rrw_btn, then animation has to jump to function addMovieClip1 and call function), and has to remove the previous animation. If animation start addMovieClip3 and I hit 2 time or more rrw_btn, animation has to jump to first function. The same will happeing when i hit ffw_btn but there will we jump to next function from 2 to 3 or 1 to 3.