The method looks like this:
var startButton:StartButton;
var logo:Title;
var restart:RestartButton;
public function EightyEightJazz() {
logo = new Title();
logo.x = stage.width/2;
logo.y = stage.height/5;
addChild(logo);
trace(stage.height + " " +stage.width);
startButton = new StartButton();
startButton.x = stage.width/2;
startButton.y = 300;
addChild(startButton);
startButton.addEventListener(MouseEvent.CLICK, function (e:MouseEvent){
jazz();
});
}
And all it's doing is putting everything on the screen, and waiting for the user to use the start button before it calls the main game method.
For some reason though, my stage dimensions are the dimensions of my Title symbol. The window stays the same size, but if I trace(stage.width + " " + stage.height), or try to use the width and height to set the positions of my objects, then it gets all wonky.
The strangest thing though, is that as soon as it gets into the jazz() method, the stage gets fixed again.
This is the first flash thing I've ever done, so I've only been able to try a few things, but setting focus to the stage didn't help, and I can't seem to figure out why it's doing this.
Any help would be fantastic, and thanks for taking the time to read this.

New Topic/Question
Reply



MultiQuote




|