PDA

View Full Version : what's wrong with this loop?



j0se
May 30th, 2002, 09:16 AM
i want a graphic to flash on and off on a scene, moving the play head back and forth between frames

here's what i got:

frame1:
//var
counter=1;

frame3:
while (counter<100){
gotoAndPlay(2); //the graphic is in this frame
counter=counter+1;
}


i thought it was working until i increased the value in the condition and realised that the graphic flashes for the sme amount of time (a second or 2) regardless of the value - which must mean it's not working!

:(
bah

as always, your help is invaluable!

j0se
May 30th, 2002, 09:51 AM
found the answer - an if statement in frame 3 instead, and it works ok

(sorry) <img src=http://www.ezboard.com/intl/aenglish/images/emoticons/embarassed.gif ALT=":o">

thoriphes
May 30th, 2002, 08:29 PM
try an if statement instead of