From 1ba4fe99a75d0fcc66c85f533127a1de4f124eb9 Mon Sep 17 00:00:00 2001 From: Alug Date: Mon, 2 Nov 2026 14:38:38 +0100 Subject: [PATCH] fix fof noencore ceiling checks being flipped in opengl renderer matches software now even if most custom maps were made with opengl in mind, stuff did not work anyways for years so this shouldnt hopefully cause any issues --- src/hardware/hw_main.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/hardware/hw_main.cpp b/src/hardware/hw_main.cpp index e05d923ee..67c7d5817 100644 --- a/src/hardware/hw_main.cpp +++ b/src/hardware/hw_main.cpp @@ -2961,7 +2961,7 @@ static void HWR_Subsector(size_t num) } else { - HWR_GetFlat(flatlump, R_NoEncore(rover->master->frontsector, !bottom)); + HWR_GetFlat(flatlump, R_NoEncore(rover->master->frontsector, bottom)); light = R_GetPlaneLight(gl_frontsector, centerHeight, underside); HWR_RenderPlane(sub, &extrasubsectors[num], !bottom, roverheight, HWR_RippleBlend(gl_frontsector, rover, false)|PF_Occlude, *gl_frontsector->lightlist[light].lightlevel, flatlump, @@ -4286,7 +4286,10 @@ static void HWR_RenderDrawNodes(void) gl_frontsector = NULL; if (!(plane->blend & PF_NoTexture)) - HWR_GetFlat(plane->lumpnum, R_NoEncore(plane->FOFSector, plane->isceiling)); + { + const boolean ceiling = plane->FOFSector ? !plane->isceiling : plane->isceiling; // match software! + HWR_GetFlat(plane->lumpnum, R_NoEncore(plane->FOFSector, ceiling)); + } HWR_RenderPlane(NULL, plane->xsub, plane->isceiling, plane->fixedheight, plane->blend, plane->lightlevel, plane->lumpnum, plane->FOFSector, plane->alpha, plane->planecolormap);