mirror of
https://github.com/ZDoom/qzdoom-gpl.git
synced 2025-02-08 14:01:49 +00:00
Fix drawing dormant lights
This commit is contained in:
parent
4e56c9a41a
commit
62716c3d91
1 changed files with 18 additions and 15 deletions
|
@ -560,6 +560,8 @@ static void Draw1Column(int x, int y1, int y2, WallSampler &sampler, void(*draw1
|
||||||
dc_lights = lightbuffer + nextlightindex;
|
dc_lights = lightbuffer + nextlightindex;
|
||||||
FLightNode *cur_node = dc_light_list;
|
FLightNode *cur_node = dc_light_list;
|
||||||
while (cur_node && nextlightindex < 64 * 1024)
|
while (cur_node && nextlightindex < 64 * 1024)
|
||||||
|
{
|
||||||
|
if (!(cur_node->lightsource->flags2&MF2_DORMANT))
|
||||||
{
|
{
|
||||||
uint32_t red = cur_node->lightsource->GetRed();
|
uint32_t red = cur_node->lightsource->GetRed();
|
||||||
uint32_t green = cur_node->lightsource->GetGreen();
|
uint32_t green = cur_node->lightsource->GetGreen();
|
||||||
|
@ -579,6 +581,7 @@ static void Draw1Column(int x, int y1, int y2, WallSampler &sampler, void(*draw1
|
||||||
|
|
||||||
// Precalculate the constant part of the dot here so the drawer doesn't have to.
|
// Precalculate the constant part of the dot here so the drawer doesn't have to.
|
||||||
light.x = light.x * light.x + light.y * light.y;
|
light.x = light.x * light.x + light.y * light.y;
|
||||||
|
}
|
||||||
|
|
||||||
cur_node = cur_node->nextLight;
|
cur_node = cur_node->nextLight;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue