From 4ee7cf2de159a388ecc1761a71fb77626031fac5 Mon Sep 17 00:00:00 2001 From: Magnus Norddahl Date: Thu, 29 Nov 2018 00:03:50 +0100 Subject: [PATCH] - forgot to set the light level --- src/polyrenderer/scene/poly_model.cpp | 4 ++-- src/swrenderer/things/r_model.cpp | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/polyrenderer/scene/poly_model.cpp b/src/polyrenderer/scene/poly_model.cpp index 30bad72de..cba1c991b 100644 --- a/src/polyrenderer/scene/poly_model.cpp +++ b/src/polyrenderer/scene/poly_model.cpp @@ -46,7 +46,7 @@ void PolyRenderModel(PolyRenderThread *thread, const Mat4f &worldToClip, uint32_ bool foggy = false; int actualextralight = foggy ? 0 : PolyRenderer::Instance()->Viewpoint.extralight << 4; bool fullbrightSprite = ((actor->renderflags & RF_FULLBRIGHT) || (actor->flags5 & MF5_BRIGHT)); - int lightlevel = fullbrightSprite ? 255 : actor->Sector->lightlevel + actualextralight; + renderer.lightlevel = fullbrightSprite ? 255 : actor->Sector->lightlevel + actualextralight; renderer.visibility = PolyRenderer::Instance()->Light.SpriteGlobVis(foggy); renderer.fillcolor = actor->fillcolor; @@ -90,7 +90,7 @@ void PolyRenderHUDModel(PolyRenderThread *thread, const Mat4f &worldToClip, uint bool foggy = false; int actualextralight = foggy ? 0 : PolyRenderer::Instance()->Viewpoint.extralight << 4; bool fullbrightSprite = isBright(psp); - int lightlevel = fullbrightSprite ? 255 : playermo->Sector->lightlevel + actualextralight; + renderer.lightlevel = fullbrightSprite ? 255 : playermo->Sector->lightlevel + actualextralight; renderer.visibility = PolyRenderer::Instance()->Light.SpriteGlobVis(foggy); PalEntry ThingColor = (playermo->RenderStyle.Flags & STYLEF_ColorIsFixed) ? playermo->fillcolor : 0xffffff; diff --git a/src/swrenderer/things/r_model.cpp b/src/swrenderer/things/r_model.cpp index fc6159fe1..611d75669 100644 --- a/src/swrenderer/things/r_model.cpp +++ b/src/swrenderer/things/r_model.cpp @@ -85,7 +85,7 @@ namespace swrenderer bool foggy = false; int actualextralight = foggy ? 0 : PolyRenderer::Instance()->Viewpoint.extralight << 4; bool fullbrightSprite = ((actor->renderflags & RF_FULLBRIGHT) || (actor->flags5 & MF5_BRIGHT)); - int lightlevel = fullbrightSprite ? 255 : actor->Sector->lightlevel + actualextralight; + renderer.lightlevel = fullbrightSprite ? 255 : actor->Sector->lightlevel + actualextralight; renderer.visibility = PolyRenderer::Instance()->Light.SpriteGlobVis(foggy); renderer.fillcolor = actor->fillcolor; @@ -130,7 +130,7 @@ namespace swrenderer bool foggy = false; int actualextralight = foggy ? 0 : PolyRenderer::Instance()->Viewpoint.extralight << 4; bool fullbrightSprite = isBright(psp); - int lightlevel = fullbrightSprite ? 255 : playermo->Sector->lightlevel + actualextralight; + renderer.lightlevel = fullbrightSprite ? 255 : playermo->Sector->lightlevel + actualextralight; renderer.visibility = PolyRenderer::Instance()->Light.SpriteGlobVis(foggy); PalEntry ThingColor = (playermo->RenderStyle.Flags & STYLEF_ColorIsFixed) ? playermo->fillcolor : 0xffffff;