I'm making a XML banner rotator and recently introduced TimelineLite. I started using it since the flash.utils.timer doesn't have a pause() method (which is totally ridiculous). I ended up ridding of the timer completely since there's an onComplete param for the timeline. Here's what I'm trying to do:
http://dev.archonic.com/mint/HomepageBa ... index.html
Pretty self-explanatory. When the mouse hovers above the container, the timer (which is now just a TweenMax tween) pauses. Mouse off and it resumes. Then when the tween is done, the same thing happens with the next banner. As you can see it's not quite doing that.
Every time a slide is loaded, a function is called to update the colours of the navigation items (called updateNavColours):
function updateNavColours():void {
//Idle colours
for(var i:uint = 0; i if(i != current) {
TweenMax.to(navItems[i].navNum_bg, 0, {tint:navBG_IDLE, scaleX:1, scaleY:1, overwrite:true})
TweenMax.to(navItems[i].num, 0, {tint:navTXT_IDLE});
TweenMax.killTweensOf(navItems[i].navShine_mc, false);
}
}
//Selected colour
TweenMax.to(navItems[current].navNum_bg, 0.2, {scaleX:1, scaleY:1, tint:navBG_SELECTED});
TweenMax.to(navItems[current].num, 0.2, {tint:navTXT_SELECTED});
navTimeline.insert( TweenMax.from(navItems[current].navShine_mc, slideData[current][2], {width:0, ease:Linear.easeNone}) );
navTimeline.resume();
}
I've tried using navTimeline.killTweensOf, navTimeline.append, adding a label at the end of the tween and using gotoAndStop and gotoAndPlay, removing the tween from the timeline, etc.
It was working when the timeline was less involved (used only for pausing on mouse over) and the flash timer called the next slide. I'd could always go back but this seems like a more elegant solution. And I'd like to understand timline lite a little better
Any ideas?
PS - I watched the timeline basics video, very helpful! Is that timeline advanced video you talked of available?