Fix empty WAD files printing the wrong sprite count.
This commit is contained in:
parent
ec9d47cb34
commit
2fff5e9f6d
|
@ -385,9 +385,9 @@ void R_AddSpriteDefs(UINT16 wadnum)
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
start = W_CheckNumForNamePwad("S_START", wadnum, 0);
|
start = W_CheckNumForNamePwad("S_START", wadnum, 0);
|
||||||
if (start == UINT16_MAX)
|
if (start == INT16_MAX)
|
||||||
start = W_CheckNumForNamePwad("SS_START", wadnum, 0); //deutex compatib.
|
start = W_CheckNumForNamePwad("SS_START", wadnum, 0); //deutex compatib.
|
||||||
if (start == UINT16_MAX)
|
if (start == INT16_MAX)
|
||||||
start = 0; //let say S_START is lump 0
|
start = 0; //let say S_START is lump 0
|
||||||
else
|
else
|
||||||
start++; // just after S_START
|
start++; // just after S_START
|
||||||
|
@ -402,11 +402,11 @@ void R_AddSpriteDefs(UINT16 wadnum)
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
end = W_CheckNumForNamePwad("S_END",wadnum,start);
|
end = W_CheckNumForNamePwad("S_END",wadnum,start);
|
||||||
if (end == UINT16_MAX)
|
if (end == INT16_MAX)
|
||||||
end = W_CheckNumForNamePwad("SS_END",wadnum,start); //deutex compatib.
|
end = W_CheckNumForNamePwad("SS_END",wadnum,start); //deutex compatib.
|
||||||
}
|
}
|
||||||
|
|
||||||
if (end == UINT16_MAX)
|
if (end == INT16_MAX)
|
||||||
{
|
{
|
||||||
CONS_Debug(DBG_SETUP, "no sprites in pwad %d\n", wadnum);
|
CONS_Debug(DBG_SETUP, "no sprites in pwad %d\n", wadnum);
|
||||||
return;
|
return;
|
||||||
|
|
Loading…
Reference in New Issue