mirror of
https://git.do.srb2.org/STJr/SRB2.git
synced 2024-11-15 09:11:48 +00:00
Semi-hacky fix to R_AddSpriteDefs printing Added -1 frames in 0 sprites
: if the start marker is equal to or beyond the end marker, none of r_things' for (l = startlump; l < endlump; l++)
loops will run, so just assume no sprites.
Simply put, `W_CheckNumForFolderStartPK3` and its `End` equivalent will never return INT16_MAX for nonexistence, and I don't want to break any assumptions elsewhere by modifying those functions directly, so this is the simplest possible fix.
This commit is contained in:
parent
ae2594e5ce
commit
e75490c99d
1 changed files with 1 additions and 1 deletions
|
@ -451,7 +451,7 @@ void R_AddSpriteDefs(UINT16 wadnum)
|
|||
else
|
||||
start++; // just after S_START
|
||||
|
||||
if (end == INT16_MAX)
|
||||
if (end == INT16_MAX || start >= end)
|
||||
{
|
||||
CONS_Debug(DBG_SETUP, "no sprites in pwad %d\n", wadnum);
|
||||
return;
|
||||
|
|
Loading…
Reference in a new issue