AS3 Q

Out of context: Reply #17

  • Started
  • Last post
  • 19 Responses
  • kpl0

    var loader:Loader = new Loader();
loader.contentLoaderInfo.addEven... loadDone);
    
loader.load("swfWithNewClasses.s...

    function loadDone(e:Event):void {

    var loaderInfo:LoaderInfo = e.target as LoaderInfo;
    var NewClass:Class = loaderInfo.applicationDomain.get...

    var mc:MovieClip = new NewClass() as MovieClip;

    addChild(mc);

    }

    • bahkpl
    • haha... i put some extra spaces when I copy/paste...
      loaderinfo . applicationDomain . getDefinition ( "string" ) as Class
      PonyBoy
    • seems to paste it..
      ... and I think I get what you're saying - I'll give this a try too... thanks!
      PonyBoy
    • awesome. tell us if it works.kpl

View thread