From 7018ce925bdeeb0da76efad37c7159571ab60921 Mon Sep 17 00:00:00 2001 From: toasterbabe Date: Mon, 12 Feb 2018 21:31:03 +0000 Subject: [PATCH] Fixed the strengths going in the wrong direction of transparency in GL! --- src/hardware/hw_draw.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/hardware/hw_draw.c b/src/hardware/hw_draw.c index 0e10c6473..072380e6b 100644 --- a/src/hardware/hw_draw.c +++ b/src/hardware/hw_draw.c @@ -509,12 +509,12 @@ void HWR_FadeScreenMenuBack(UINT16 color, UINT8 strength) if (color & 0xFF00) // Do COLORMAP fade. { Surf.FlatColor.rgba = UINT2RGBA(0x01010160); - Surf.FlatColor.s.alpha = 0xFF - (strength*8); + Surf.FlatColor.s.alpha = (strength*8); } else // Do TRANSMAP** fade. { Surf.FlatColor.rgba = pLocalPalette[color].rgba; - Surf.FlatColor.s.alpha = (UINT8)((float)(10-strength)*25.5f); + Surf.FlatColor.s.alpha = (UINT8)(strength*25.5f); } HWD.pfnDrawPolygon(&Surf, v, 4, PF_NoTexture|PF_Modulated|PF_Translucent|PF_NoDepthTest); }