Skip to content

Commit

Permalink
Fixed All Games: Do not do the text glitter/shadow effect for the spa…
Browse files Browse the repository at this point in the history
…ce character.
  • Loading branch information
danij-deng committed Apr 18, 2010
1 parent 037e3af commit d819ddc
Showing 1 changed file with 20 additions and 22 deletions.
42 changes: 20 additions & 22 deletions doomsday/plugins/common/src/hu_stuff.c
Expand Up @@ -2445,33 +2445,31 @@ void M_WriteText3(int x, int y, const char* string, gamefontid_t font,
w = gFonts[font].chars[c].patch.width;
h = gFonts[font].chars[c].patch.height;

if(!gFonts[font].chars[c].patch.lump)
if(gFonts[font].chars[c].patch.lump && c != ' ')
{
// A character we don't have a patch for...?!
continue;
}

if(pass)
{
// The character itself.
GL_DrawPatch_CS(cx, cy + yoff, gFonts[font].chars[c].patch.lump);
// A character we have a patch for that is not white space.
if(pass)
{
// The character itself.
GL_DrawPatch_CS(cx, cy + yoff, gFonts[font].chars[c].patch.lump);

// Do something flashy!
if(flash > 0)
// Do something flashy!
if(flash > 0)
{
M_LetterFlash(cx, cy + yoff, w, h, true,
flashColor[CR], flashColor[CG],
flashColor[CB], flashColor[CA] * flash);
}
}
else if(flagShadow && cfg.menuShadow > 0)
{
M_LetterFlash(cx, cy + yoff + h/2, w, h, true,
flashColor[CR], flashColor[CG],
flashColor[CB], flashColor[CA] * flash);
// Shadow.
M_LetterFlash(cx, cy + yoff, w, h, false, 1, 1, 1,
(red <
0 ? DGL_GetInteger(DGL_CURRENT_COLOR_A) /
255.0f : alpha) * cfg.menuShadow);
}
}
else if(flagShadow && cfg.menuShadow > 0)
{
// Shadow.
M_LetterFlash(cx, cy + yoff + h/2, w, h, false, 1, 1, 1,
(red <
0 ? DGL_GetInteger(DGL_CURRENT_COLOR_A) /
255.0f : alpha) * cfg.menuShadow);
}

cx += w;
}
Expand Down

0 comments on commit d819ddc

Please sign in to comment.