From d65fe8f6bf49c16eaad596dda1153cb8abff27a0 Mon Sep 17 00:00:00 2001 From: Ashnal Date: Sat, 17 May 2025 18:04:12 -0400 Subject: [PATCH] Removes score from,gp grading fixes podium warp data generation more minor renames --- src/k_podium.cpp | 32 ++++++++++++++++---------------- src/k_rank.cpp | 7 +++---- src/k_rank.h | 2 +- 3 files changed, 20 insertions(+), 21 deletions(-) diff --git a/src/k_podium.cpp b/src/k_podium.cpp index ea20555e3..0ba7a2ee4 100644 --- a/src/k_podium.cpp +++ b/src/k_podium.cpp @@ -180,7 +180,7 @@ void podiumData_s::Init(void) default: { lvl->totalExp = TARGETEXP; - texp += lvl->totalExp; + texp += lvl->totalExp * rank.numPlayers; break; } } @@ -199,7 +199,7 @@ void podiumData_s::Init(void) rgs += dta->rings; dta->exp = M_RandomRange(MINEXP, MAXEXP); - pexp = std::max(pexp, dta->exp); + pexp += dta->exp; } if (lvl->event == GPEVENT_BONUS) @@ -510,22 +510,22 @@ void podiumData_s::Draw(void) .font(srb2::Draw::Font::kZVote) .text(va("%c%d", (rank.scorePosition > 0 ? '+' : ' '), rank.scorePosition)); - drawer_winner - .xy(64, 19) - .patch("K_POINT4"); + // drawer_winner + // .xy(64, 19) + // .patch("K_POINT4"); - drawer_winner - .xy(88, 21) - .align(srb2::Draw::Align::kLeft) - .font(srb2::Draw::Font::kPing) - .colormap(TC_RAINBOW, SKINCOLOR_GOLD) - .text(va("%d", rank.winPoints)); + // drawer_winner + // .xy(88, 21) + // .align(srb2::Draw::Align::kLeft) + // .font(srb2::Draw::Font::kPing) + // .colormap(TC_RAINBOW, SKINCOLOR_GOLD) + // .text(va("%d", rank.winPoints)); - drawer_winner - .xy(75, 31) - .align(srb2::Draw::Align::kCenter) - .font(srb2::Draw::Font::kZVote) - .text(va("%c%d", (rank.scoreGPPoints > 0 ? '+' : ' '), rank.scoreGPPoints)); + // drawer_winner + // .xy(75, 31) + // .align(srb2::Draw::Align::kCenter) + // .font(srb2::Draw::Font::kZVote) + // .text(va("%c%d", (rank.scoreGPPoints > 0 ? '+' : ' '), rank.scoreGPPoints)); srb2::Draw drawer_trophy = drawer.xy(272, 10); diff --git a/src/k_rank.cpp b/src/k_rank.cpp index 89cae5e16..bd0bc030e 100644 --- a/src/k_rank.cpp +++ b/src/k_rank.cpp @@ -332,7 +332,6 @@ void gpRank_t::Init(void) const INT32 cupLevelNum = grandprixinfo.cup->cachedlevels[i]; if (cupLevelNum < nummapheaders && mapheaderinfo[cupLevelNum] != NULL) { - //laps += K_RaceLapCount(cupLevelNum); exp += TARGETEXP; } } @@ -582,10 +581,10 @@ gp_rank_e K_CalculateGPGrade(gpRank_t *rankData) rankData->scoreContinues = 0; rankData->scoreTotal = 0; - const INT32 expWeight = (rankData->totalExp > 0) ? RANK_WEIGHT_LAPS : 0; + const INT32 expWeight = (rankData->totalExp > 0) ? RANK_WEIGHT_EXP : 0; const INT32 prisonsWeight = (rankData->totalPrisons > 0) ? RANK_WEIGHT_PRISONS : 0; - const INT32 total = RANK_WEIGHT_POSITION + RANK_WEIGHT_SCORE + expWeight + prisonsWeight + RANK_WEIGHT_RINGS; + const INT32 total = RANK_WEIGHT_POSITION + expWeight + prisonsWeight + RANK_WEIGHT_RINGS; const INT32 continuesPenalty = total / RANK_CONTINUE_PENALTY_DIV; if (rankData->position > 0) @@ -619,7 +618,7 @@ gp_rank_e K_CalculateGPGrade(gpRank_t *rankData) rankData->scoreTotal = rankData->scorePosition + - rankData->scoreGPPoints + + // rankData->scoreGPPoints + rankData->scoreExp + rankData->scorePrisons + rankData->scoreRings + diff --git a/src/k_rank.h b/src/k_rank.h index d26f754c8..4f36d12df 100644 --- a/src/k_rank.h +++ b/src/k_rank.h @@ -91,7 +91,7 @@ extern "C" { #define RANK_WEIGHT_POSITION (150) #define RANK_WEIGHT_SCORE (100) -#define RANK_WEIGHT_LAPS (100) +#define RANK_WEIGHT_EXP (100) #define RANK_WEIGHT_PRISONS (100) #define RANK_WEIGHT_RINGS (50)