diff --git a/src/k_kart.c b/src/k_kart.c index 97a6bef56..7d933f3ae 100644 --- a/src/k_kart.c +++ b/src/k_kart.c @@ -3370,8 +3370,13 @@ static void K_GetKartBoostPower(player_t *player) if (player->driftboost) // Drift Boost { // Rebuff Eggman's stat block corner - const INT32 heavyAccel = ((9 - player->kartspeed) * 2) + (player->kartweight - 1); - const fixed_t heavyAccelBonus = FRACUNIT + ((heavyAccel * maxmetabolismincrease * 2) / 24); + // const INT32 heavyAccel = ((9 - player->kartspeed) * 2) + (player->kartweight - 1); + // const fixed_t heavyAccelBonus = FRACUNIT + ((heavyAccel * maxmetabolismincrease * 2) / 24); + + // hello commit from 18 months ago, The Situation Has Changed. + // We buffed rings so many times that weight needs a totally different class of change! + // I've left the old formulas in, in case I'm smoking dick, but this was sorely needed in TA especially. + const fixed_t herbalfolkmedicine = FRACUNIT + FRACUNIT*(player->kartweight-1)/6 + FRACUNIT*(8-player->kartspeed)/16; fixed_t driftSpeed = FRACUNIT/4; // 25% base @@ -3382,7 +3387,10 @@ static void K_GetKartBoostPower(player_t *player) } // Bottom-left bonus - driftSpeed = FixedMul(driftSpeed, heavyAccelBonus); + // driftSpeed = FixedMul(driftSpeed, heavyAccelBonus); + + // Fucking bonus ever + driftSpeed = FixedMul(driftSpeed, herbalfolkmedicine); ADDBOOST(driftSpeed, 4*FRACUNIT, 0); // + variable top speed, + 400% acceleration, +0% handling } @@ -8635,10 +8643,15 @@ void K_KartPlayerThink(player_t *player, ticcmd_t *cmd) } else if (player->ringboost) { - // These values can get FUCKED ever since ring-stacking speed changes. - // If we're not actively being awarded rings, roll off extreme ringboost durations. + // If a Ring Box or Super Ring isn't paying out, aggressively reduce + // extreme ringboost duration. Less aggressive for accel types, so they + // retain more speed for small payouts. + + UINT8 roller = TICRATE*2; + roller += 8*(8-player->kartspeed); + if (player->superring == 0) - player->ringboost -= max((player->ringboost / TICRATE / 2), 1); + player->ringboost -= max((player->ringboost / roller), 1); else player->ringboost--; } @@ -10431,6 +10444,9 @@ static void K_KartDrift(player_t *player, boolean onground) S_StartSound(player->mo, sfx_s23c); //K_SpawnDashDustRelease(player); + // Used to detect useful driftboosts. + UINT8 oldDriftBoost = player->driftboost; + // Airtime means we're not gaining speed. Get grounded! if (!onground) player->mo->momz -= player->speed/2; @@ -10507,6 +10523,13 @@ static void K_KartDrift(player_t *player, boolean onground) player->trickcharge = 0; player->infinitether = TICRATE*2; } + + // If you actually used a useful driftboost, adjust the added boost, biasing towards bottom-right. + // Everyone else has speed-retention mechanics they can chain into themselves: Metal needs help! + if (player->driftboost > oldDriftBoost) + { + player->driftboost = (18 + player->kartweight + player->kartspeed) * player->driftboost / 20; + } } // Remove charge