mirror of
https://git.do.srb2.org/STJr/SRB2.git
synced 2024-11-15 09:11:48 +00:00
Actually, wait; this is way better and cleaner.
This commit is contained in:
parent
ed0529b9d5
commit
fdcc8c912a
1 changed files with 9 additions and 7 deletions
|
@ -696,9 +696,10 @@ static void ST_drawTime(void)
|
|||
// Counting down the hidetime?
|
||||
if ((gametype == GT_TAG || gametype == GT_HIDEANDSEEK) && (stplyr->realtime <= (hidetime*TICRATE)))
|
||||
{
|
||||
tics = (hidetime*TICRATE + (TICRATE-1) - stplyr->realtime);
|
||||
if ((tics+1-TICRATE) < 3*TICRATE)
|
||||
ST_drawRaceNum(tics+1-TICRATE);
|
||||
tics = (hidetime*TICRATE - stplyr->realtime);
|
||||
if (tics < 3*TICRATE)
|
||||
ST_drawRaceNum(tics);
|
||||
tics += (TICRATE-1); // match the race num
|
||||
downwards = true;
|
||||
}
|
||||
else
|
||||
|
@ -710,11 +711,12 @@ static void ST_drawTime(void)
|
|||
// Time limit?
|
||||
if (gametype != GT_COOP && gametype != GT_RACE && gametype != GT_COMPETITION && cv_timelimit.value && timelimitintics > 0)
|
||||
{
|
||||
if (timelimitintics >= stplyr->realtime)
|
||||
if (timelimitintics > stplyr->realtime)
|
||||
{
|
||||
tics = (timelimitintics + (TICRATE-1) - stplyr->realtime);
|
||||
if ((tics+1-TICRATE) && (tics+1-TICRATE) < 3*TICRATE)
|
||||
ST_drawRaceNum(tics+1-TICRATE);
|
||||
tics = (timelimitintics - stplyr->realtime);
|
||||
if (tics < 3*TICRATE)
|
||||
ST_drawRaceNum(tics);
|
||||
tics += (TICRATE-1); // match the race num
|
||||
}
|
||||
else // Overtime!
|
||||
tics = 0;
|
||||
|
|
Loading…
Reference in a new issue