mirror of
https://github.com/KartKrewDev/RingRacers.git
synced 2025-10-30 08:01:28 +00:00
Ring respawn timer is based on lap count (proportional to 3 laps)
This commit is contained in:
parent
1fa417f561
commit
7321a95a65
1 changed files with 8 additions and 0 deletions
|
|
@ -11021,8 +11021,16 @@ void P_RespawnSpecials(void)
|
||||||
if (pcount == 1) // No respawn when alone
|
if (pcount == 1) // No respawn when alone
|
||||||
return;
|
return;
|
||||||
else if (pcount > 1)
|
else if (pcount > 1)
|
||||||
|
{
|
||||||
time = (180 - (pcount * 10))*TICRATE;
|
time = (180 - (pcount * 10))*TICRATE;
|
||||||
|
|
||||||
|
// If the map is longer or shorter than 3 laps, then adjust ring respawn to account for this.
|
||||||
|
// 5 lap courses would have more retreaded ground, while 2 lap courses would have less.
|
||||||
|
if ((mapheaderinfo[gamemap-1]->numlaps != 3)
|
||||||
|
&& !(mapheaderinfo[gamemap-1]->levelflags & LF_SECTIONRACE))
|
||||||
|
time = (time * 3) / mapheaderinfo[gamemap-1]->numlaps;
|
||||||
|
}
|
||||||
|
|
||||||
// only respawn items when cv_itemrespawn is on
|
// only respawn items when cv_itemrespawn is on
|
||||||
//if (!cv_itemrespawn.value) // TODO: remove this cvar
|
//if (!cv_itemrespawn.value) // TODO: remove this cvar
|
||||||
//return;
|
//return;
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue