I would like to delay the button click event to trigger for 10 seconds after I press the button. The following is the Actionscript3 code I am using now. I want to delay the GLButton mouse click event.
stop();
import com.greensock.;
import com.greensock.easing.;
import com.greensock.plugins.*;
import com.greensock.events.LoaderEvent;
import com.greensock.loading.ImageLoader;
import com.greensock.loading.LoaderMax;
import com.greensock.loading.SWFLoader;
import com.greensock.loading.VideoLoader;
import com.greensock.loading.display.ContentDisplay;
import flash.display.MovieClip;
import fl.transitions.Tween;
import fl.transitions.TweenEvent;
import fl.transitions.easing.*;
Messages.GLButton.addEventListener(MouseEvent.CLICK, btnClick);
function btnClick(event:MouseEvent):void {
var X1pos:Number = 0;
var Y1pos:Number = 0;
var SWF1:MovieClip;
var loader1:Loader = new Loader();
var currentSWF:String = “FireWorks.swf”;
var newSWFRequest:URLRequest = new URLRequest(currentSWF);
loader1.load(newSWFRequest);
loader1.x = X1pos;
loader1.y = Y1pos;
SWFContainer.addChild(loader1);
loader1.mask = SWFContainer.MaskArea
}