// stub KFHumanPawn for hooks
class repl_Pawn extends KFHumanPawn_Story;


// =============================================================
// remove bile effects
simulated function DoHitCamEffects(vector HitDirection, float JarrScale, float BlurDuration, float JarDurationScale ){}


// remove burning effects
simulated function StartBurnFX(){}


// remove blur effect
simulated function AddBlur(Float BlurDuration, float Intensity)
{
  if (class'Settings'.default.bRemoveBlur || KFPC == none)
    return;

  if (!bUsingHitBlur)
  {
    // If we can't handle the post processing shaders, just do an old style motion blur effect
    if (bUseBlurEffect)
    {
      StartingBlurFadeOutTime = BlurDuration;
      BlurFadeOutTime = StartingBlurFadeOutTime;

      if (CurrentBlurIntensity < Intensity)
      {
        CurrentBlurIntensity = Intensity;
      }

      if (!KFPC.PostFX_IsReady())
      {
        if (CameraEffectFound == none)
        {
          FindCameraEffect(class 'KFmod.UnderWaterBlur');
        }

        UnderWaterBlur(CameraEffectFound).BlurAlpha = UnderWaterBlur(CameraEffectFound).default.BlurAlpha;
      }
      else
      {
        KFPC.SetBlur(CurrentBlurIntensity);
      }
    }
  }
}


// PlayerReplicationInfo is none fix, sp (c)
simulated function tick(float DeltaTime)
{
  super(KFPawn).tick(DeltaTime);

  if (IsLocallyControlled() && !bUsingHitBlur && BlurFadeOutTime > 0)
  {
    BlurFadeOutTime -= DeltaTime;
    DeltaTime = BlurFadeOutTime/StartingBlurFadeOutTime * CurrentBlurIntensity;

    if (BlurFadeOutTime <= 0)
    {
      BlurFadeOutTime = 0;
      StopHitCamEffects();
    }
    else if (bUseBlurEffect && KFPC!=none && !KFPC.PostFX_IsReady())
    {
      if (CameraEffectFound != none)
        UnderWaterBlur(CameraEffectFound).BlurAlpha = Lerp(DeltaTime, 255, UnderWaterBlur(CameraEffectFound).default.BlurAlpha);
      else
        KFPC.SetBlur(DeltaTime);
    }
  }
}


// =============================================================
// commando skill for everyone
function bool ShowStalkers()
{
  // yea, show em bitches
  if (class'Settings'.default.bShowStalkers)
    return true;

  if (KFPlayerReplicationInfo(PlayerReplicationInfo) != none && KFPlayerReplicationInfo(PlayerReplicationInfo).ClientVeteranSkill != none)
  {
    return KFPlayerReplicationInfo(PlayerReplicationInfo).ClientVeteranSkill.Static.ShowStalkers(KFPlayerReplicationInfo(PlayerReplicationInfo));
  }

  return false;
}


function float GetStalkerViewDistanceMulti()
{
  // yea, show em bitches
  if (class'Settings'.default.bShowStalkers)
    return 1.0;

  if (KFPlayerReplicationInfo(PlayerReplicationInfo) != none && KFPlayerReplicationInfo(PlayerReplicationInfo).ClientVeteranSkill != none)
  {
    return KFPlayerReplicationInfo(PlayerReplicationInfo).ClientVeteranSkill.Static.GetStalkerViewDistanceMulti(KFPlayerReplicationInfo(PlayerReplicationInfo));
  }

  return 0.0;
}


// =============================================================

defaultproperties
{
}
