# Why the background shrinks when my Car cross the STAGE?

**URL:** https://forum.kirupa.com/t/why-the-background-shrinks-when-my-car-cross-the-stage/329976
**Category:** flash
**Created:** [November 13, 2012, 6:52pm UTC](https://forum.kirupa.com/t/why-the-background-shrinks-when-my-car-cross-the-stage/329976 "2012-11-13T18:52:09Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![learner\_7n](https://avatars.discourse-cdn.com/v4/letter/l/b2d939/32.png) [@learner\_7n](https://forum.kirupa.com/u/learner_7n)
#### Post date: [November 13, 2012, 6:52pm UTC](https://forum.kirupa.com/t/why-the-background-shrinks-when-my-car-cross-the-stage/329976/1 "2012-11-13T18:52:09Z")

</div>

Hi,

I have the following code & one [COLOR=#ff0000]CAR [/COLOR]which moves from [COLOR=#0000ff]right to left[/COLOR]. When the CAR moves out of the stage, the background gets shrink. How to solve this problem?

The Code:

```auto
var myStage:Stage=this.stage;
myStage.scaleMode=StageScaleMode.NO_SCALE;
myStage.align=StageAlign.TOP_LEFT;

function initialDisplay(event:Event):void{
	var swfWidth:int=myStage.stageWidth;
	var swfHeight:int=myStage.stageHeight;
	
	Background.width=swfWidth;
	Background.height=swfHeight;
}

addEventListener(Event.ENTER_FRAME,initialDisplay);

```

Note: There is no other code except the above one. Car moves by Classic Tween.

The FLA file size is 6.26 MB. So I cannot attach it. But the jpg file illustrates my problem.

Thanks for any help.
