I’m using 5.0 also… don’t worry about it.
I would use action script to do everything. No tweening at all. Mind you, the reason I asked was that this does not work in every situation. It might be recomendable not to use action script if you’re going to have a couple of those that can’t transition well. If you only have a couple, they become a distraction to the viewer. If there’s an even mix of both kinds then it’s not too bad.
For scaling, as with movement, we need to adjust the property of the object in question, using a button… Likewise we need the object to continue towards the proper course without disturbing it’s path to that eventual state of being.
Make sure that the movie clip and the button are located in the same timeline. In my example the movie clip has been given an instance name of “scaledClip”.
Now… keep this in mind. If the movie clip has stuff going on on it’s own timeline which makes it’s play head stop, then the onClipEvent on it will stop working until the movie clip starts playing again. If this is the case, then you’ll need to place the movie inside another movie clip.
on the movie clip which will be constantly playing, and located on the same timeline as the button you place this code.
onClipEvent(load){
trip=1;
rateOfChange=5;
}
onClipEvent(enterFrame){
if(trip=1&&_yscale<100){
this._yscale+=rateOfChange;
this._xscale+=rateOfChange;
}else if(trip==0&&_yscale>0){
this._yscale-=rateOfChange;
this._xscale-=rateOfChange;
}
}
the button then has this.
on(rollOver){
_parent.scaledClip.trip=1;
}
on(rollOut){
_parent.scaledClip.trip=0;
}
this is it with added alpha code added. Notice in this one I left out all those “this”'s which are really unnecessary in an onClipEvent method.
onClipEvent(load){
trip=1;
rateOfChange=5;
}
onClipEvent(enterFrame){
if(trip=1&&_yscale<100){
_alpha+=rateOfChange;
_yscale+=rateOfChange;
_xscale+=rateOfChange;
}else if(trip==0&&_yscale>0){
_alpha-=rateOfChange;
_yscale-=rateOfChange;
_xscale-=rateOfChange;
}
}
the button then has this.
on(rollOver){
_parent.scaledClip.trip=1;
}
on(rollOut){
_parent.scaledClip.trip=0;
}