]> de.git.xonotic.org Git - xonotic/darkplaces.git/commitdiff
fixed transparent color in HL textures (was red, should be blue... oops)
authorlordhavoc <lordhavoc@d7cf8633-e32d-0410-b094-e92efae38249>
Sat, 3 Mar 2001 22:10:56 +0000 (22:10 +0000)
committerlordhavoc <lordhavoc@d7cf8633-e32d-0410-b094-e92efae38249>
Sat, 3 Mar 2001 22:10:56 +0000 (22:10 +0000)
git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@175 d7cf8633-e32d-0410-b094-e92efae38249

model_brush.c
wad.c

index e0bd20f40d7622e2995c646d50772273f9df67c0..3f09262d54aaadff80939fc380e20bd6808f09a5 100644 (file)
@@ -193,8 +193,11 @@ void Mod_LoadTextures (lump_t *l)
                                                out[1] = pal[p+1];
                                                out[2] = pal[p+2];
                                                out[3] = 255;
-                                               if (out[0] == 255 && out[1] == 0 && out[2] == 0) // HL transparent color (pure blue)
+                                               if (out[0] == 0 && out[1] == 0 && out[2] == 255) // HL transparent color (pure blue)
+                                               {
                                                        out[0] = out[1] = out[2] = out[3] = 0;
+                                                       transparent = TRUE;
+                                               }
                                                out += 4;
                                        }
                                }
diff --git a/wad.c b/wad.c
index 058e07b0db517465affa1b7d6c3a1bca320710c6..9fc1237dcdaf910ed38c4e379c2c05e9fa1b165a 100644 (file)
--- a/wad.c
+++ b/wad.c
@@ -354,7 +354,7 @@ byte *W_GetTexture(char *name, int matchwidth, int matchheight)
                                for (i = 0;i < image_width*image_height;i++)
                                {
                                        c = *indata++;
-                                       if (pal[c][0] == 255 && pal[c][1] == 0 && pal[c][2] == 0) // HL transparent color (pure blue)
+                                       if (pal[c][0] == 0 && pal[c][1] == 0 && pal[c][2] == 255) // HL transparent color (pure blue)
                                                outdata[0] = outdata[1] = outdata[2] = outdata[3] = 0;
                                        else
                                        {