mirror of
https://github.com/KartKrewDev/RingRacers.git
synced 2026-01-03 21:52:40 +00:00
Fix R_CacheSpriteBrightMap trying to cache out of range lump
This commit is contained in:
parent
badb87697c
commit
9b08730281
1 changed files with 8 additions and 1 deletions
|
|
@ -1245,7 +1245,14 @@ static patch_t *R_CacheSpriteBrightMap(const spriteinfo_t *sprinfo, UINT8 frame)
|
|||
name = sprinfo->bright[SPRINFO_DEFAULT_PIVOT];
|
||||
}
|
||||
|
||||
return W_CachePatchNum(W_CheckNumForLongName(name), PU_SPRITE);
|
||||
const lumpnum_t num = W_CheckNumForLongName(name);
|
||||
|
||||
if (num == LUMPERROR)
|
||||
{
|
||||
return NULL;
|
||||
}
|
||||
|
||||
return W_CachePatchNum(num, PU_SPRITE);
|
||||
}
|
||||
|
||||
//
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue