mirror of
https://github.com/fabiangreffrath/woof.git
synced 2025-09-21 10:57:15 -04:00
fix linearsky calculation for large sky texture width (#2160)
This commit is contained in:
parent
4ebaddec41
commit
344d86d61b
@ -367,10 +367,7 @@ static void R_InitTextureMapping(void)
|
||||
xtoviewangle[x] = (i<<ANGLETOFINESHIFT)-ANG90;
|
||||
// [FG] linear horizontal sky scrolling
|
||||
int angle = (0.5 - x / (double)viewwidth) * linearskyfactor;
|
||||
if (angle >= 0)
|
||||
linearskyangle[x] = angle;
|
||||
else
|
||||
linearskyangle[x] = ANG90 + angle;
|
||||
linearskyangle[x] = (angle >= 0) ? angle : ANGLE_MAX + angle;
|
||||
}
|
||||
|
||||
// Take out the fencepost cases from viewangletox.
|
||||
|
Loading…
x
Reference in New Issue
Block a user