I have a problem with accessing properties from different packages. I can't access any properties of the Assets class from the FloorTile Class. How do I get floorTileData from Assets?
Assets:
package src.gfx{
import flash.display.Bitmap;
import flash.display.BitmapData;
import flash.geom.Rectangle;
import flash.geom.Point;
public class Assets{
public var floorTileData:BitmapData = new BitmapData(0, 0);
//Other Code
}
}
FloorTile:
package src.tilespack{
import src.gfx.Assets;
public class FloorTile extends Tile{
public function FloorTile(ID:int){
super(Assets.floorTileData, ID); //Error in this line
}
}
}
The error is due to this line
super(Assets.floorTileData, ID);
I get the Error - 1119: Access of possibly undefined property floorTileData through a reference with static type Class.