Hi all,
I am trying to make a class that makes a tiled background but i cant make it to work.
Here is the code:
import flash.display.BitmapData;
class StageMaker {
var pattern = "pattern";
function StageMaker() {
this.fillBG(pattern);
}
function fillBG(tile) {
this.beginBitmapFill(tile);
this.lineTo(Stage.width, 0);
this.lineTo(Stage.width, Stage.height);
this.lineTo(0, Stage.height);
this.lineTo(0, 0);
this.endFill();
}
}