Jump to content
Search Community

How to solve the resizing problem?

learner_7n test
Moderator Tag

Recommended Posts

Hi,

 

I am resizing my .swf file according to browser size using AS3. It is working fine. But problem occurs only when an object goes x=-300 (x, or y but in negative numbers) on stage. Means when the object goes up the stage or down the stage, everything on stage shrinks and looks very bad.

 

How to overcome this problem?

 

Actually I am having problem only when my flash movie clips move out of flash stage area.

 

Say, my swf movie width & heights are 600x400 and my flash movie clip (MC-1) animation area is set to animate from x:-100 to y:650 or x:100 to y:-450.

 

Any help, please. I tried several forums to overcome thim problem but in vain.

 

Regards.

Example.zip

Link to comment
Share on other sites

yes, the problem is the position of the truck changes the width of the container.

 

assume:

your stageWidth is 400.

the width of the container is 400px

your truck is 200px wide.

 

 

if your truck has an x position of 400 inside the container, the width of the container will be 600px.

 

You have code that says shrink the container from 600px to 400px (the width of the stage)

 

check out this tutorial on scaleModes: http://active.tutsplus.com/tutorials/actionscript/quick-tip-stretch-your-swf-with-stage-scalemode/

 

if you google "flash fullscreen website tutorial" or similar you will probably find lots of info on scaleable websites.

 

I wish we could help more but things are very busy in GreenSock land with the launch of v12. We really have to focus on GreenSock-related issues in the forums.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...