I want to move something a certain distance. However, there is inertia / resistance / negative acceleration in my system. I use a simple calculation for this:
v = oldV + ((targetV - oldV) * inertia)
Applying this to several frames, the movement "grows" or splits, for example:
v = 10 + ((0 - 10) * 0.25) = 7.5 // velocity changes from 10 to 7.5 this frame
So, I know the distance that I want to travel, and the acceleration, but not the initial speed, which will force me there. Perhaps the best explanation I want to know is how difficult it is to get into a billiard ball so that it stops at a certain point.
I look at the equations of motion ( http://en.wikipedia.org/wiki/Equations_of_motion ), but cannot decide which one is right for my problem ...
Any ideas? Thank. I am from design, not from science.
: Fiirhok ; - HTML + jQuery:
http://pastebin.com/ekDwCYvj
? , , , , .