class SHIELD extends Actor;

var Actor SG;
var float DamageTaken;

function TakeDamage(int Damage, Pawn instigatedBy, Vector Hitlocation, Vector Momentum, class<DamageType> DamageType)
{
 if (SG != none)
 {
  if (SG.IsA('SHIELD_GUN'))
   {
    SHIELD_GUN(SG).PlaySound(SHIELD_GUN(SG).ShieldOffSound,,255,,256);
    SHIELD_GUN(SG).Blasts_Left = 4;
    SHIELD_GUN(SG).Blasts_Interval = 0.005;

    if (Damage/4 < SHIELD_GUN(SG).Energy)
     SHIELD_GUN(SG).Energy = SHIELD_GUN(SG).Energy - Damage/4;
    else
     SHIELD_GUN(SG).Energy = 0;
   }
  SG.TakeDamage(Damage, instigatedBy, HitLocation, Momentum, DamageType);
 }
}

defaultproperties
{
     bCollideActors = true
     bBlockActors = true
     bBlockKarma = true
     bBlockNonZeroExtentTraces = false
     bBlockZeroExtentTraces = true
     bBlockPlayers = true
     bBlockProjectiles = true
     bAcceptsProjectors = false
     DrawType=DT_StaticMesh
     StaticMesh=StaticMesh'SHIELD_2016_SM.SHIELD_MESH'
     AmbientSound=Sound'WeaponSounds.BaseFiringSounds.BShield1'
     bHidden=False
     bOnlyOwnerSee=False
     RemoteRole=ROLE_SimulatedProxy
     DrawScale=3.2
     AmbientGlow=255
     bUnlit=True
}
