mirror of
https://git.do.srb2.org/STJr/SRB2.git
synced 2025-01-29 12:40:58 +00:00
* Always remove linkdraw vissprites from unsorted drawing chain.
* Make the related I_Error more descriptive and "#define PARANOIA"'d only.
This commit is contained in:
parent
dda9148e56
commit
b2fc2e03ba
1 changed files with 12 additions and 7 deletions
|
@ -1845,11 +1845,16 @@ void R_SortVisSprites(void)
|
|||
&& dsfirst->sz < ds->sz)
|
||||
continue;
|
||||
|
||||
// remove from chain
|
||||
ds->next->prev = ds->prev;
|
||||
ds->prev->next = ds->next;
|
||||
linkedvissprites++;
|
||||
break;
|
||||
}
|
||||
|
||||
// remove from chain
|
||||
ds->next->prev = ds->prev;
|
||||
ds->prev->next = ds->next;
|
||||
linkedvissprites++;
|
||||
|
||||
if (dsfirst != &unsorted)
|
||||
{
|
||||
if (!(ds->cut & SC_FULLBRIGHT))
|
||||
ds->colormap = dsfirst->colormap;
|
||||
ds->extra_colormap = dsfirst->extra_colormap;
|
||||
|
@ -1870,8 +1875,6 @@ void R_SortVisSprites(void)
|
|||
ds->next = dsnext->next;
|
||||
dsnext->next = ds;
|
||||
}
|
||||
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1882,8 +1885,10 @@ void R_SortVisSprites(void)
|
|||
bestscale = bestdispoffset = INT32_MAX;
|
||||
for (ds = unsorted.next; ds != &unsorted; ds = ds->next)
|
||||
{
|
||||
#ifdef PARANOIA
|
||||
if (ds->cut & SC_LINKDRAW)
|
||||
I_Error("No link made!"); // testing
|
||||
I_Error("R_SortVisSprites: no link or discardal made for linkdraw!");
|
||||
#endif
|
||||
|
||||
if (ds->sortscale < bestscale)
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue