mirror of
https://github.com/UberGames/lilium-voyager.git
synced 2024-12-13 13:40:56 +00:00
Have OpenGL2 "map $lightmap" check for NULL tr.lightmaps too
Zero length lightmap lump will have NULL tr.lightmaps. OpenGL1 already has this check, because r_vertexLight 1 would crash Team Arena. OpenGL2 does not disable loading lightmaps when r_vertexLight is 1 though, so it does not have that issue.
This commit is contained in:
parent
7a4ef47476
commit
9c99cf29db
1 changed files with 1 additions and 1 deletions
|
@ -639,7 +639,7 @@ static qboolean ParseStage( shaderStage_t *stage, char **text )
|
|||
else if ( !Q_stricmp( token, "$lightmap" ) )
|
||||
{
|
||||
stage->bundle[0].isLightmap = qtrue;
|
||||
if ( shader.lightmapIndex < 0 ) {
|
||||
if ( shader.lightmapIndex < 0 || !tr.lightmaps ) {
|
||||
stage->bundle[0].image[0] = tr.whiteImage;
|
||||
} else {
|
||||
stage->bundle[0].image[0] = tr.lightmaps[shader.lightmapIndex];
|
||||
|
|
Loading…
Reference in a new issue