- fixed: RecreateAllAttachedLights must activate the lights it creates.

This also removes the gl_attachedlights CVAR because with the new management this doesn't really work anymore.

# Conflicts:
#	src/gl/system/gl_cvars.h
#	wadsrc/static/menudef.txt
This commit is contained in:
Christoph Oelckers 2019-01-30 20:21:00 +01:00 committed by drfrag
parent 309407ed61
commit 4daa256e2f
4 changed files with 1 additions and 5 deletions

View file

@ -87,8 +87,6 @@ CUSTOM_CVAR (Bool, gl_lights, true, CVAR_ARCHIVE | CVAR_GLOBALCONFIG | CVAR_NOIN
else AActor::DeleteAllAttachedLights();
}
CVAR (Bool, gl_attachedlights, true, CVAR_ARCHIVE | CVAR_GLOBALCONFIG);
//==========================================================================
//
//==========================================================================
@ -872,6 +870,7 @@ void AActor::RecreateAllAttachedLights()
if (a->IsKindOf(NAME_DynamicLight))
{
::AttachLight(a);
::ActivateLight(a);
}
else
{

View file

@ -5,7 +5,6 @@
#include "g_levellocals.h"
EXTERN_CVAR(Bool, gl_lights)
EXTERN_CVAR(Bool, gl_attachedlights)
class FSerializer;

View file

@ -22,7 +22,6 @@ EXTERN_CVAR(Bool, gl_usefb)
EXTERN_CVAR(Int, gl_weaponlight)
EXTERN_CVAR (Bool, gl_lights);
EXTERN_CVAR (Bool, gl_attachedlights);
EXTERN_CVAR (Bool, gl_lights_checkside);
EXTERN_CVAR (Bool, gl_light_sprites);
EXTERN_CVAR (Bool, gl_light_particles);

View file

@ -2295,7 +2295,6 @@ OptionMenu "GLLightOptions" protected
Title "$GLLIGHTMNU_TITLE"
Option "$TCMNU_DYNLIGHTS", "r_dynlights", "OnOff"
Option "$GLLIGHTMNU_LIGHTSENABLED", gl_lights, "OnOff"
Option "$GLLIGHTMNU_LIGHTDEFS", gl_attachedlights, "YesNo"
Option "$GLLIGHTMNU_CLIPLIGHTS", gl_lights_checkside, "YesNo"
Option "$GLLIGHTMNU_LIGHTSPRITES", gl_light_sprites, "YesNo"
Option "$GLLIGHTMNU_LIGHTPARTICLES", gl_light_particles, "YesNo"