Search  

AS3 FRAME LABELS

HomeForumsHelp NeededAS3 frame labels
Default-profile signalr32
18 posts
Bought between 10 and 49 items

Hey okay.. So say i have a movie with 3 mc buttons.. Lets say all the buttons load the same swf.. How do i get it to load the same swf but start out on different frame labels.. Say the file is test.swf and it loads test2.swf.. how do i get the buttons from test.swf to load test2.swf and have each button go to different frame labels located in test2.swf

THANKS

Posted about 1 month ago
65882 theflyingtinman
505 posts
Item was featured Referred at least one person Sold between 100 and 1 000 dollars

Of the top of my head (not tested) .. in your swf Loader Complete handler you want something like this :

function OnLoaded(e:Event)
{
    var ldrInfo:LoaderInfo = e.target as LoaderInfo;
    var swfObj: Object = ldrInfo.content;
    this.addChild(ldrInfo.content);
    swfObj.gotoAndPlay("label");
    ....
}

Posted about 1 month ago
Default-profile signalr32
18 posts
Bought between 10 and 49 items

going to give it a try.. but i dont have a load complete.. this is my load function that i have for the buttons.. the buttons are images that are being pulled via xml and the swf that it loads is placed in the xml file..

imagesArray[i].addEventListener(MouseEvent.CLICK, doSomething); function doSomething(event:MouseEvent):void { var swfURL:URLRequest = new URLRequest(thumbsXML.image[imagesArray.indexOf(event.target)].@url); }

swfLoader.load(swfURL);
swfCon.addChild(swfLoader);
Posted about 1 month ago
65882 theflyingtinman
505 posts
Item was featured Referred at least one person Sold between 100 and 1 000 dollars
going to give it a try.. but i dont have a load complete..

So just add one!

swfLoader.contentLoaderInfo.addEventListener(Event.COMPLETE, OnLoaded);

Posted about 1 month ago