function Interpolate.Linear(f,V,X)X=math.clamp(X,0,1)return(1-X)*f+X*V end function Interpolate.QuadInOut(f)return f<.5 and(2*f)*f or 1-math.pow(-2*f+2,2)/2 end function Interpolate.Bezier(f,V,X,n)return((1-n)^2*f+((2*(1-n))*n)*V)+n^2*X end return Interpolate
-- @Description Basic linear interpolation
-- @Arg1 Time
-- @Arg2 StartingValue
-- @Arg3 EndingValue
function Interpolate.Linear(p0, p1, t)
	t = math.clamp(t, 0, 1)
	return (1 - t) * p0 + t * p1
end

function Interpolate.QuadInOut(t)
	return t < 0.5 and 2 * t * t or 1 - math.pow(-2 * t + 2, 2) / 2
end

function Interpolate.Bezier(p0, p1, p2, t)
	return (1 - t) ^ 2 * p0 + 2 * (1 - t) * t * p1 + t ^ 2 * p2
end

return Interpolate
