diff --git a/src/cvars.cpp b/src/cvars.cpp index 0f818f64a..1f1828f5c 100644 --- a/src/cvars.cpp +++ b/src/cvars.cpp @@ -919,6 +919,7 @@ consvar_t cv_devmode_screen = PlayerCheat("devmode_screen", "1").min_max(1, 4).d consvar_t cv_drawpickups = PlayerCheat("drawpickups", "Yes").yes_no().description("Hide rings, spheres, item capsules, prison capsules (visual only)"); consvar_t cv_drawtimer = PlayerCheat("drawtimer", "No").yes_no().description("Always draw the timer (race checkpoint timing, etc)"); consvar_t cv_debugfonts = PlayerCheat("debugfonts", "No").yes_no().description("Draw font bounding boxes (integer precision, beware centered text!)"); +consvar_t cv_vorpal = ServerCheat("vorpal", "No").yes_no().description("Show real EXP odds modification"); void lua_profile_OnChange(void); consvar_t cv_lua_profile = PlayerCheat("lua_profile", "0").values(CV_Unsigned).onchange(lua_profile_OnChange).description("Show hook timings over an average of N tics"); diff --git a/src/k_hud.cpp b/src/k_hud.cpp index 4f91c412f..f43f27f7e 100644 --- a/src/k_hud.cpp +++ b/src/k_hud.cpp @@ -4090,6 +4090,13 @@ static boolean K_drawKartLaps(void) UINT16 displayEXP = stplyr->karthud[khud_exp]; + // Odds debugger + if (cv_vorpal.value) + { + displayEXP = 100 * K_EffectiveGradingFactor(stplyr) / FRACUNIT; + } + + // Jesus Christ. // I do not understand the way this system of offsets is laid out at all, // so it's probably going to be pretty bad to maintain. Sorry. diff --git a/src/k_kart.c b/src/k_kart.c index 7816aaa21..a986dc478 100644 --- a/src/k_kart.c +++ b/src/k_kart.c @@ -151,7 +151,15 @@ fixed_t K_EffectiveGradingFactor(const player_t *player) fixed_t min = (franticitems) ? MINFRANTICFACTOR : MINGRADINGFACTOR; if (grandprixinfo.gp && grandprixinfo.masterbots && !K_PlayerUsesBotMovement(player)) return min; - return max(min, player->gradingfactor); + + fixed_t gf = player->gradingfactor; + fixed_t SOFT_CAP = FRACUNIT; + fixed_t SOFT_CAP_FACTOR = 3*FRACUNIT; + + if (gf > SOFT_CAP) + gf = SOFT_CAP + FixedDiv(gf - SOFT_CAP, SOFT_CAP_FACTOR); + + return max(min, gf); } player_t *K_DuelOpponent(player_t *player) diff --git a/src/k_roulette.c b/src/k_roulette.c index 8a734688a..6c5aad085 100644 --- a/src/k_roulette.c +++ b/src/k_roulette.c @@ -1426,7 +1426,7 @@ void K_FillItemRouletteData(player_t *player, itemroulette_t *const roulette, bo // 5: Skim any items that are much weaker than the reel's average out of the roulette // 6: Cram it all in - fixed_t largegamescaler = roulette->playing * 6 + 100; // Spread out item odds in large games for a less insane experience. + fixed_t largegamescaler = roulette->playing * 10 + 100; // Spread out item odds in large games for a less insane experience. UINT32 targetpower = 100 * roulette->dist / largegamescaler; // fill roulette with items around this value! UINT32 powers[NUMKARTRESULTS]; // how strong is each item? think of this as a "target distance" for this item to spawn at @@ -1642,7 +1642,7 @@ void K_FillItemRouletteData(player_t *player, itemroulette_t *const roulette, bo // Conversely, if we're lonely, try not to reselect an item that wouldn't be useful to us // without any players to use it on. if (K_IsItemUselessAlone(bestitem)) - deltapenalty = Easing_InCubic(loneliness, deltapenalty, 3*deltapenalty); + deltapenalty = Easing_Linear(loneliness, deltapenalty, 5*deltapenalty); // Draw complex odds debugger. This one breaks down all the calcs in order. if (cv_kartdebugdistribution.value > 1) diff --git a/src/r_main.h b/src/r_main.h index 79005f7cc..f17ef9551 100644 --- a/src/r_main.h +++ b/src/r_main.h @@ -139,6 +139,7 @@ extern consvar_t cv_debugfinishline; extern consvar_t cv_drawinput; extern consvar_t cv_drawtimer; extern consvar_t cv_debugfonts; +extern consvar_t cv_vorpal; // debugging