My favorites | Sign in
Project Home Downloads Wiki Issues
Search
for
BasicFlashCS3Example  
Instructions for use within Flash CS3
Featured, Phase-Implementation
Updated Aug 3, 2009 by spambuck...@gmail.com

Introduction

The scripting lib can be used within Flash CS3 by loading the special ESCompilerSWF provided in the download zip. Its document class is an instance of ICompiler.

Details

import com.newgonzo.scripting.ICompiler;
import com.newgonzo.scripting.events.CompilerEvent;
import com.newgonzo.scripting.utils.CompilerLoader;

var loader:CompilerLoader = new CompilerLoader();
loader.addEventListener(CompilerEvent.INIT, compilerInit);
loader.load("ESCompilerSWF.swf");

function compilerInit(event:CompilerEvent):void
{
  var compiler:ICompiler = event.compiler;
  
  compiler.compileAndLoad("trace('Hello World!');");
}

Sign in to add a comment
Powered by Google Project Hosting