Fix some textures not being rendered, like STARGR2 in E2M3

This occurs if all texture IDs on a particular line are multiples of
256 (like STARGR2 = 256) since the cast to boolean (byte) destroys
significant bits.
This commit is contained in:
Lephenixnoir 2021-08-12 14:03:03 +02:00
parent 5520a6e5ee
commit 56e0d05640
Signed by: Lephenixnoir
GPG Key ID: 1BBA026E13FC0495
2 changed files with 2 additions and 3 deletions

View File

@ -375,7 +375,7 @@ const byte* R_GetColumn ( int tex, int col )
/* CGDOOM: To save RAM in WADs bound by limited memory, composite textures
can be allowed only up to a certain size. Original CGDOOM limits to 8192
bytes to that switches can appear, but some other textures fail. */
bytes so that switches can appear, but some other textures fail. */
#if 0
if(lump <= 0 && texturecompositesize[tex] > 8192)
{
@ -586,7 +586,6 @@ void R_InitTextures (void)
}
//
// R_InitFlats
//

View File

@ -607,7 +607,7 @@ void R_StoreWallRange ( int start, int stop )
}
// calculate rw_offset (only needed for textured lines)
segtextured = (boolean)(midtexture | toptexture | bottomtexture | maskedtexture);
segtextured = (midtexture | toptexture | bottomtexture | maskedtexture) != 0;
if (segtextured)
{