double EaseCubicInOut(num t, num b, num c, num d) { if ((t/=d/2.0) < 1.0) { return (c/2.0*t*t*t + b); } t -= 2.0; return (c/2.0*(t*t*t + 2.0) + b); }