- fixed: The floor waggle code used FloatBobOffsets as sine table but this
only has 64 entries and is not precise enough. It now uses finesine instead. - fixed: When compositing a multipatch texture any patch that is a multpatch texture itself and contains rotations may not be composited directly into the destination buffer. This must be done with an intermediate buffer. - Fixed: Drawing a slider in the options menu did not scale the x-coordinate. - Fixed: If the alt HUD had to draw negative numbers the minus sign was misplaced due to incorrect texture coordinate calculations. - changed option menu scaling for widescreen modes so that it doesn't scale down so quickly. - made some error messages in DECORATE that don't affect the parsing non-fatal so that the parser can continue to find more problems. SVN r2076 (trunk)
This commit is contained in:
parent
54283ee231
commit
87f3c9c5b7
10 changed files with 117 additions and 64 deletions
|
|
@ -158,15 +158,20 @@ static void DrawImageToBox(FTexture * tex, int x, int y, int w, int h, int trans
|
|||
|
||||
static void DrawHudText(FFont *font, int color, char * text, int x, int y, int trans=0xc000)
|
||||
{
|
||||
int zerowidth = font->GetCharWidth('0');
|
||||
int zerowidth;
|
||||
FTexture *tex_zero = font->GetChar('0', &zerowidth);
|
||||
|
||||
x+=zerowidth/2;
|
||||
for(int i=0;text[i];i++)
|
||||
{
|
||||
int width;
|
||||
FTexture *texc = font->GetChar(text[i], &width);
|
||||
int offset = texc->TopOffset - tex_zero->TopOffset + tex_zero->GetHeight();
|
||||
screen->DrawChar(font, color, x, y, text[i],
|
||||
DTA_KeepRatio, true,
|
||||
DTA_VirtualWidth, hudwidth, DTA_VirtualHeight, hudheight, DTA_Alpha, trans,
|
||||
DTA_CenterBottomOffset, 1, TAG_DONE);
|
||||
DTA_LeftOffset, width/2, DTA_TopOffset, offset,
|
||||
/*DTA_CenterBottomOffset, 1,*/ TAG_DONE);
|
||||
x+=zerowidth;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue