mirror of
https://git.do.srb2.org/STJr/SRB2.git
synced 2025-02-01 14:10:54 +00:00
Take slopes into account even more in FOF wall cutoff in HWR_ProcessSeg
This commit is contained in:
parent
ed82b94e64
commit
eb1e7eff8f
1 changed files with 22 additions and 8 deletions
|
@ -1641,10 +1641,17 @@ static void HWR_ProcessSeg(void) // Sort of like GLWall::Process in GZDoom
|
|||
hS = P_GetFFloorTopZAt (rover, v2x, v2y);
|
||||
l = P_GetFFloorBottomZAt(rover, v1x, v1y);
|
||||
lS = P_GetFFloorBottomZAt(rover, v2x, v2y);
|
||||
if (!(*rover->t_slope) && !gl_frontsector->c_slope && !gl_backsector->c_slope && h > highcut)
|
||||
h = hS = highcut;
|
||||
if (!(*rover->b_slope) && !gl_frontsector->f_slope && !gl_backsector->f_slope && l < lowcut)
|
||||
l = lS = lowcut;
|
||||
// Adjust the heights so the FOF does not overlap with top and bottom textures.
|
||||
if (h >= highcut && hS >= highcutslope)
|
||||
{
|
||||
h = highcut;
|
||||
hS = highcutslope;
|
||||
}
|
||||
if (l <= lowcut && lS <= lowcutslope)
|
||||
{
|
||||
l = lowcut;
|
||||
lS = lowcutslope;
|
||||
}
|
||||
//Hurdler: HW code starts here
|
||||
//FIXME: check if peging is correct
|
||||
// set top/bottom coords
|
||||
|
@ -1790,10 +1797,17 @@ static void HWR_ProcessSeg(void) // Sort of like GLWall::Process in GZDoom
|
|||
hS = P_GetFFloorTopZAt (rover, v2x, v2y);
|
||||
l = P_GetFFloorBottomZAt(rover, v1x, v1y);
|
||||
lS = P_GetFFloorBottomZAt(rover, v2x, v2y);
|
||||
if (!(*rover->t_slope) && !gl_frontsector->c_slope && !gl_backsector->c_slope && h > highcut)
|
||||
h = hS = highcut;
|
||||
if (!(*rover->b_slope) && !gl_frontsector->f_slope && !gl_backsector->f_slope && l < lowcut)
|
||||
l = lS = lowcut;
|
||||
// Adjust the heights so the FOF does not overlap with top and bottom textures.
|
||||
if (h >= highcut && hS >= highcutslope)
|
||||
{
|
||||
h = highcut;
|
||||
hS = highcutslope;
|
||||
}
|
||||
if (l <= lowcut && lS <= lowcutslope)
|
||||
{
|
||||
l = lowcut;
|
||||
lS = lowcutslope;
|
||||
}
|
||||
//Hurdler: HW code starts here
|
||||
//FIXME: check if peging is correct
|
||||
// set top/bottom coords
|
||||
|
|
Loading…
Reference in a new issue