Jump to content
Search Community

TweenlineMax inside different frames

procastino test
Moderator Tag

Recommended Posts

Hi!

First of all, thanks for this great tool, I'm quite a newbie to AS3 and it's helping me a lot to get my job done.

I have a question that probaly comes from not using it appropiately, hope you forgive... :)

I have been making an animation in which I want different items to tween at different times when different buttons are rolled over.

I have a main timeline and a "image" timeline. On the first frame of the main timeline I have this code, which makes "image" timeline go to a labeled frame, depending on the button you roll over.

function botonsOver (e:MouseEvent):void{
var botonItem:MovieClip= e. target as MovieClip;
	image.gotoAndStop(botonItem.name);

 

on the labeled frame I put the TimelineMax code, very simple actions like:

var tlCalor:TimelineMax=new TimelineMax();
tlCalor.appendMultiple([
					TweenMax.from(raiosIv1, .5,{x:-340,y:-260}),
					TweenMax.from(raiosIv2, .5,{x:-95,y:-330})
					],.5, TweenAlign.START,.4); 

It worked all right but, in a specific labeled frame, if the duration of the Tweenings is too long, the tweening simply ends up without reaching the end. I found out that this doesn't happen if I insert more frames on the timeline, but I didn't have to do this on the previous labeled frames...

Hope I explained myself... Any idea what can be happening?

Thanks a lot!

Link to comment
Share on other sites

Hi Procrastino,

 

I am having difficulty understanding.

perhaps if you post a simplified fla file I can be of more assistance.

 

If adding frames seems to be a solution, i'm guessing that perhaps the timeline where you are running out of frames may need a stop() action somewhere. maybe where you have the code

 

var tlCalor:TimelineMax=new TimelineMax();
tlCalor.appendMultiple([
                 TweenMax.from(raiosIv1, .5,{x:-340,y:-260}),
                 TweenMax.from(raiosIv2, .5,{x:-95,y:-330})
                 ],.5, TweenAlign.START,.4);

stop()

 

 

your previous gotoAndStop should make that unnecessary but I really don't know what the trouble is.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...