22 / Scroll behaviour
Kinetic Drag
Grab it and throw it. It keeps going after you let go, then slows to a stop as though it had weight.
also called drag-to-scroll · inertial scrolling · momentum decay
Everything lives in the decay constant. 0.90 stops abruptly and feels cheap; 0.98 slides forever and feels broken. Around 0.94 is where it starts feeling like an object with mass.
How it is built
v *= 0.94; /* per frame */
if (Math.abs(v) < 0.1) stop();grab and throw