|
Special notice! While MC Tween is a nice extension and it will continue to work for AS1 and AS2 until the end of time, it is my duty to inform all citizens that I have switched the focus from further development on MC Tween to a new AS2 and AS3 extension, a real Class this time, called "caurina.transitions.Tweener" (or just Tweener). Tweener doesn't have as many features as MC Tween yet (for example, it doesn't have native filter tweens), and the documentation isn't 100% done, but it features a complete, more solid redesign with a few additional syntax features that were impossible to achieve with MC Tween. And it works the same for AS2 (including Flash Lite 2+) and AS3.
So, if you use MC Tween, or you're thinking about using it, I'd like to suggest you try Tweener instead. It follows all the principles of simplicity I tried to feature on MC Tween, but with a more powerful syntax. Tweener download, examples and documentation are available on Tweener's page. You can read more about this change on this blog post.
Thank you for your attention and sorry for this ugly box. And don't worry, this website will not be deleted or anything.
Notice for October 2008: also note that, if you are still interested in MC Tween and don't want to use class-based AS2 or AS3 solutions, Larry Benedict has taken the matter into his hands and updated MC Tween with some filter features that are not available in the latest version. You can read more about it (and download his version) here or here.
Author & Disclaimer
MC Tween was created and is maintained by me - Zeh Fernando. I live at São Paulo, Brazil. I can be reached at the email address z[AT]zeh.com.br.
I created these prototypes on April 5th, 2003. I remember that, shortly after visiting proto.layer51.com, I thought to myself "Hey, there's a cool collection of prototypes and functions available here, probably somebody has already built a movieclip sliding prototype that uses Robert Penner's equations!". However, as I browsed the site, I found out that all movieclip sliding prototypes were actually very awkward to use (requiring you to create onEnterFrame blocks) or too complicated (requiring several lines of code for one simple tween). That's when I, taking a cue from Jonas Galvez's simpleTween method, decided to create a new tweening prototype to control movieclip sliding... and some other stuff. The kind of work I was doing at the time really called for an easier sliding and fading prototype, and while I was using some of the famous "divide the remaining value by 2" easing calculations on simple fading and sliding prototypes, I needed something a bit more powerful - with time and animation control.
So I started MC Tween at home, first as an experimental project, then started using it at work as a beta test, just for myself. It quickly spread to all Flash movies we create at my work place, and then I started adding more and more features until we dropped all other sliding or fading prototypes in favor of MC Tween. That's also when the name was coined - we used to call all our #include files with the name of the class name plus the function name, and that's how "mc_tween.as" was born. The name just stuck since it has no real name. I've also sent it to proto.layer51.com itself, on this page (still a valuable resource for discussion about it). It quickly become the most visited prototype on the site.
I ended up using MC Tween on all my Flash movies, and personally, I can barely think on how I could work without it. My work flow is much more straightforward now - while I don't usually create intros, I create animation rich websites, so all our buttons and sections and movieclips have transition effects - and I can concentrate on getting the job done instead of recreating handlers to control menu or button animations. I may be biased since I created a tweening engine, but I really think that starting using tweening prototypes on my Flash work has been the biggest step I've ever made on my interface development career. If you have never used such engines, and you created rich Flash websites, I urge you to try some tweening extension as soon as possible - your productivity will more than double. Be it MC Tween, be it one of the other great tweening extensions now available, you'll be doing yourself a favor by trying.
Nowadays, while it's pretty much feature complete, I'm still updating MC Tween every once in a while, adding features and solving issues; there are still plenty of mini-features I plan to add to it.
Acknowledgements
Of course, MC Tween would not have been possible without Robert Penner. He's the god of mathematical equations on Flash; he created all easing equations used on my prototype. All the equations - the animation types, in practical words - were created by him long before I created MC Tween. Here's the disclaimer from his equations' license (also available here):
TERMS OF USE - EASING EQUATIONS
Open source under the BSD License.
Copyright © 2001 Robert Penner
All rights reserved.
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
Robert Penner also created the pointOnCurve equation I use on the _global.findPointOnCurve() function -- it's used to find a point on a curve when using the bezierSlideTo() shortcut method.
Boring disclaimer
MC Tween was created and is maintained by Zeh Fernando with code from Robert Penner (used with permission). It is not for commercial distribution or reproduction. Anyone can use it freely on their own work, be it open-source, free, or commercial work. While I do not enforce it, I do ask for credit where credit's due - use common sense and don't be a leech. Comments, suggestions, questions and bug reports are welcomed.