properly support -keeplights option. Current implementation never worked.
This commit is contained in:
parent
6b01d68ba6
commit
76dd045925
|
|
@ -702,6 +702,11 @@ int BSPMain( int argc, char **argv )
|
||||||
Sys_Printf( "Disabling water\n" );
|
Sys_Printf( "Disabling water\n" );
|
||||||
nowater = qtrue;
|
nowater = qtrue;
|
||||||
}
|
}
|
||||||
|
else if( !strcmp( argv[ i ], "-keeplights" ))
|
||||||
|
{
|
||||||
|
keepLights = qtrue;
|
||||||
|
Sys_Printf( "Leaving light entities on map after compile\n" );
|
||||||
|
}
|
||||||
else if( !strcmp( argv[ i ], "-nodetail" ) )
|
else if( !strcmp( argv[ i ], "-nodetail" ) )
|
||||||
{
|
{
|
||||||
Sys_Printf( "Ignoring detail brushes\n") ;
|
Sys_Printf( "Ignoring detail brushes\n") ;
|
||||||
|
|
|
||||||
|
|
@ -2105,12 +2105,6 @@ int LightMain( int argc, char **argv )
|
||||||
else
|
else
|
||||||
Sys_Printf( " shader lightstyles hack: enabled\n" );
|
Sys_Printf( " shader lightstyles hack: enabled\n" );
|
||||||
|
|
||||||
keepLights = game->keepLights;
|
|
||||||
if (keepLights == qtrue)
|
|
||||||
Sys_Printf( " keep lights: enabled\n" );
|
|
||||||
else
|
|
||||||
Sys_Printf( " keep lights: disabled\n" );
|
|
||||||
|
|
||||||
patchShadows = game->patchShadows;
|
patchShadows = game->patchShadows;
|
||||||
if (patchShadows == qtrue)
|
if (patchShadows == qtrue)
|
||||||
Sys_Printf( " patch shadows: enabled\n" );
|
Sys_Printf( " patch shadows: enabled\n" );
|
||||||
|
|
@ -2730,11 +2724,6 @@ int LightMain( int argc, char **argv )
|
||||||
noStyles = qfalse;
|
noStyles = qfalse;
|
||||||
Sys_Printf( "Enabling lightstyles\n" );
|
Sys_Printf( "Enabling lightstyles\n" );
|
||||||
}
|
}
|
||||||
else if( !strcmp( argv[ i ], "-keeplights" ))
|
|
||||||
{
|
|
||||||
keepLights = qtrue;
|
|
||||||
Sys_Printf( "Leaving light entities on map after compile\n" );
|
|
||||||
}
|
|
||||||
else if( !strcmp( argv[ i ], "-cpma" ) )
|
else if( !strcmp( argv[ i ], "-cpma" ) )
|
||||||
{
|
{
|
||||||
cpmaHack = qtrue;
|
cpmaHack = qtrue;
|
||||||
|
|
|
||||||
|
|
@ -287,6 +287,10 @@ void SetLightStyles( void )
|
||||||
char lightTargets[ MAX_SWITCHED_LIGHTS ][ 64 ];
|
char lightTargets[ MAX_SWITCHED_LIGHTS ][ 64 ];
|
||||||
int lightStyles[ MAX_SWITCHED_LIGHTS ];
|
int lightStyles[ MAX_SWITCHED_LIGHTS ];
|
||||||
|
|
||||||
|
/* -keeplights option: force lights to be kept and ignore what the map file says */
|
||||||
|
if (keepLights)
|
||||||
|
SetKeyValue(&entities[0], "_keepLights", "1");
|
||||||
|
|
||||||
/* ydnar: determine if we keep lights in the bsp */
|
/* ydnar: determine if we keep lights in the bsp */
|
||||||
if (KeyExists(&entities[ 0 ], "_keepLights") == qtrue)
|
if (KeyExists(&entities[ 0 ], "_keepLights") == qtrue)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user