mirror of
https://github.com/fabiangreffrath/woof.git
synced 2025-09-20 18:37:48 -04:00
Merge branch 'master' of github.com:fabiangreffrath/woof
This commit is contained in:
commit
9aa4ddd7f8
12
src/r_data.c
12
src/r_data.c
@ -1048,11 +1048,10 @@ void R_InitData(void)
|
||||
int R_FlatNumForName(const char *name) // killough -- const added
|
||||
{
|
||||
int i = (W_CheckNumForName)(name, ns_flats);
|
||||
if (i == -1)
|
||||
if (i == NO_TEXTURE)
|
||||
{
|
||||
// [FG] render missing flats as SKY
|
||||
I_Printf(VB_WARNING, "R_FlatNumForName: %.8s not found", name);
|
||||
return skyflatnum;
|
||||
return i;
|
||||
}
|
||||
return i - firstflat;
|
||||
}
|
||||
@ -1124,7 +1123,12 @@ void R_PrecacheLevel(void)
|
||||
memset(hitlist, 0, numflats);
|
||||
|
||||
for (i = numsectors; --i >= 0; )
|
||||
hitlist[sectors[i].floorpic] = hitlist[sectors[i].ceilingpic] = 1;
|
||||
{
|
||||
if (sectors[i].floorpic > NO_TEXTURE)
|
||||
hitlist[sectors[i].floorpic] = 1;
|
||||
if (sectors[i].ceilingpic > NO_TEXTURE)
|
||||
hitlist[sectors[i].ceilingpic] = 1;
|
||||
}
|
||||
|
||||
for (i = numflats; --i >= 0; )
|
||||
if (hitlist[i])
|
||||
|
@ -41,6 +41,8 @@ struct mobj_s;
|
||||
|
||||
#define MAXDRAWSEGS 256
|
||||
|
||||
#define NO_TEXTURE (-1)
|
||||
|
||||
//
|
||||
// INTERNAL MAP TYPES
|
||||
// used by play and refresh
|
||||
|
@ -304,6 +304,9 @@ visplane_t *R_FindPlane(fixed_t height, int picnum, int lightlevel,
|
||||
visplane_t *check;
|
||||
unsigned hash; // killough
|
||||
|
||||
if (picnum == NO_TEXTURE)
|
||||
return NULL;
|
||||
|
||||
if (picnum == skyflatnum || picnum & PL_SKYFLAT) // killough 10/98
|
||||
{
|
||||
lightlevel = 0; // killough 7/19/98: most skies map together
|
||||
|
Loading…
x
Reference in New Issue
Block a user