restore original fix for "garbage lines at the top of weapon sprites" (#1485)

* Revert "fix garbage lines at the top of weapon sprites (#1377)"

This reverts commit 6cccb751849b83d0f5e12b9c85f139f085d62db1.

* restore original fix
This commit is contained in:
Roman Fomin 2024-02-17 23:38:08 +07:00 committed by GitHub
parent 2744c8a141
commit 27f1a65c60
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -586,7 +586,13 @@ void R_ExecuteSetViewSize (void)
// psprite scales
pspritescale = FixedDiv(viewwidth_nonwide, SCREENWIDTH); // killough 11/98
pspriteiscale = FixedDiv(SCREENWIDTH, viewwidth_nonwide) + 1; // killough 11/98
pspriteiscale = FixedDiv(SCREENWIDTH, viewwidth_nonwide); // killough 11/98
// [FG] make sure that the product of the weapon sprite scale factor
// and its reciprocal is always at least FRACUNIT to
// fix garbage lines at the top of weapon sprites
while (FixedMul(pspriteiscale, pspritescale) < FRACUNIT)
pspriteiscale++;
skyiscale = FixedDiv(160 << FRACBITS, focallength);