闪光灯定时延迟

时间:2016-02-11 21:28:55

标签: actionscript-3 flash timer

// AS3
var myTimer:Timer = new Timer(1000);                  // 1 second
myTimer.addEventListener(TimerEvent.TIMER, runMany);
myTimer.start();

function runMany(event:TimerEvent):void {
trace("runMany() called @ " + getTimer() + " ms");
}

预期产出:

runMany() called @ 1000 ms

生成输出:

runMany() called @ 12823 ms
runMany() called @ 25603 ms
runMany() called @ 38404 ms

这是由于一些软件问题吗? I copied this easy code from Adobe Site但它无效。

on left AS3 code is written and in Output box undesired output is given

1 个答案:

答案 0 :(得分:0)

相同的代码在Flash CS6 actionscript 3.0中工作(在CS4中给出了意外的O / P)所以我认为问题可能是软件问题。它说会安装一些功能无法正确安装我忽略它.......无论如何谢谢所有。