0
votes

I have a flash application created in FlashDevelop (game.swf). It was created from usual template

package 
{
    import flash.display.Sprite;
    import flash.events.Event;

    public class Main extends Sprite 
    {
        public function Main():void 
        {
            if (stage) init();
            else addEventListener(Event.ADDED_TO_STAGE, init);

        }// end function

        private function init(e:Event = null):void 
        {
           //here I add some sprites Loaded with ImageLoader  greensock
           // for each sprite I set it position and size from code
        }// end function

    }// end class

}// end package

So after adding loaded sprites everything is right on debugging .But when I load game.swf from another parent swf application everything goes bad. All childs of Main sprite becomes very big. In my code I dont set width and height for Main sprite. Whats wrong wrong? Why everything doesnt remain as in debugger? Parent swf set stage display state FULL_SCREEN before loading game.swf. Looks like Main sprite stretches over container.

1

1 Answers

1
votes

Try setting these properties on both the host and child swf:

stage.scaleMode = StageScaleMode.NO_SCALE;
stage.align = StageAlign.TOP_LEFT;