Stop reinventing lerp() all over the place.

This commit is contained in:
Mari the Deer 2022-05-29 18:07:30 +02:00
commit 65597c181a
10 changed files with 38 additions and 31 deletions

View file

@ -344,7 +344,7 @@ Class SWWMMainMenu : SWWMCleanMenu
// naive, but whatever
if ( swwm_oldlogo ) theta = clamp(2.*frametime,0.,1.);
else theta = clamp(4.*frametime,0.,1.);
if ( prevms ) demopos = demopos*(1.-theta)-40*theta;
if ( prevms ) demopos = SWWMUtility.Lerp(demopos,-40,theta);
double alph = clamp(1.-(demopos/100),0.,1.);
if ( !swwm_oldlogo )
{