Jump to content
Search Community

LiquidStage and Animating

needlemouse test
Moderator Tag

Recommended Posts

Hello Guys!

 

I was messing around with liquid stage and i noticed one thing.

 

LiquidStage works fine on non animated display objects, BUT, if i try to animate lets say the y coordinates of the display object, the PIN POINT is not being interpreted properly.

 

Basically, if i let it animate without suddenly resizing the browser, it works really well, no errors or anything. BUT, if i try to suddenly resize the window while its animating, the position of the display object changes and it is pinned on a different location.

 

here's my code: (It works fine if i didnt suddenly resize the browser while the object is animating, but it messes up if i try to suddenly resize my browser while its animating.)

 

Also want to mention that its pretty clear to me why this is happening. Its because of the stage dimension was changed when the animation happened.

 

content_container.alpha = 0;
content_container.y = stage.stageHeight - content_container.height

ls = new LiquidStage(this.stage, 1000, 665, 1000, 665);
ls.attach(content_container, ls.BOTTOM_LEFT);

//Animation.
TweenMax.to(content_container, 0.5, {alpha:1, y:stage.stageHeight - content_container.orig_height - 50});

 

Any help to counter this issue is so much appreciated!!! :D

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...