From 5a761dd3c3ec891e5d06b5e2401134a0b24f3480 Mon Sep 17 00:00:00 2001 From: Christoph Oelckers Date: Sat, 1 Jul 2017 16:19:41 +0200 Subject: [PATCH] - fixed alpha of palette index 0 for ice and alpha translations. --- src/r_data/r_translate.cpp | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/r_data/r_translate.cpp b/src/r_data/r_translate.cpp index d8bff43d47..d8af38b11e 100644 --- a/src/r_data/r_translate.cpp +++ b/src/r_data/r_translate.cpp @@ -942,7 +942,9 @@ void R_InitTranslationTables () IcePaletteRemap[i] = ColorMatcher.Pick (IcePalette[i][0], IcePalette[i][1], IcePalette[i][2]); } FRemapTable *remap = translationtables[TRANSLATION_Standard][7]; - for (i = 0; i < 256; ++i) + remap->Remap[0] = 0; + remap->Palette[0] = 0; + for (i = 1; i < 256; ++i) { int r = GPalette.BaseColors[i].r; int g = GPalette.BaseColors[i].g; @@ -955,7 +957,9 @@ void R_InitTranslationTables () // The alphatexture translation. Since alphatextures use the red channel this is just a standard grayscale mapping. PushIdentityTable(TRANSLATION_Standard); remap = translationtables[TRANSLATION_Standard][8]; - for (i = 0; i < 256; i++) + remap->Remap[0] = 0; + remap->Palette[0] = 0; + for (i = 1; i < 256; i++) { remap->Remap[i] = i; remap->Palette[i] = PalEntry(255, i, i, i);