FDT and ANT – part 1

Just started to work with FDT and wrote about my “troubles” (post#1 and post#2) with my transition from FlashDevelop.
(have to be very carefull what I say: “they” are watching me: here and here 😀 )

And it seems to be a very natural (geeky) thing to learn about ANT.

And where do you go to learn about ANT and SWF/Flash/FDT? (Google?)
After some tinkering all I got was: failed to create task or type fdt.launch.application

This post was very useful: FDT and ANT | A Users Guide Part I by Alan Klement.
Watch the videos (I’m not very fond of tutorial videos but in this case; they get the job done).
What I love about the “Video I: Getting Started” is the fact that it builds up from scratch. So watch this video when you want to know about ant-files/xml, how to open the ANT-View, how to open/execute an ANT-file.

The second video (Video II: Compiling a SWF) was what I really was looking for: how to export a SWF. Very nice because it starts from scratch.
And it gave me the answer I was looking for: why didn’t my ANT-file didn’t work (it about 3/4 of the video):

BUILD FAILED
[blabla]\source\a\example\build\build.xml:17: Problem: failed to create task or type fdt.launch.application
Cause: The name is undefined.
Action: Check the spelling.
Action: Check that any custom tasks/types have been declared.
Action: Check that any / declarations have taken place.

Solution is very simple, but if you don’t know, you will hate FDT and really it’s not it fault:
Goto the green “play” button with the brown bag, in the toolbar (one picture says more than a thousand words:)

Select the ANT-file you want to change (I have only one :D), goto to tab “JRE” and change the Runtime JRE to Run in the same JRE as the workspace and your done:

Very useful are the ANT-snippets and ANT-Build-template!
Download (created by Alan Klement) and “install” the ANT-template (how-to on this page but here the short version)

To add XML files templates go: Preferences > XML > XML Files > Editor > Templates and click import.

To add Ant snippets go: Preferences > Ant > Editor > Templates and click import.

I haven’t seen the second part of this tutorial: FDT and ANT | A Users Guide Part II but I will.
It seems to be focused on the use of the templates and snippets.

source:
FDT and ANT | A Users Guide Part I
FDT and ANT | A Users Guide Part II

    One thought on “FDT and ANT – part 1

    1. ANT is an ugly-ass dragon but it sure as hell can spit fire. 🙂 I use it for compiling/opening multiple swf/swc files. I also love using ANT to make my own SWFObject-templates. It’s a master in removing/adding directories and files and also replacing vars in your template-files (and opening them afterwards). If you’re getting handy with ANT you can easily build a whole deploy-system (including ftp-deployment) with a single press of a button.
      It can be a very powerful language…. it’s just fugly as a hairy butt! (making loops is so completely non-logical, it makes you want to pull out your hair sometimes). You can also use ANT for instance to read svn-metadata and put it inside .as files (or externally loaded xml-files as you wish)… you can then read them out in a published/staging website… handy if you want to know if the client is looking at the same version as you do. For this to work you do need SVNant (http://subclipse.tigris.org/svnant/svn.html). A tutorial about the basics of this stuff can be found here: http://richardleggett.co.uk/blog/index.php/2006/10/19/svn_revision_using_ant_in_swf. Hope this gives you a nudge in the right direction. Good luck dude… and may the power of the paper-folding/gluiing-gods be with you! 😉

    Comments are closed.