-
prevframe? help it wont work
is there a way to tween backwards on rollout...cuz im doing a button on rollover gotoAndPlay 2 and on rollout PrevFrame(); how do i get to treew back???? help please thanks
-
You might be able to adapt this.
What it does is create an onEnterFrame function that navigates to previous frame each time when the direction is backwards or navigates to the next frame if the direction is forwards.
There is some more gubbins in there to allow you to set speeds as well, but hey, some days ...
Last edited by AlsoGaiusCoffey; 07-11-2008 at 07:31 AM.
-
thats cool...but um isnt there simpler code than that...usALLY I DONT UNDERSTAND UNLESS I ROTE IT..oops sorry bout the caps.um what if i send u the fla and tell u what i want the u fix it then ill understand it maybey...
-
cuz what i did was a while loop heres the code i have
-
the code is
onClipEvent (enterFrame) {
this.onRollOver = function() {
this.gotoAndPlay(2);
};
this.onRollOut = function() {
do {
prevFrame();
} while (this._currentframe > 1);
};
}
thats on the mc
-
-
Your problem is that the prevFrame action only occurs when you are rolling over or rolling out.
Try this:
PHP Code:
this.onRollOut = function() {
this.onEnterFrame = go_backward;
};
function go_backward() {
if (this._currentframe>1) {
prevFrame();
}
}
this.onRollOver = function() {
delete this.onEnterFrame;
this.gotoAndPlay(2);
};
-
nice thanks man that works
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|