From ad51b791d5d65eb3d35adbd24d1af4e4cfcaf0d2 Mon Sep 17 00:00:00 2001 From: Sryder Date: Thu, 21 May 2020 18:11:38 +0100 Subject: [PATCH] Fix software not contrasting properly to +-2 --- src/p_setup.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/p_setup.c b/src/p_setup.c index ea0c04d5c..cd1cabdc9 100644 --- a/src/p_setup.c +++ b/src/p_setup.c @@ -461,7 +461,7 @@ void P_UpdateSegLightOffset(seg_t *li) abs(li->v1->y - li->v2->y))), 90*FRACUNIT) * ((fixed_t)contrast * 2); // Between -2 and 2 for software, -16 and 16 for hardware - li->lightOffset = FixedFloor((extralight / contrast) + (FRACUNIT / 2)) / FRACUNIT; + li->lightOffset = FixedFloor((extralight / 8) + (FRACUNIT / 2)) / FRACUNIT; #ifdef HWRENDER li->hwLightOffset = FixedFloor(extralight + (FRACUNIT / 2)) / FRACUNIT; #endif