World at War - Mini Bounce

The fix for Bayonet-Jumps is also responsible for mini-bounces because they’ve just limited the maximum z-velocity a player can have instead of fixing the real issue. 3 new dvars were added: player_bayonetLaunchDebugging, player_bayonetLaunchProof and player_bayonetLaunchZCap.

A check in PM_MeleeChargeUpdate or PM_MeleeChargeClear, depending on your build, was added to check if player_bayonetLaunchProof is enabled and if it is, limit the maximum z-velocity to the value stored in player_bayonetLaunchZCap. This will act as a global z-velocity cap as that that function gets called every iteration of PmoveSingle.

So to fix mini bounces and also re-enable bayonetjumps, simply disable player_bayonetLaunchProof or nop / invert the check in PM_MeleeChargeUpdate.

PM_MeleeChargeClear - WaW / BO1

void __cdecl PM_MeleeChargeClear(playerState_s *ps)
{
    ps->pm_flags &= 0xFFFDFFFF;
    ps->meleeChargeYaw = 0.0f;
    ps->meleeChargeDist = 0;
    ps->meleeChargeTime = 0;
  
    if ( player_bayonetLaunchProof->current.enabled )
    {
        if ((player_bayonetLaunchZCap->current.value - ps->velocity[2]) < 0.0f )
            ps->velocity[2] = *(float *)&player_bayonetLaunchZCap->current.integer;
    }
}