- fix interpolation for p->q16rotscrnang. Setting p->oq16rotscrnang in displayrooms() (at frame rate) isn't where it should be done.

This commit is contained in:
Mitchell Richters 2020-07-28 22:24:30 +10:00
parent f49ded7962
commit 27b3c8e0f8
2 changed files with 1 additions and 3 deletions

View file

@ -881,6 +881,7 @@ void checklook(int snum, int sb_snum)
} }
p->oq16ang = p->q16ang; p->oq16ang = p->q16ang;
p->oq16look_ang = p->q16look_ang; p->oq16look_ang = p->q16look_ang;
p->oq16rotscrnang = p->q16rotscrnang;
if (cl_syncinput) if (cl_syncinput)
applylook(snum, 1); applylook(snum, 1);

View file

@ -539,10 +539,7 @@ void displayrooms(int snum, int smoothratio)
if (!cl_syncinput) if (!cl_syncinput)
renderSetRollAngle(p->q16rotscrnang / (float)(FRACUNIT)); renderSetRollAngle(p->q16rotscrnang / (float)(FRACUNIT));
else else
{
renderSetRollAngle((p->oq16rotscrnang + mulscale16(((p->q16rotscrnang - p->oq16rotscrnang + (1024 << FRACBITS)) & 0x7FFFFFF) - (1024 << FRACBITS), smoothratio)) / (float)(FRACUNIT)); renderSetRollAngle((p->oq16rotscrnang + mulscale16(((p->q16rotscrnang - p->oq16rotscrnang + (1024 << FRACBITS)) & 0x7FFFFFF) - (1024 << FRACBITS), smoothratio)) / (float)(FRACUNIT));
p->oq16rotscrnang = p->q16rotscrnang; // JBF: save it for next time
}
if ((snum == myconnectindex) && (numplayers > 1)) if ((snum == myconnectindex) && (numplayers > 1))
{ {