From 3b319b958eadc663b64189ed30eb0fb832cbc047 Mon Sep 17 00:00:00 2001 From: Leonx254 Date: Mon, 16 Oct 2023 19:56:14 -0300 Subject: [PATCH] fix broken thingy --- RSDKv3/Palette.cpp | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/RSDKv3/Palette.cpp b/RSDKv3/Palette.cpp index 89e22fc0..e115346a 100644 --- a/RSDKv3/Palette.cpp +++ b/RSDKv3/Palette.cpp @@ -76,10 +76,11 @@ void SetLimitedFade(byte paletteID, byte R, byte G, byte B, ushort alpha, int st PACK_RGB888(activePalette[i], (byte)((ushort)(R * alpha + alpha2 * activePalette32[i].r) >> 8), (byte)((ushort)(G * alpha + alpha2 * activePalette32[i].g) >> 8), (byte)((ushort)(B * alpha + alpha2 * activePalette32[i].b) >> 8)); - activePalette32[i].r = (byte)((ushort)(R * alpha + alpha2 * activePalette32[i].r) >> 8); - activePalette32[i].g = (byte)((ushort)(G * alpha + alpha2 * activePalette32[i].g) >> 8); - activePalette32[i].b = (byte)((ushort)(B * alpha + alpha2 * activePalette32[i].b) >> 8); - if (renderType == RENDER_HW) + if (renderType == RENDER_HW) { // not like this works on HW.... + activePalette32[i].r = (byte)((ushort)(R * alpha + alpha2 * activePalette32[i].r) >> 8); + activePalette32[i].g = (byte)((ushort)(G * alpha + alpha2 * activePalette32[i].g) >> 8); + activePalette32[i].b = (byte)((ushort)(B * alpha + alpha2 * activePalette32[i].b) >> 8); activePalette[i] |= 1; + } } } \ No newline at end of file