From cf1d3bce53750da4eaf855c313ff41c47b4cef14 Mon Sep 17 00:00:00 2001 From: Alug Date: Tue, 29 Jul 2025 01:21:12 +0200 Subject: [PATCH] add slope check here not necessary but may skip more uneeded checks and stuff --- src/hardware/hw_main.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/hardware/hw_main.cpp b/src/hardware/hw_main.cpp index c2a61836c..98e776659 100644 --- a/src/hardware/hw_main.cpp +++ b/src/hardware/hw_main.cpp @@ -728,7 +728,8 @@ static void HWR_RenderPlane(subsector_t *subsector, poly_subsector_t *xsub, bool for (i = 0, v3d = planeVerts; i < (INT32)nrPlaneVerts; i++,v3d++,pv++) SETUP3DVERT(v3d, pv->x, pv->y); - lightlevel = HWR_CalcSlopeLight(lightlevel, slope, gl_frontsector, (FOFsector != NULL)); + if (slope) + lightlevel = HWR_CalcSlopeLight(lightlevel, slope, gl_frontsector, (FOFsector != NULL)); if (subsector && lightlevel != 255 && (havesnakerpad || havepazrcst || havefaytpad)) {