mirror of
https://github.com/KartKrewDev/RingRacers.git
synced 2026-04-27 20:41:46 +00:00
Ring count formatting: Correct to always have leading 0s for up to 3 digits
This commit is contained in:
parent
8c19477ad8
commit
bb98db6fce
2 changed files with 4 additions and 4 deletions
|
|
@ -5844,11 +5844,11 @@ void M_DrawStatistics(void)
|
||||||
}
|
}
|
||||||
else if (gamedata->totalrings >= 1000000)
|
else if (gamedata->totalrings >= 1000000)
|
||||||
{
|
{
|
||||||
sprintf(beststr, "%u,%u,%u", (gamedata->totalrings/1000000), (gamedata->totalrings/1000)%1000, (gamedata->totalrings%1000));
|
sprintf(beststr, "%u,%03u,%03u", (gamedata->totalrings/1000000), (gamedata->totalrings/1000)%1000, (gamedata->totalrings%1000));
|
||||||
}
|
}
|
||||||
else if (gamedata->totalrings >= 1000)
|
else if (gamedata->totalrings >= 1000)
|
||||||
{
|
{
|
||||||
sprintf(beststr, "%u,%u", (gamedata->totalrings/1000), (gamedata->totalrings%1000));
|
sprintf(beststr, "%u,%03u", (gamedata->totalrings/1000), (gamedata->totalrings%1000));
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -1025,9 +1025,9 @@ static const char *M_GetConditionString(condition_t *cn)
|
||||||
|
|
||||||
case UC_TOTALRINGS: // Requires collecting >= x rings
|
case UC_TOTALRINGS: // Requires collecting >= x rings
|
||||||
if (cn->requirement >= 1000000)
|
if (cn->requirement >= 1000000)
|
||||||
return va("collect %u,%u,%u Rings", (cn->requirement/1000000), (cn->requirement/1000)%1000, (cn->requirement%1000));
|
return va("collect %u,%03u,%03u Rings", (cn->requirement/1000000), (cn->requirement/1000)%1000, (cn->requirement%1000));
|
||||||
if (cn->requirement >= 1000)
|
if (cn->requirement >= 1000)
|
||||||
return va("collect %u,%u Rings", (cn->requirement/1000), (cn->requirement%1000));
|
return va("collect %u,%03u Rings", (cn->requirement/1000), (cn->requirement%1000));
|
||||||
return va("collect %u Rings", cn->requirement);
|
return va("collect %u Rings", cn->requirement);
|
||||||
|
|
||||||
case UC_POWERLEVEL: // Requires power level >= x on a certain gametype
|
case UC_POWERLEVEL: // Requires power level >= x on a certain gametype
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue