I'm surprised it makes a noticeable difference but... resetting your frame to the start is using an added IF statement. Maybe try using MOD instead. This means the same number of statements are executed every time through the loop so the timing should be better.
Also note I added a tNumFrames variable so the routine will work for any animated gif. Just replace the 36 with the correct number and off you go. ---------------- put the currentFrame of image "imgSpinner" into tCurrentFreim put 1 into tEnough ---------- Added line ---------- put 36 into tNumFrames ------------------------------ repeat until the mouse is up play "ding.wav" wait 80 milliseconds ---------- New lines start ---------- add 1 to tCurrentFreim set the currentFrame of image "imgSpinner" to tCurrentFreim mod tNumFrames if tCurrentFreim > 95 then send mouseUp to me ---------- New lines end ---------- end repeat ---------------- Hope this helps (and was right... I'm still learning) -- Jim M > From: "kweto" <[EMAIL PROTECTED]> > Reply-To: How to use Revolution <[EMAIL PROTECTED]> > Date: Mon, 20 Sep 2004 17:38:17 +0900 > To: "How to use Revolution" <[EMAIL PROTECTED]> > Subject: slight delay in animated gif loop > > My only guesses as to why are that (1) either the "repeat... if" control > structure requires a bit more processing time, or (2) I have neglected to > set some image property I am not aware of. (Incidentally, the gif plays > smoothly when tested on a browser.) > > Here's the bit of script: > > put the currentFrame of image "imgSpinner" into tCurrentFreim > put 1 into tEnough > repeat until the mouse is up > play "ding.wav" > wait 80 milliseconds > -- long enough for the soundfile to play (and, yes > -- I tried "wait until the sound is done" but yuch!) > if tCurrentFreim > 35 then put 0 into tCurrentFreim > if tCurrentFreim < 37 then add 1 to tCurrentFreim > set the currentFrame of image "imgSpinner" to tCurrentFreim > add 1 to tEnough > if tEnough > 95 then send mouseUp to me > end repeat > ---------------- _______________________________________________ use-revolution mailing list [EMAIL PROTECTED] http://lists.runrev.com/mailman/listinfo/use-revolution
