Would it be possible to make the entire add draggable. So the user can take out out of the way if you wanted to.
I wouldn't recommend that use implement any flash add that is going to get in the way of content. At best it should appear and after a certain period go back to it's collapsed position.
In any case, if you want to do this...look into the startDrag() and stopDrag() methods.
How would I make it so that instead of appearing wright away, the back animates to expand.
For any kind of tweening (animation), I always use MC Tween or Tweener. It would be fairly easily to implement MC Tween in this instance.
For example, replace
Code:
ad.back._height = Stage.height;
with
Code:
back.resizeTo(back._width, Stage.height, .5, "easeOutQuad");
If you do that, you should get rid of the positioning on the text field. Unless you use it in conjunction with MC Tween's onTweenComplete method, it won't have the height of back until the animation completes (and you're calling it before the animation completes).
What font did you use for the text? I really like it.
It's called nevis. It's available here for free.
Can I use this on my website? Or is that against your license?
Yeah, sure. I just mean don't sell my code as yours. Thanks for asking though.
Bookmarks