mirror of
https://github.com/KartKrewDev/RingRacers.git
synced 2025-10-30 08:01:28 +00:00
Fade-in position number after GO
This commit is contained in:
parent
5f20d5a3ac
commit
2d200c1361
1 changed files with 16 additions and 0 deletions
16
src/k_hud.c
16
src/k_hud.c
|
|
@ -1601,9 +1601,20 @@ static void K_DrawKartPositionNum(INT32 num)
|
||||||
const tic_t counter = (leveltime / 3); // Alternate colors every three frames
|
const tic_t counter = (leveltime / 3); // Alternate colors every three frames
|
||||||
fixed_t scale = FRACUNIT;
|
fixed_t scale = FRACUNIT;
|
||||||
fixed_t fx = 0, fy = 0;
|
fixed_t fx = 0, fy = 0;
|
||||||
|
transnum_t trans = 0;
|
||||||
INT32 fflags = 0;
|
INT32 fflags = 0;
|
||||||
UINT8 *color = NULL;
|
UINT8 *color = NULL;
|
||||||
|
|
||||||
|
if (leveltime < (starttime + NUMTRANSMAPS))
|
||||||
|
{
|
||||||
|
trans = max(0, (starttime + NUMTRANSMAPS) - leveltime);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (trans >= NUMTRANSMAPS)
|
||||||
|
{
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
if (stplyr->positiondelay || stplyr->exiting)
|
if (stplyr->positiondelay || stplyr->exiting)
|
||||||
{
|
{
|
||||||
UINT8 delay = (stplyr->exiting) ? POS_DELAY_TIME : stplyr->positiondelay;
|
UINT8 delay = (stplyr->exiting) ? POS_DELAY_TIME : stplyr->positiondelay;
|
||||||
|
|
@ -1658,6 +1669,11 @@ static void K_DrawKartPositionNum(INT32 num)
|
||||||
fy >>= 1;
|
fy >>= 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (trans > 0)
|
||||||
|
{
|
||||||
|
fflags |= (trans << V_ALPHASHIFT);
|
||||||
|
}
|
||||||
|
|
||||||
if (stplyr->exiting && num == 1)
|
if (stplyr->exiting && num == 1)
|
||||||
{
|
{
|
||||||
// 1st place winner? You get rainbows!!
|
// 1st place winner? You get rainbows!!
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue