I’ve create a flash file that when u click a button it imports an external swf file into content movie clip.
Does anybody know how to create a button within the main swf file that can rewind the external file?
I’ve tried using the code below, but it just rewinds through the whole swf file.
on (release) {MovieClip.prototype.playF = function(m, n, fps) {
function playF2(mc) {
if (mc.m<mc.n) {
mc.nextFrame();
} else {
mc.prevFrame();
}
if (mc._currentframe == mc.n) {
clearInterval(mc.int);
}
updateAfterEvent();
}
this.m = m;
this.n = n;
this.fps = fps;
this.gotoAndStop(this.m);
clearInterval(this.int);
this.int = setInterval(playF2, 1000/this.fps, this);
};
MovieClip.prototype.stopF = function() {
clearInterval(this.int);
};
//----------------------- don’t change anything above this line -------------------------
// to rewind from the current frame to frame 1 at 25 fps:
_root.playF(_root.content,20,5);
}
Thanks