diff --git a/src/hardware/hw_main.c b/src/hardware/hw_main.c index c98a7f47a..6e66795da 100644 --- a/src/hardware/hw_main.c +++ b/src/hardware/hw_main.c @@ -1126,9 +1126,22 @@ void HWR_SplitWall(sector_t *sector, FOutVector *wallVerts, INT32 texnum, FSurfa } #endif - // Found a break - bot = min(max(bheight, realbot), top); +#ifdef ESLOPE + if (endbheight > endtop) + endbot = endtop; +#endif + if (bheight >= top) + continue; + + //Found a break; + bot = bheight; + + if (bot < realbot) + bot = realbot; + +#ifdef ESLOPE endbot = min(max(endbheight, endrealbot), endtop); +#endif Surf->PolyColor.s.alpha = alpha;