IMPORTANT EDIT:
I have just realised that the follow path constraint does NOTHING AT ALL!
You can delete it, the curve modifier does all the work, (sorry for the confusion.)
Here is a file without the follow path constraint. THIS IS THE MOST CORRECT ONE (edited)
Cube3.blend (98.6 KB)
Sorry for the delay, I was working this weekend.
To do the animation you ONLY NEED 2 things.
1 A “curve modifier” to deform (curve) the cube along the curve. For the curve modifier to deform nicely I had to add some edge loops to the cube (you can see that if you look at the cube in edit mode.)
The curve modifier deforms the cube along its local x axis. (that is why the loop cuts look like they are in the wrong direction when you look at the cube in edit mode.) The modifier aligns the cube along the curve on its x axis.
To get the cube to move in the animation you have to key frame the x location of the cube. with the I key (you can choose just location)
2 the “shape keys”.
If you mute the shape keys (by clicking the arrows), you will see that the cube just goes along the curve and deforms but does not “stretch”.
The shape keys animate the stretching of the cube.
To key frame the shape keys value’s you have to hover your mouse over their value field’s and hit I.
If you mute all the shape keys and then turn them on one by one you will see what each one does.
Shape key 1 stretches the cube.
Shape key 2 squashes the cube at the beginning (from its top towards its bottom)
Shape key 3 squashes the cube at the end (from it bottom towards its top) This is necessary because when the cube is at the far end of the curve (where it lands) it is upside down.
Part of it is (the cubes movement) along the curve. By keyframing the x location of the cube.
Part not: the srtetching and shrinking, this is done by animating the shape keys values.
To recap you have to key-frame the cubes x location ( hit I choose location) to get the cube moving.
Then you key-frame the shape keys to stretch and shrink the cube, ( hover over the value field and hit I ).
Yes I duplicated the keyframes and mirrored them just for fun, sorry to confuse I w3anted it ito jump back
I hope all that helps.
If you can not work it out I recomend you search and watch 2 tutorials
One for the curve modifier and one for shape keys.
You will understand it all better once you understand these concepts.
Latest edit! Sorry to bump the thread again.
I deleted the follow path channel from the keyframes of the file aswell so as not to confuse.
Last edit (I hope)
I have now stripped the file to the minimum keyframes necessary, and deleted the rotation and scale key frames (they did not effect the animation).