Darken zero-padding in score box.

This commit is contained in:
Mari the Deer 2023-11-22 19:49:24 +01:00
commit 7fd2eed00b
2 changed files with 6 additions and 3 deletions

View file

@ -245,13 +245,16 @@ extend Class SWWMStatusBar
Screen.DrawTexture(AmmoTex[0],false,xx,yy,DTA_VirtualWidthF,ss.x,DTA_VirtualHeightF,ss.y,DTA_KeepRatio,true);
}
// score
String sstr = String.Format("%09d",int(ScoreInter.GetValue()));
int scr = int(ScoreInter.GetValue());
int dcnt = 8-int(Log10(clamp(scr,1,999999999)));
String sstr = String.Format("%9d",clamp(scr,0,999999999));
xx = ss.x-(margin+48);
if ( bDrewAmmo ) yy -= 12;
else yy = ss.y-(margin+22);
Screen.DrawTexture(ScoreTex,false,xx,yy,DTA_VirtualWidthF,ss.x,DTA_VirtualHeightF,ss.y,DTA_KeepRatio,true);
xx += 10;
yy += 2;
for ( int i=0; i<dcnt; i++ ) Screen.DrawChar(MiniHUDFont,mhudfontcol[MCR_BRASS],xx+i*4,yy,0x30,DTA_VirtualWidthF,ss.x,DTA_VirtualHeightF,ss.y,DTA_KeepRatio,true,DTA_ColorOverlay,Color(160,0,0,0));
Screen.DrawText(MiniHUDFont,mhudfontcol[MCR_BRASS],xx,yy,sstr,DTA_VirtualWidthF,ss.x,DTA_VirtualHeightF,ss.y,DTA_KeepRatio,true);
int bx = bDrewAmmo?56:50;
// ammo display