FlashDevelop 2.0 RC2 Impressions

FlashDevelop 2.0 RC2 Impressions

I’m playing with FlashDevelop since reading about it on Keith Peter’s blog. It is as he says: stable, slick, and with great features like usable code completion, code folding editor, integrated class explorer (yay!) and lots more I haven’t yet touched. It’s sweet!

I was stuck figuring out the best way to include an external SWF filled with media assets into the build process. Basically, I wanted to generate the following MTASC-equivalent command line:

mtasc main.as -cp classpaths -swf assets.swf -out mymovie.swf -main

What this does is tell MTASC to compile main.as (which then compiles everything else included in it), using the classpaths specified. The -swf switch is the one that will import the media assets, but instead of “injecting” the compiled AS2 into it, I’m specifying a different output file with the -out switch. The last switch tells MTASC to start program execution in the static function main().

There are two ways to specify build parameters in FlashDevelop:

  • Edit the Project Settings to set the header parameters and output file, but I haven’t figured out how to add the -swf assets.swf line. I don’t think you can do this in RC2, though this is ideal because I can compile ‘n run by just hitting F5. Instead of invoking MTASC directly, this executes FDBuild.

  • Alternatively, I can use the MTASC Quick Build feature, in which you add your additional parameters in a special comment in the source file. The problem with this approach is that QuickBuild applies only to the currently-viewed file, so you have to switch back to your main.as file before you compile. Blah!

<

p>Just when I was about to give up and switch back to the Flash IDE, I read here that you can actually add SWFs to the compile chain by right-clicking them in the Project Explorer and selecting add to the library. That’s a much more IDE-ish way of doing things, so I’m happy now. The documentation isn’t entirely clear on this; fortunately I stumbled upon this thread.

2 Comments

  1. Philippe 18 years ago

    Admitedly, the project manager’s many features are not documented in a comprehensive way… So FYI, when you “add to the library” some assets (SWF, JPEG, PNG, TTF), they are actually embedded into a new SWF using SWFMILL. Then your application code is injected into this SWF using MTASC.

    Please note that the “code injection” workflow (injecting code into some SWF created in the Flash IDE) will be supported as expected in the next release of FlashDevelop.

    ——-

  2. Dave Seah 18 years ago

    Thanks for the info, Philippe! Looking forward to the next release.