From 3a0d6fd2fb1fca982f217ff78d628b63eed8ad32 Mon Sep 17 00:00:00 2001 From: toaster Date: Mon, 18 Sep 2023 17:40:29 +0100 Subject: [PATCH] Minor fixes for K_RaceLapCount - Fix comment in k_race.c - Use numlaps for level_tally_t::Init instead, as this is the cache'd form and permits us to remove k_race.h from the dependencies --- src/k_race.c | 2 +- src/k_tally.cpp | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/src/k_race.c b/src/k_race.c index a6d8f2674..0a1b64a02 100644 --- a/src/k_race.c +++ b/src/k_race.c @@ -423,7 +423,7 @@ void K_RunFinishLineBeam(void) } /*-------------------------------------------------- - UINT8 K_RaceLapCount(void); + UINT8 K_RaceLapCount(INT16 mapNum); See header file for description. --------------------------------------------------*/ diff --git a/src/k_tally.cpp b/src/k_tally.cpp index 076047afa..54115326b 100644 --- a/src/k_tally.cpp +++ b/src/k_tally.cpp @@ -17,7 +17,6 @@ #include "k_kart.h" #include "k_rank.h" #include "k_grandprix.h" -#include "k_race.h" #include "k_battle.h" #include "k_boss.h" #include "k_specialstage.h" @@ -330,7 +329,7 @@ void level_tally_t::Init(player_t *player) if ((gametypes[gt]->rules & GTR_CIRCUIT) == GTR_CIRCUIT) { laps = player->lapPoints; - totalLaps = K_RaceLapCount(gamemap-1); + totalLaps = numlaps; if (inDuel == false) {