i runned debuger
(error shows sometimes, and sometimes not XD)
TypeError: Error #1009: Cannot access a property or method of a null object reference.
at test_fla::MainTimeline/countdown()[test_fla.MainTimeline::frame571:14]
at flash.utils::Timer/_timerDispatch()
at flash.utils::Timer/tick()
i must go on continue to continue play
debugger shows error
var count:Number = 60;
//2.
var myTimer:Timer = new Timer(1000,count);
//3.
myTimer.addEventListener(TimerEvent.TIMER, countdown);
//4.
myTimer.start();
//5.
function countdown(event:TimerEvent):void {
counter.text = String((count)-myTimer.currentCount);//<-------- HERE
if(counter.text == "0"){
gotoAndPlay(1);
}
}
Any help?! Thanks
Aleksandar