Warning: file_get_contents(/data/phpspider/zhask/data//catemap/5/actionscript-3/7.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Actionscript 3 actionscript进程延迟?_Actionscript 3_Flash_Flash Cs5 - Fatal编程技术网

Actionscript 3 actionscript进程延迟?

Actionscript 3 actionscript进程延迟?,actionscript-3,flash,flash-cs5,Actionscript 3,Flash,Flash Cs5,我想知道我怎样才能让一个tween在执行之前多等几秒钟?我的代码如下: btn_1.addEventListener(MouseEvent.CLICK, about_navigate); function about_navigate(event:MouseEvent):void { topbarTween.yoyo(); //how to make the below tween wait 2 seconds before it i

我想知道我怎样才能让一个tween在执行之前多等几秒钟?我的代码如下:

  btn_1.addEventListener(MouseEvent.CLICK, about_navigate);

    function about_navigate(event:MouseEvent):void
        {
        topbarTween.yoyo();
        //how to make the below tween wait 2 seconds before it is carried out   
        btmTween.yoyo();
        }

我是AS3新手,因此非常感谢您的帮助

我不认为原生的
Tween
类有内置的延迟方法(就像大多数第三方解决方案一样-尽管如果我错了,请有人纠正我)

您可以使用
flash.utils.setTimeout
计时器

function about_navigate(event:MouseEvent):void
{
    topbarTween.yoyo();
    setTimeout(btmTween.yoyo,2000);
}

你在用土生土长的特温图书馆吗?或者像TweenLite/Tweener/Gtween这样的第三方软件?我正在使用本机库只是一个简单的问题:var myRotationTween:Tween=newTween(content_mc,“rotation”,Elastic.easeOut,content_mc.rotation,content_mc.rotation-90,3,true);设置超时(myRotationTween,500);