Papervision 3D Programming Tutorial: Tweener
How often do you want to move an object by some predefined amount over a certain period of time? Like “move to this point in 2 seconds”. This sort of movement over a timescale is the cornerstone of animation and scripting. Unfortunately to implement this in code is quite tedious. You first need to work out how fast you should be moving, and then keep track of how long you have actually moved. It’s not hard, but it does require writing a lot of boring code.
Fortunately there is a very elegant solution for this sort of animation. The Tweener library allows you to modify the properties of an object over a certain period of time with one or two lines of code. Learn how to use this technique in this tutorial. Demo and source code are attached as always.