|
|||||||
| Tutorials:flash:tweening | ||||
|
Table of Contents The Complete Tweening Tutorial1. What is tweening?A tween is a computer-generated transition between two keyframes. In simpler words, it’s Flash moving an object from point A to point B in a given set of frames, as opposed to you moving the object every frame manually.
2. Should I use tweens or frame-by-frame (fbf)?It really all depends on your style. However, each technique has its pro’s and con’s. Tweening is simple, quick and usually smooth without much trouble, but it has less control and is often less realistic looking than fbf. Fbf movies tend to have bigger file sizes, but are less laggy in most instances. Also, having a tablet usually helps a bucket load if you’re gonna go with fbf. A tablet is basically an actual drawing pad that transfers strokes into mouse movements on your compy, so what you draw on the tablet is drawn on the screen. This helps fbf a lot, for obvious reasons. The fact that I don’t have one of these is a major factor in my decision to not use fbf often. In the end, whichever technique you go with should include a little of the other technique. On complex movements, you’re gonna want to throw some fbf into your tweened movies, and in fbf movies, you’re going to want to tween where you just want a simple, straight, clean movement.
3. How do I make a tween?
Before I go into that, you need to know a few rules when it comes to tweens.
Okay, with that out of the way, let’s move on to actual tweening.
In addition to position, motion tweens can change instance properties (tint, transparency, etc.), scaling, skewing, rotating, and filters (in Flash 8). You can alter these properties with the Transform tool and the Properties panel (well, those are for Flash MX and above – Flash 5 and below use Right-Click>Transform>Scale (or rotate or whatever) for transforming and the Instance panel for the properties changing).
4. What’s the deal with shape tweens?Shape tweens are a little weird, to be frank. They can act abnormally for no reason, and they have to be used very precisely for good results. Basically, a shape tween is a motion tween that deals with raw fills and lines – it tweens things that aren’t symbols, and the starting and ending shapes can be different, because it generates a transition between them based on edge similarities and bends. In complex objects, they usually screw up and look ugly. However, if you’re doing something like animating a blob, or possibly a mask (see Advanced Techniques), you’re going to be shape tweening (your shapes are simple, and their actual form will be changing a lot, so it’s usually good to use shape tweens there when you can). Shape tweens are made the same way as motion tweens, but they don’t have any of motion tweening’s rules (however, your starting and ending objects should be very similar if you want it to look any good). They do no animate symbols, and there can be any number of bodies of fill or lines, technically.
5. What advanced techniques are there?There’re three main ones: guides, masks, and easing. Guides and masks are technically universal layer properties, but they go hand-in-hand with tweening.
Guides
A guide involves at least two layers. One layer is the path, and the rest are the layers that follow the path. [If you’re good with logic and observing, the uploaded source file (.fla) below should be enough to give you the gist of everything.] The top guide layer should consist of an un-intersected line formation (can by multiple lines attached to one another). The layers underneath the guide layer that are affected by it will follow the line formation if their start and end positions lie on points on the guide (affected layers are tabbed). For example, if your guide layer was an “S” shape, and you made a ball in the layer affected by it and made the ball start on the top of the S and tween to the bottom, it would follow the S-shape when moving. A bit funky, you might want to experiment with it a bit.
Masks
Masking really isn’t too bad. It’s applied to layer like a guide – the top Mask layer affects all layers designated below it. The mask’s effect, however, is totally different.
Easing
Easing is the easiest of the three to utilize, but it takes some practice to master. Easing lets you choose the speed at which your object is changing during a tween. Normally, you choose between –100 and +100 (you can change it in the Properties panel or the Frame panel {p5.1}). –100 makes your tween start pretty much still, and then accelerate. +100 starts your tween off quickly and slows it down to a stop. In many instances, one will make a normal tween, then put a keyframe in the middle to divide it up into two tweens, and apply –100 to the first one and +100 to the second {p5.2}. This allows for one solid movement that eases its way into starting and stopping. I use easing in almost every tween I use, and pretty much any tween-based animator should too.
If you want an example of all these techniques being used, you should see my clock day movie. It utilizes pretty much everything said in here (for guide and mask, look at clear up close and watch her tears). You can find it here:
6. Any tips?
Yeah, there’re a few things to keep in mind: |