PDA

View Full Version : [AS3] how to use packages in multiframe flash timeline


jlar
12-09-2008, 03:22 PM
Hi,

I am trying to work my way through a game design book using AS3 and Flash CS3. I have created a package with a class for the game in an .as file, and I have also created a .fla file of the game level, with all of the sprites and characters. I exported all of them for actionscript. But, I can't seem to figure out how to get the .fla file to recognize the .as file. When I click test movie, the level plays with no compile errors, but nothing happens.

Is there a way to use the import statement or something like that? I tried simply

import iceAttack;

where iceAttack.as is the name of the actionscript file thatis in the same folder as the iceAttack.fla file, but this did nothing.

Thanks,
jon

rrh
12-10-2008, 05:40 PM
You need to set the Document class, which should be on your properties panel for the document.