swftools-common
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Swftools-common] avoid loop in video SWF


From: Chris
Subject: Re: [Swftools-common] avoid loop in video SWF
Date: Wed, 3 Nov 2010 08:19:34 +0100

On Tue, 2 Nov 2010 16:55:33 -0700
Matthias Kramm <address@hidden> wrote:

> On Tue, Nov 02, 2010 at 09:26:14PM +0100, Pablo Rodr?guez <address@hidden> 
> wrote:
> > .flash filename="video-slide.swf" bbox=841x545 version=7
> > .swf movie "video-snippet.swf"
> > .frame 1
> >       .put movie
> >       .stop
> >       .action:
> >           movie._x = (Stage.width - movie._width) / 2;
> >           movie._y = (Stage.height - movie._height) / 2;
> >       .end
> > .frame 2
> >       .del movie
> > .end
> > 
> > Is there a way here to prevent the loop in the embedding script?
> 
> I guess you could run a loop in the parent, telling the
> child to stop after reaching the last frame:
> 
> .frame 1
>   .put movie
>   .action:
>       if(movie._currentframe == movie._totalframes) {
>       movie.stop();
>       }
>   .end
> .frame 2
>   .action
>       gotoFrame(1);
>   .end
> 
> (You need two frames in the parent in order to re-execute the script)
> 
> Matthias

Then  again, you could if you wished remove the .frame tags completely, and do
the whole thing with script.  As per the example under 'Load another SWF', here,

        http://wiki.swftools.org/index.php/Swfc_Code_Snippets

Chris.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]