Question
need countdown timer for game
i'm making a shooting game i need a timer that counts down
and then when it gets to 0 it goes to a certain frame. This is the
code i'm using:
var seconds:Number=10;
time_txt.text="";
function countDown(){
var time=seconds--;
time_txt.text=time;
if(time=0){
gotoAndStop("lose");
clearInterval(counter);
}
}
counter=setInterval(countDown, 1000);
can any one help
var seconds:Number=10;
time_txt.text="";
function countDown(){
var time=seconds--;
time_txt.text=time;
if(time=0){
gotoAndStop("lose");
clearInterval(counter);
}
}
counter=setInterval(countDown, 1000);
can any one help
