Merge branch 'tally-laps-one-indexed' into 'master'

level_tally_t::Init - Fix K_RaceLapCount map indexing issue

See merge request KartKrew/Kart!1475
This commit is contained in:
Oni 2023-09-10 23:51:54 +00:00
commit 6c962ad7a9

View file

@ -330,14 +330,11 @@ void level_tally_t::Init(player_t *player)
if ((gametypes[gt]->rules & GTR_CIRCUIT) == GTR_CIRCUIT) if ((gametypes[gt]->rules & GTR_CIRCUIT) == GTR_CIRCUIT)
{ {
laps = player->lapPoints; laps = player->lapPoints;
totalLaps = K_RaceLapCount(gamemap-1);
if (inDuel == true) if (inDuel == false)
{ {
totalLaps = K_RaceLapCount(gamemap); totalLaps *= 2;
}
else
{
totalLaps = K_RaceLapCount(gamemap) * 2;
} }
} }