
Ever wonder how I made this animation (or any of these)? You'll learn how in this tutorial, including a detailed behind-the-scenes look.
How do you make animations that behave in a realistic way?
Last updated: Apr 9, 2006 (first version)
Level 1 update on Jun 10, 2007 (a few very minor changes)
This section covers planning - forming the base plan, main plan, and detailed plan as well as how to set up the spreadsheet.
1 The base plan
Before doing anything, I need an idea on what to even do. This is the base plan. Whether it's running up a mountain, gliding across town, jumping out of a rocket going 550 mph and landing coming to a stop, or just swimming in a lake, before I even start the first phase of making an animation, I need to decide what the animation should be of first. In our tutorial, we'll make an animation where I'm float-running along normally, run into a obstacle tossing me high up, use the flash attack straight up to amplify the height, then splash into a lake from the resulting long fall. This may seem like a lot, but there actually isn't much to it. This is our base plan.
2 The main plan
We now need a more detailed plan than the base plan. This is the main plan. The main plan for our tutorial will involve some kind of object to toss me up. This, in my mind game, is often caused by a large rock about 2 feet high with abrupt angle changes. We'll use a 45° angle since they're simple to use. We'll have 2 to 5 seconds of normal float-running at 200 mph then hit this object. Remember, it's easier to subtract, but not add so always overestimate (and not rediculously). We'll launch at a diagonal (the same angle as the slope) going 140 mph in both directions. After a reaction time's worth (3 frames for 0.3 seconds), the flash attack is used to go straight up while I gradually decelerate horizontally to a complete stop. I then splash into a lake near 240 mph going in as deep so the waves are from 16 to 32 pixels from the image top. The animation will end here. This seems like a lot, but it should only take a few hours to process. Layers come in very handy for this.
As to the scenery, we'll have some mountains (one of my favorite things) and at least 2 fog layers. The fog color will be 4060FF (or ######), a light bluish-gray color. The grass will be 40C000 a medium yellow-green color (######). The lake will be 2060E0 (######). The sky will be 4080FF (######).
Next, we need to figure out how the scenery is arranged. For determining distance, a concept called scaling is used. Scaling affects the size and distance of an object. If you double the scaling value, the object will be twice as far but twice as big. How far the objects are depends on how you think of it. In most cases, 1 scaling unit as 30 feet distance is a decent standard (which approximates about that of a typical camera). There will be two layers of mountains, a close layer and a far layer. The edge of the first fog layer will have a scaling of 100. The edge of the second fog layer will have a scaling of 200, the third at 300, and the fourth, which is to the edge of the mountains, will have a scaling of 400. The closest mountains will have 400 and the furthest mountains will have 500. The visibility will be 600. This puts visibility, given the standard, at 18000 feet, or about 3.4 miles (5.5 kilometers). The lake will have a scaling of 20 and not be affected by the fog. We'll also have a speed indicator on the bottom right corner and nothing else. Finally, our animation will be 320x240 resolution, a typical size I use.
3 The detailed plan
From here on, to view a full-size screenshot (1600x1200), just click on the scaled down version of the image. The screenshot will open in a new window so you can more easily switch between this page and the screenshot to learn how things are explained.
3.1 Setting up the basic spreadsheet layout
Now that we know what's going to happen in our animation to more detail, we need an extremely detailed plan, the detailed plan. For this, we'll use a spreadsheet document. How the spreadsheet is set up is usually quite consistant.
In cell A1, I type the title of the animation, "The unexpected obstacle" always with "math notes" following it. To the right of this in the first empty cell where the previous text doesn't occupy it, I put my base plan in here. In the cells below, in row 3, I mark the basic layer names from furthest to closest (sometimes I do it the other way around). I have it as mountains 1 and 2 for each the X and Y positions. Then I have the fog 1 through 3 layers, and finally the lake. The fog layers are all the same horizontally so I can leave those as is and only have the Y value. The same goes for the lake. Below that, I have 500, 500, 400, 400, 300, 200, 100, and 20. In cell I4, I have "frame" to indicate the frame number. In cell J4, I have "speed" to indicate the raw speed, the combined speed of the X and Y speeds. In K4, I have "X SPD" to denote the X speed (horizontal). L4 has "Y SPD" for the Y speed (vertical). M4 has "X POS" and N4 has "Y POS" to denote the X and Y positions. Cell O4 has "notes/actions" to remind me what's happening. I also make the frame column bold and centered as it's very important as it helps determine what file name to save as. Also, I normally widen the notes/actions column and narrow the frame column to make them stick out better. At the moment, we have this:

3.2 Basic layout finishing touches
This is the very basic layout. However, we'll have the first few frames give the title and credits. First, we should set up the rest of the spreadsheet. On the first frame, speed is always zero. The position will be 0 and 20 for the X and Y values. Why 20? To "raise" the "camera" to the height of the character's eye to get a human-eye view. We can later change it. Here's what we do:
- In a cell off the side (such as P4 in my case), have "scaling values" in it.
- In the cells below it (P5) and the 5 to the right, enter the scaling values 500, 400, 300, 200, 100, and 20. There is no need to duplicate the 500 and 400 from the mountains.
- In the cells below this (P6), type "=" then point to the cell directly above.
- Select all cells on the same row (P6 to U6 in my case) below the other numbers in this area then press control+R (or use the edit menu or whatever to fill to the right).
Why do this you may ask? If you want to fine-tune the scaling, it'll be easier to do, especially once you've processed the final plan in full. If 400 for the scaling seems too low or too high, you can change it by changing all other cells simply by changing one single cell. That is pure speed and power! That's why this is important.
Next is setting up the rather short formulas:
- In cell J5, below the speed column, type "=(K5^2+L5^2)^0.5" without the quotes. This is the Pythagorean Theorum. This formula will need adjustments later on, especially when the acceleration is involved but we'll get to that later.
- In cells A5 and C5, type a zero.
- In cell B5, type "=N5/P5+120" without the quotes. Note how this references the position and the scaling off the side? The +120 at the end will be explained later.
- In cell D5, type "=N5/Q5+120" without the quotes. Note how the two formulas are the same in design?
- Repeat step 4 for the other cells to the right related to the background scenery.
- In cell A6, type "=M6/P6" without the quotes. Note the similarity between the X and Y formulas of the same thing. There's no +120 or anything at the end. This, too, is explained later.
- Repeat the same process for cell C6.
- Select cells B5 and B6 and press control+D to fill down (or use the edit menu or the equivelent function).
- Do the same for columns D through H as you did with B5 and B6 (you can do all 5 at once - just start the selection at D5 and go to H6 to make a multi-cell selection).
- In cell I6, type "=I5+1" without the quotes. This adds 1 to the frame count for each row.
- Repeat step 8 for cells J5 and J6 as well as for K5 and K6.
- Since a bulk of the animation involved vertical acceleration, we'll do L5 and L6 differently. For these, type "=L5-2" without the quotes as usual. The -2 is explained later.
- Cells M6 and N6 are done the same way. M6 has "=M5+K6" and N6 has "=N5+L6". This adds the speed to the current position to get the new position.
- Finally, for the last step, select cells A6 through U6 and select the cells below to make a big selection. Go down not just one row, but several dozen rows (300 rows should be sufficient for this animation). Press control+D to fill down (or use the edit menu).
The spreadsheet is now set up. All we need to do now is make a few minor adjustments to fit the final plan, all you do is change the speed as needed and take the notes as well. Before these changes are made, you have this:

As to what the +120 is doing at the end, it helps set the horizon. Since we're doing 320x240 for the animation, the horizon, for the most realistic effects, is half way down from the top and half of 240 is 120. When it comes to moving the layers, the top part of the ground gets moved and this is why it's there. The horizontal does not have this so it can start at zero and adding zero doesn't change anything so it's left out for the X positions. The -2 at the end is the speed change. At 20 mph per second downward acceleration, you gain 2 mph downward in one frame, and a frame is normally 1/10 of a second. Note the relationships between the vertical speed, the position, and scenery Y positions. Also note the relationship with the scenery Y positions and the scaling and how it affects it. Just to get this far normally with the spreadsheet, I'd be 10 to 15 minutes into this, mainly depending on how many layers I have and the complexity of the animation. The last bit takes about that same amount of time (an hour for 3000 frames' worth).
3.3 Finalizing the spreadsheet
The finalization also doesn't take much time either. All you need to do is change the speed a few times and take notes. However, first are the title and credits which use two text objects. We'll do these first before anything else. The title is obvious "The Unexpected Obstacle". In the notes/actions column, I put "text40: "The Unexpected Obstacle";" in there. The 40 means 40 frames or 4 seconds. This value is determined by the syllable count. I count 8 syllables. I add 5 frames for each syllable. That last sentence, if added, would have 45 instead due to 9 syllables. It takes me two seconds to say it (20 frames) and about 2 1/2 seconds to read it (25 frames). This leaves 1 1/2 seconds to spare. The 5-frame method goes to important things (like the title or credits). I use 4-frames instead for less important things like character speech (which would make the 40 become a 32 and the 45 become a 36). 1-frame is used for statistical displays (like the speed and height indicators) as they are updated every frame. I do use 3 and 6, but they are very rarely seen.
For the credits, I'll have "text70: "By ulillillia, created with GIMP and Excel";". I counted 14 syllables in this case and thus the 70. These are my only two planned text objects. For best compression and visibility, I place text objects on an all-black background then start the animation afterwards. Instead of frame 2, it's actually 41 given the text object delay of 40. Instead of where frame 3 was (or 42), it's 111. I manually type these in (often just doing the math in my head as it's often faster that way). Frame 111 means that I'm 11.1 seconds into the animation already. To check the time delays, I use a clock and my mind game to simulate it, usually at 2X time in my mind game. The first frame's speeds of the main animation are always zero. This logs the original frame details. From there, it changes as needed. After adding the text objects and modifying the frame count, this is what I have:

Here's what we need to do next:
- Change the Y speed to 0 to frame 111. The first frame of the actual animation must always be zero. It changes after the first frame (unless you want a pause effect).
- The plan is to float run for 5 seconds. This covers frames 111 to 160. The Y speed should be zero for all these (you aren't moving vertically yet). The X speed should be at 200.
- Fill down these new values to frame 160 (not row 160). Frame 160 should have an X speed of 200 and a Y speed of 0 at this point.
- A note is added saying that the obstacle appears. I have it as "obstacle appears on far left". (Screenshot available)
- Due to the low scaling of the character and the high speed, the obstacle disappears right away. I add this to my notes. Horizontal speed is now 140 and the vertical speed is now 141. Because acceleration is now involved, I modify the speed formula to have "(L57-1)" instead of just "L57". This is explained a little later.
- For 2 more frames, the horizontal speed stays at 140 and the vertical speed goes down by two. Be sure you update the speed column (select the entire column down and just use fill down).
- This is the time the flash attack is used. Add 100 to the Y speed and add the note. The horizontal speed remains the same.
- After another frame, the horizontal speed changes to 139.5 with the vertical left going as is. The speed column needs yet another change. Instead of just "K62", I now use "(K62-0.5)". This is explained a little later.
- Now have it so that the horizontal speed decreases by 1 every frame (using "=K62-1" and filling that down to the bottom). Why subtract 1 instead of 0.5? This is explained a little later. (Screenshot available)
- No change occurs for quite a while. It's clear until frame 282 that something new occurs - the start of falling. Only a note is needed there.
- On frame 306 when the horizontal goes below 0, set the -0.5 to 0 and fill the zeros down to the bottom. This requires another change to the speed column - leaving the "K202" all by itself getting rid of the parentheses you added earlier (though not needed, but the -0.5 does need to get deleted). This leaves "=(K202^2+(L202-1)^2)^0.5" remaining.
- Then again, nothing goes on until frame 401 that notes are needed. The special thing about this frame is that the character is now below where he started on the vertical - splash!
- Before I can know the last adjustment value, I need to make the scenery so I'll just leave it as is. The speed, because you've now landed, is at zero. The formula now becomes "=(K298^2+L298^2)^0.5" instead, the same style as the original one. (Screenshot available)
All this would normally take me about 10 minutes for this particular animation so I'd be 25 minutes in under normal circumstances. It doesn't seem like it given my computer clock, but it takes a lot more time to type all this than it does to do that. Here are the three screenshots showing progress along the way (for those tagged with "screenshot available" and in the order of occurrance):



The reason for having the "-1" added to the formula is for the adjustment at the end of the frame. It may seem like "-2" should be used instead, the reason is with the distance-acceleration formula. The speed displayed is based on the real speed at the end of the frame. The same thing also applies to the change of 0.5 then 1's. Before, at the 140, the speed was constant so it didn't need that adjustment. A short while later, the deceleration begins. The average speed from 139 to 140 is 139.5. The average speed from 138 to 139 is 138.5 and that's where that comes from. The horizontal deceleration in my mind game is 10 mph per second which is why is decreases by 1 instead of 2. To simplify the formula adjustments, having something hidden off the side that can get adjusted can be used.
The next thing to do is to create the scenery used.
3.2.3 Animation creation tutorial - how I make my flash-like animated GIFs to the finest detail
3.2.3.1 Introduction - The indroduction and tools needed
3.2.3.1-1 Introduction
3.2.3.1-2 Tools used
3.2.3.2 History - The history of my animation creation
3.2.3.2-1 The AVI days
3.2.3.2-2 MSPaint and early animated GIFs
3.2.3.2-3 GIMP and my latest animations
3.2.3.2-4 Automation leads to extreme complexity
3.2.3.2-5 Discoveries made along the way
3.2.3.2-6 The future
3.2.3.3 Glossary of terms and common formulas - Common animation-related terms and common formulas involved with art
3.2.3.3-1 Glossary
3.2.3.3-2 Commonly used formulas
3.2.3.4 Planning - Forming the plan - what the animation will do and how to set up the spreadsheet
3.2.3.4-1 The base plan
3.2.3.4-2 The main plan
3.2.3.4-3 The detailed plan
3.2.3.5 Creating the scenery - Making the scenery - how to optimize it and work with it
3.2.3.5-1 Some important notes
3.2.3.5-2 The easy stuff
3.2.3.5-3 The mountains
3.2.3.5-4 Making the character
3.2.3.5-5 Adding the obstacle and speed data
3.2.3.6 Animating - Processing the frames - using the spreadsheet data to make the frames of the animation
3.2.3.6-1 Important notes
3.2.3.6-2 Doing the text objects
3.2.3.6-3 The first scenery frames
3.2.3.6-4 Further scenery frames
3.2.3.7 Testing - Testing the animation - how to test the animation to spot problems
3.2.3.7-1 Compiling the animation
3.2.3.7-2 Testing the animation
3.2.3.8 Tips and tricks - Tips, tricks, and shortcuts to make animation-creation easier and faster
3.2.3.9 FAQ - Some commonly asked questions and help to common problems
Footnotes:
None.