<s:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark"
xmlns:mx="library://ns.adobe.com/flex/mx"
addedToStage="application1_addedToStageHandler(event)" backgroundAlpha="0">
그리고 stats클래스의 경우에는 UIComponent에 실어서 application에 addElement하면 되고 Startling클래스의 경우는 바로 application.stage를 넘겨주면 된다.
protected function windowedapplication1_addedToStageHandler(event:Event):void
{
// TODO Auto-generated method stub
stats = new Stats();
var ui:UIComponent = new UIComponent();
ui.addChild(stats);
this.addElement(ui);
myStarling = new Starling(Game, stage);
myStarling.antiAliasing = 1;
myStarling.start();
}
No comments:
Post a Comment