mirror of
https://github.com/ZDoom/gzdoom-gles.git
synced 2024-11-11 07:12:16 +00:00
ZDoom wasn't setting drawseg_t::curline when making "fake" drawseg for skyboxes, which interfered with portal sprite clipping routine randomly.
This commit is contained in:
parent
e669e3cd08
commit
75d21d6dd8
2 changed files with 2 additions and 4 deletions
|
@ -1294,6 +1294,7 @@ void R_DrawSkyBoxes ()
|
|||
ds_p->sprtopclip = R_NewOpening (pl->maxx - pl->minx + 1);
|
||||
ds_p->maskedtexturecol = ds_p->swall = -1;
|
||||
ds_p->bFogBoundary = false;
|
||||
ds_p->curline = NULL;
|
||||
memcpy (openings + ds_p->sprbottomclip, floorclip + pl->minx, (pl->maxx - pl->minx + 1)*sizeof(short));
|
||||
memcpy (openings + ds_p->sprtopclip, ceilingclip + pl->minx, (pl->maxx - pl->minx + 1)*sizeof(short));
|
||||
|
||||
|
|
|
@ -322,11 +322,8 @@ nextpost:
|
|||
//
|
||||
bool R_ClipSpriteColumnWithPortals (fixed_t x, fixed_t y, vissprite_t* spr)
|
||||
{
|
||||
size_t numdrawsegs = ds_p-firstdrawseg;
|
||||
for (int i = (int)numdrawsegs-1; i >= 0; i--)
|
||||
for (drawseg_t* seg = ds_p; seg-- > firstdrawseg; ) // copied code from killough below
|
||||
{
|
||||
drawseg_t* seg = &firstdrawseg[i];
|
||||
|
||||
// ignore segs from other portals
|
||||
if (seg->CurrentPortalUniq != CurrentPortalUniq)
|
||||
continue;
|
||||
|
|
Loading…
Reference in a new issue