Hello,
my Flash project is beginning to get out of hand because there are too many .as files and I would like to organize them in folders. But I don’t know how I need to import them properly.
I put them in a folder called “levels”, in there is a Level.as and five specific files that extend the Level class, Ground0.as to Ground5.as.
I put the folder name levels as the package name, so for example the Level.as file begins as following
package levels{
import flash.display.*;
import flash.events.*;
public class Level extends MovieClip {
and in my Document Class (“MainClass”), I tried to import the folder “levels”
package {
import flash.display.*;
import flash.events.*;
import flash.utils.*;
import flash.ui.Keyboard;
import levels.*
public class MainClass extends MovieClip {
but calling the classes that are in the subdirectory “levels” simply doesn’t work. Do I need to do something else or call the classes in a different way?
Thank you.