Fix for bug #17589: removing a lamp in the game engine with glsl

materials did not work correct.
This commit is contained in:
Brecht Van Lommel 2008-09-10 09:51:06 +00:00
parent ecc5bdb8d7
commit 75078d62df

@ -65,6 +65,13 @@ KX_LightObject::KX_LightObject(void* sgReplicationInfo,SG_Callbacks callbacks,
KX_LightObject::~KX_LightObject()
{
GPULamp *lamp;
if((lamp = GetGPULamp())) {
float obmat[4][4] = {{0}};
GPU_lamp_update(lamp, 0, obmat);
}
m_rendertools->RemoveLight(&m_lightobj);
}