mirror of
https://github.com/KartKrewDev/RingRacers.git
synced 2025-10-30 08:01:28 +00:00
UCRP_FINISHTIMEEXACT: Round to the nearest second
This commit is contained in:
parent
f2f8a10bd0
commit
680416946a
1 changed files with 6 additions and 4 deletions
10
src/m_cond.c
10
src/m_cond.c
|
|
@ -858,7 +858,7 @@ boolean M_CheckCondition(condition_t *cn, player_t *player)
|
||||||
return (player->exiting
|
return (player->exiting
|
||||||
&& !(player->pflags & PF_NOCONTEST)
|
&& !(player->pflags & PF_NOCONTEST)
|
||||||
//&& M_NotFreePlay(player)
|
//&& M_NotFreePlay(player)
|
||||||
&& player->realtime == (unsigned)cn->requirement);
|
&& player->realtime/TICRATE == (unsigned)cn->requirement/TICRATE);
|
||||||
case UCRP_FINISHTIMELEFT:
|
case UCRP_FINISHTIMELEFT:
|
||||||
return (timelimitintics
|
return (timelimitintics
|
||||||
&& player->exiting
|
&& player->exiting
|
||||||
|
|
@ -1361,12 +1361,14 @@ static const char *M_GetConditionString(condition_t *cn)
|
||||||
((cn->type == UCRP_FINISHPLACE && cn->requirement > 1)
|
((cn->type == UCRP_FINISHPLACE && cn->requirement > 1)
|
||||||
? " or better" : ""));
|
? " or better" : ""));
|
||||||
case UCRP_FINISHTIME:
|
case UCRP_FINISHTIME:
|
||||||
case UCRP_FINISHTIMEEXACT:
|
return va("finish in %i:%02i.%02i",
|
||||||
return va("finish in %s%i:%02i.%02i",
|
|
||||||
(cn->type == UCRP_FINISHTIMEEXACT ? "exactly " : ""),
|
|
||||||
G_TicsToMinutes(cn->requirement, true),
|
G_TicsToMinutes(cn->requirement, true),
|
||||||
G_TicsToSeconds(cn->requirement),
|
G_TicsToSeconds(cn->requirement),
|
||||||
G_TicsToCentiseconds(cn->requirement));
|
G_TicsToCentiseconds(cn->requirement));
|
||||||
|
case UCRP_FINISHTIMEEXACT:
|
||||||
|
return va("finish in exactly %i:%02i",
|
||||||
|
G_TicsToMinutes(cn->requirement, true),
|
||||||
|
G_TicsToSeconds(cn->requirement));
|
||||||
case UCRP_FINISHTIMELEFT:
|
case UCRP_FINISHTIMELEFT:
|
||||||
return va("finish with %i:%02i.%02i remaining",
|
return va("finish with %i:%02i.%02i remaining",
|
||||||
G_TicsToMinutes(cn->requirement, true),
|
G_TicsToMinutes(cn->requirement, true),
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue