- remove redundant if statement left over from 2260c2353d.

This commit is contained in:
Mitchell Richters 2020-07-30 08:49:01 +10:00
parent 2260c2353d
commit 02dfa10d27
4 changed files with 5 additions and 19 deletions

View File

@ -244,7 +244,7 @@ void dointerpolations(int smoothratio);
int* animateptr(int i); int* animateptr(int i);
void updateviewport(void); void updateviewport(void);
void backuppos(player_struct* p, bool clipping = true); void backuppos(player_struct* p, bool noclipping = false);
void backuplook(player_struct* p); void backuplook(player_struct* p);
void backupview(player_struct* p); void backupview(player_struct* p);

View File

@ -850,9 +850,9 @@ void applylook(int snum, double factor)
// //
//--------------------------------------------------------------------------- //---------------------------------------------------------------------------
void backuppos(player_struct* p, bool clipping) void backuppos(player_struct* p, bool noclipping)
{ {
if (clipping) if (!noclipping)
{ {
p->oposx = p->posx; p->oposx = p->posx;
p->oposy = p->posy; p->oposy = p->posy;

View File

@ -2746,14 +2746,7 @@ void processinput_d(int snum)
ksqrt((p->posx - p->bobposx) * (p->posx - p->bobposx) + (p->posy - p->bobposy) * (p->posy - p->bobposy)); ksqrt((p->posx - p->bobposx) * (p->posx - p->bobposx) + (p->posy - p->bobposy) * (p->posy - p->bobposy));
if (p->on_ground) p->bobcounter += sprite[p->i].xvel >> 1; if (p->on_ground) p->bobcounter += sprite[p->i].xvel >> 1;
if (ud.clipping == 0 && (sector[p->cursectnum].floorpicnum == MIRROR || p->cursectnum < 0 || p->cursectnum >= MAXSECTORS)) backuppos(p, ud.clipping == 0 && (sector[p->cursectnum].floorpicnum == MIRROR || p->cursectnum < 0 || p->cursectnum >= MAXSECTORS));
{
backuppos(p, false);
}
else
{
backuppos(p);
}
// Shrinking code // Shrinking code

View File

@ -3641,14 +3641,7 @@ void processinput_r(int snum)
ksqrt((p->posx - p->bobposx) * (p->posx - p->bobposx) + (p->posy - p->bobposy) * (p->posy - p->bobposy)); ksqrt((p->posx - p->bobposx) * (p->posx - p->bobposx) + (p->posy - p->bobposy) * (p->posy - p->bobposy));
if (p->on_ground) p->bobcounter += sprite[p->i].xvel >> 1; if (p->on_ground) p->bobcounter += sprite[p->i].xvel >> 1;
if (ud.clipping == 0 && (sector[p->cursectnum].floorpicnum == MIRROR || p->cursectnum < 0 || p->cursectnum >= MAXSECTORS)) backuppos(p, ud.clipping == 0 && (sector[p->cursectnum].floorpicnum == MIRROR || p->cursectnum < 0 || p->cursectnum >= MAXSECTORS));
{
backuppos(p, false);
}
else
{
backuppos(p);
}
// Shrinking code // Shrinking code